![]() While MicroPython was designed to be "bare iron", it wasn't overly difficult to port it to run as a separate task inside the XBee firmware, and connect it up with internals for I/O and file. Run the following command at the serial REPL: After pressing enter you should see no output and the > prompt return. With this script you have basic serial port communications (quite usable) and it can be easily added to for enhanced functionality. Controlling a Relay Module – MicroPython Code (Script) The code to control a relay with the ESP32 or ESP8266 is as simple as controlling an LED or any other output. sqlite3 - Reimplementation of CPython's sqlite3 module for Pycopy (Unix port). The standard Python libraries have been “micro-ified” to fit in with the philosophy of MicroPython. Micropython serial module micropython serial module from machine import Pin led = Pin (Pin.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |