print is exactly the same as console.log in Espruino - it's really there just to make it easier for learners...
If you know where the console is (eg. Serial1) you can just do Serial1.write - but you should be aware that you can totally mess things up - console.log actually removes the current line(s) being input in the console before writing your text (the current input line is then put back when your JS function has finished executing)
Espruino is a JavaScript interpreter for low-power Microcontrollers. This site is both a support community for Espruino and a place to share what you are working on.
print
is exactly the same asconsole.log
in Espruino - it's really there just to make it easier for learners...If you know where the console is (eg. Serial1) you can just do
Serial1.write
- but you should be aware that you can totally mess things up -console.log
actually removes the current line(s) being input in the console before writing your text (the current input line is then put back when your JS function has finished executing)