-->
Page 6 of 26

Re: [NodeMcu] Change log (build 20141209)

PostPosted: Tue Dec 09, 2014 5:22 am
by zeroday
alonewolfx2 wrote:How can i use more than one timer? Can you give an example?

zeroday wrote:Change log:
2014-12-09
increase alarm num in tmr module to 7.


Code: Select alltmr.alarm(0,1000,1,function() print("alarm 0") end)
tmr.alarm(1,2000,1,function() print("alarm 1") end)

--tmr.stop(0)
--tmr.stop(1)

Re: [NodeMcu] Change log (build 20141211)

PostPosted: Thu Dec 11, 2014 2:07 am
by zeroday
Change log:
2014-12-11
    1, fix uart.setup(), now setup can set pins in other mode back to uart mode.
    2, add wifi.sta.status() api, to get connection status in station mode.
    3, modify tmr.now() to return a uint31 rather than uint32. now-=0x80000000 if now>0x7fffffff.

Re: [NodeMcu] Change log (build 20141211)

PostPosted: Thu Dec 11, 2014 7:48 am
by gerardwr
zeroday wrote:Change log:
2014-12-11
    1, fix uart.setup(), now setup can set pins in other mode back to uart mode.


Sorry, but I do not understand what the change is, not even after looking at the updated documentation.

At 1st I thought that there was a way to re-purpose the RX/TX lines as GPIO, and now setting this back to uart was the change. Apparently it is not.

What is it, please?

Re: [NodeMcu] Change log (build 20141211)

PostPosted: Thu Dec 11, 2014 8:16 am
by zeroday
gerardwr wrote:
zeroday wrote:Change log:
2014-12-11
    1, fix uart.setup(), now setup can set pins in other mode back to uart mode.


Sorry, but I do not understand what the change is, not even after looking at the updated documentation.

At 1st I thought that there was a way to re-purpose the RX/TX lines as GPIO, and now setting this back to uart was the change. Apparently it is not.

What is it, please?


gpio1 and gpio3 are rx/tx. the default function of these 2pins is uart.
gpio module can use these 2 pins as general io pins, gpio.mode(..)

the issue is, when these pins set as gpio. it works as gpio.
but if you want to set these pins again in uart mode(uart.setup). it failed.

it stays in gpio mode (rx pin). issue 18