How to send float over serial

前端 未结 9 1924
Happy的楠姐
Happy的楠姐 2021-01-02 09:15

What\'s the best way to send float, double, and int16 over serial on Arduino?

The Serial.print() only sends val

9条回答
  •  醉话见心
    2021-01-02 09:51

    Use the Firmata protocol. Quote:

    Firmata is a generic protocol for communicating with microcontrollers from software on a host computer. It is intended to work with any host computer software package. Right now there is a matching object in a number of languages. It is easy to add objects for other software to use this protocol. Basically, this firmware establishes a protocol for talking to the Arduino from the host software. The aim is to allow people to completely control the Arduino from software on the host computer.

提交回复
热议问题