-
Notifications
You must be signed in to change notification settings - Fork 325
lua debugging via serial console
Noodlesalat edited this page Feb 18, 2019
·
2 revisions
This presents a very simple way of getting a debug output of a lua script on the serial console. Shortly before the device reboots this can be used, e.g. in order to debug things such as the "Save & Reboot"-button in the config-modes wizard.
In this example the device of the serial-console was /dev/ttyS0. No additional steps are required as this should work out of the box.
-- open serial console to send messages
local wserial = io.open("/dev/ttyS0","w")
-- write messages (two dot for string concat)
wserial:write("DEBUG: this is my debug output"..aVariable.."\n")
-- send all queued messages (this is non-obligatory)
wserial:flush()
-- close serial connection
wserial:close()
-
Usage
-
Community
-
Development
- Device Integration
- Roadmap
- Release-life-cycle
- Protocols
- Meeting 2024/05
- Meeting 2024/03
- Meeting 2024/02
- Meeting 2024/01
- Meeting 2023/06
- Meeting 2023/05
- Meetup-CCCamp
- Meeting 2023/04
- Meeting 2023/03
- Meeting 2023/02
- Meeting 2023/01
- Meeting 2022/06
- Meeting 2022/05
- Meeting 2022/04
- Meeting 2022/03
- Meeting 2022/02
- Meeting 2022/01
- Meeting 2021/01
- Meeting 2019/01
- Meeting 2018/03
- Meeting 2018/02
- Meeting 2018/01
- Meeting 2017/01
- Concepts
- Release Process
-
Debugging