How to use file.write as a substitute for io.write?
Posted: Thu Aug 16, 2018 6:08 pm
Deep in the NodeMCU Developer FAQ there is brief mention:
"For example, the standard io and os libraries don't work, but have been largely replaced by the NodeMCU node and file libraries."
But nowhere is it explained how to use file.write as an alternative for io.write.
A simple replacement of file.write for io.write yields:
What file is to be opened to get the same serial console that is used by print()?
Where is this documented?
"For example, the standard io and os libraries don't work, but have been largely replaced by the NodeMCU node and file libraries."
But nowhere is it explained how to use file.write as an alternative for io.write.
A simple replacement of file.write for io.write yields:
Code: Select all
PANIC: unprotected error in call to Lua API (calculateTime.lua:30: open a file first)
What file is to be opened to get the same serial console that is used by print()?
Where is this documented?