我正在从事一个房间可视化项目,类似于此(摘自):我正在使用来自leddartech的LeddarVu8 (见下图),arduino uno (与rs485shield一起使用): #include "C:\Program Files (x86)\ArduinoCan be used with Arduino IDE's Serial Monitor.的串行
所以我画了一个草图,从usb端口取一个两位数的数字,检查与该数字匹配的引脚的状态,然后切换引脚的开/关。由于某些原因,当我通过Arduino串行监视器发送13时,我得到了这样的消息:Pin number is greater than 14, details: 490 51 541
这意味着IDE发送了奇怪的数字,或者Arduino错误地处理了它们。
我用信号编写了道路转弯事故预防系统的Arduino程序,并在tinker CAD仿真中进行了测试,当蜂鸣器插针的功能被调用时,插脚0和1的输出受到影响,如果从代码中删除该函数,代码运行良好。int irSensor1 = 12; // connect ir sensor 1 to arduino pin 12intled1 = 8; // conect Led1 to arduino pin 0
int l