

MakeCode allows you to read and plot serial data from the micro:bit, allowing you to accurately log data from the device's sensors.Ĭonnect your micro:bit to the computer with a USB cable then open in a Chrome-based browser.
Mac terminal emulator usb serial how to#
Note that WebUSB is currently only supported by Chrome.ĭiscover how to use WebUSB in this knowledge base article. The Python editor also features REPL (Read-Eval-Print-Loop), allowing you to write & test code on your micro:bit in real-time. WebUSB is still in beta we're currently looking for help testing it, and we'd love for you to get involved.īoth editors allow you to stream and plot serial data in-browser. WebUSB allows you to read serial data in your web browser using the Python or JavaScript Blocks editors.

You can send and receive data over serial on the micro:bit using both Python and Makecode for micro:bit. This is useful for debugging programs as well as data logging, or using your micro:bit as a controller for your computer. When your micro:bit is connected to a computer with a USB cable it is able to send and receive data using 'serial' communication.
