As the title says... Chat on...

User avatar
By mrgreedy
#11034 This weekend I've had some free time to hack around with LUA and my little ESP01. I've achieved quite a lot and learned a ton of stuff. Reading and writing files, string handling, sending data to websites.

benlo.com was an excellent starting point for all this.

Any, on to my problem.. When I create a web server I can only connect to it once. Not only that, this "one time connection" only works after a hard reset. At first I thought it was something in my code. So I tried an example from the NodeMCU github..

Code: Select all    srv=net.createServer(net.TCP)
    srv:listen(80,function(conn)
      conn:on("receive",function(conn,payload)
        print(payload)
        conn:send("<h1> Hello, NodeMcu.</h1>")
      end)
      conn:on("sent",function(conn) conn:close() end)
    end)


And this will only connect once.. I'm running firmware NodeMCU 0.9.5 build 20150213 - anyone else having similar problems?
User avatar
By mrgreedy
#11059 Dropped down to NodeMCU 0.9.5 build 20150127 and the webserver part works now..

Tried using an even earlier version and it didn't have floating point number support with was a shock :)