Post your best Lua script examples here

User avatar
By rutierut
#15535 Somehow i've lost the .bin file from the firmware & reflashed all my ESP's with another one. I've been searching for hours for this firmware online and trying many others but they al have either a broken MQTT-module or to little memory. Does anyone still have this file? If so pleaseeee upload it.
User avatar
By MeNoGeek
#15550
rutierut wrote:Somehow i've lost the .bin file from the firmware. Does anyone still have this file? If so pleaseeee upload it.
I didn't follow the whole topic, but from your original post...
rutierut wrote:NodeMCU 0.9.5 build 20150118
...I reckon you might be looking for some file on this page:
https://github.com/nodemcu/nodemcu-firmware/tree/master/pre_build/0.9.5
User avatar
By rutierut
#15577
MeNoGeek wrote:
rutierut wrote:Somehow i've lost the .bin file from the firmware. Does anyone still have this file? If so pleaseeee upload it.
I didn't follow the whole topic, but from your original post...
rutierut wrote:NodeMCU 0.9.5 build 20150118
...I reckon you might be looking for some file on this page:
https://github.com/nodemcu/nodemcu-firmware/tree/master/pre_build/0.9.5


First of all thanks for your reply. Unfortunately, while the same version, this appears to be a different file . Although that's what i thought. None of my MQTT scripts are functional using this file, every time this error is served:

(Workinprogress.lua:46: attempt to index global 'mqtt' (a nil value))

this is line 46:

m = mqtt.Client(clientID, 120, userID, userPWD)


I have no idea how to fix this as higher versions seem to be having lower memory and can't even run or compile the script.