简体   繁体   中英

Firmata, undeclared PULSE_IN erorr

I am trying to use the HC-SR04 and utilize the results in a python script. For this I using the StandardFirmata.ino sketch from: https://github.com/jgautier/arduino-1/blob/pulseIn/examples/StandardFirmata/StandardFirmata.ino

When I try to upload the file to my Arduino UNO I get an error. 错误消息的屏幕截图。

How do I fix this error? Is there an alternative version of Firmata I can use that still supports.ping()?

I did not install the.ping() capable Firmata correctly. You can not just swap the.ino files with the StandardFrimata available at Examples in the Arduino IDE. The files include Firmata.h which has defines for many macros used by the sketch. Since I was using the.h file from a normal Firmata the PULSE_IN macro was not defined.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM