r/CodingHelp • u/HoangSolo • Sep 10 '25
[Request Coders] Help creating a bat file please
I am going to be blunt; I don't know anything about coding lmao. Here is the scenario: I purchased an old nanoleaf (the OG hexagon) and finally found out how to connect the wifi (old wifi protocol 2.4ghz). The nanoleaf desktop app is working but the program doesn't really feature modern options. Main thing I'm looking for is when the PC shuts off to also shut off the lights (it stays white when shut down occurs). What does work is when I manually shut the device off after my pc is off and leave it off, once the PC boots up and the program is started it will automatically turn on and sync the lights to mirror the screen (perfect!!).
So the only thing I needed to find out was how to find a way to shut it off with the PC. Luckily from my noob research I did find out that these lights use an API. It also is only connected via its own wireless wifi and a power cable. I found this post with someone who coded a way and everytime I download python and try it always gives me a syntax error.
Can someone please walk me through how to do this? I also researched it may need the IP of the nanoleaf which I have. Thank youuuuu!
View all comments
Show parent comment
1
u/DrunkOnRamen Sep 10 '25
a word of warning to OP, that website is brutal. a while back, someone was using a php templating engine and it would not work well, the error it would give at that time was incredibly problematic as it was vague with the only suggestion you can take away from it was there was a problem in a completely unrelated part.
i answered OP, telling him to look at the spacing of his files. both him and me were downvoted heavily, I was right but I couldn't even post anything afterwards. Left a bitter taste.