File tree Expand file tree Collapse file tree 2 files changed +5
-4
lines changed
Expand file tree Collapse file tree 2 files changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -18,7 +18,8 @@ <h1>Sonoff S20 - ESP Web Server</h1>
1818 < p > < small >
1919 {wifi}< br >
2020 {ntp_sync}< br >
21- {watchdog}
21+ {watchdog}< br >
22+ {rtc_memory}
2223 </ small > </ p >
2324 < p > < small >
2425 total: {total:.2f} KB, used: {alloc:.2f} KB, free: {free:.2f} KB< br >
Original file line number Diff line number Diff line change 66import uasyncio as asyncio
77import uos as os
88import utime as time
9- from leds import power_led
9+ from leds import power_led , relay
1010from ntp import ntp_sync
1111from watchdog import watchdog
1212from wifi import wifi
13- from leds import power_led , relay
1413
1514rtc = machine .RTC ()
1615button_pin = machine .Pin (0 , machine .Pin .IN )
@@ -32,6 +31,7 @@ def send_web_page(writer, message=''):
3231 wifi = wifi ,
3332 ntp_sync = ntp_sync ,
3433 watchdog = watchdog ,
34+ rtc_memory = machine .RTC ().memory (),
3535
3636 utc = rtc .datetime (),
3737 total = alloc + free ,
@@ -130,7 +130,7 @@ def main():
130130 print ('Wait for WiFi connection %s sec.' % s )
131131 time .sleep (s )
132132 s += 5
133-
133+
134134 print ('Start webserver on %s...' % wifi .station .ifconfig ()[0 ])
135135 loop = asyncio .get_event_loop ()
136136
You can’t perform that action at this time.
0 commit comments