arduino-due

How i write multiple float data to Arduino from Rpi as master via i2c?

余生颓废 提交于 2019-12-12 04:39:12
问题 I read many post how Rpi receives float data via Arduino via i2c, with Rpi as master. But i need write floats values to arduino and i don't found any example. I want to use python smbus. Any one have a example? Thanks a lot! 回答1: After many tests, i can exchange multiple data between arduino as slave and Raspberry pi3 as master. Arduino code: #include <Wire.h> byte data[12]; int command; typedef struct processData{ float temp1; float temp2; float temp3; float temp4; float vazao_quente; float

Why do I need to change the Baudrate after I send a Reset to the ESP8266?

喜欢而已 提交于 2019-12-08 11:35:46
问题 So I have succesfully attached a Esp8266 to an Arduino Due. I can communicate with it via Serial Monitor if I choose the Baudrate to be 74880. Then all the commands come to it correctly and can be read back correctly. However, when I send the command AT+RST which restarts the Esp8266 I can no longer communicate with it and need to reopen the serial connection with a Baudrate of 115200. I have to repeat this every time I load the code new to the Arduino or when I power off the Esp8266. Any