openFrameworksでArduinoを制御できるようにと、FirmataというライブラリをArduinoに書き込もうとした時にはまったのでその対処法を残しておく。
ArduinoにStandardFirmataを書き込もうとした時のエラー
Firmata v2.3.5を書き込もうとしたらこんな感じ。エラーだらけす。
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 | StandardFirmata.ino: In function 'void sysexCallback(byte, byte, byte*)': StandardFirmata:462: error: 'class FirmataClass' has no member named 'write' StandardFirmata:463: error: 'class FirmataClass' has no member named 'write' StandardFirmata:466: error: 'class FirmataClass' has no member named 'write' StandardFirmata:467: error: 'class FirmataClass' has no member named 'write' StandardFirmata:468: error: 'class FirmataClass' has no member named 'write' StandardFirmata:469: error: 'class FirmataClass' has no member named 'write' StandardFirmata:472: error: 'class FirmataClass' has no member named 'write' StandardFirmata:473: error: 'class FirmataClass' has no member named 'write' StandardFirmata:476: error: 'class FirmataClass' has no member named 'write' StandardFirmata:477: error: 'class FirmataClass' has no member named 'write' StandardFirmata:480: error: 'class FirmataClass' has no member named 'write' StandardFirmata:481: error: 'class FirmataClass' has no member named 'write' StandardFirmata:484: error: 'class FirmataClass' has no member named 'write' StandardFirmata:485: error: 'class FirmataClass' has no member named 'write' StandardFirmata:487: error: 'class FirmataClass' has no member named 'write' StandardFirmata:489: error: 'class FirmataClass' has no member named 'write' StandardFirmata:494: error: 'class FirmataClass' has no member named 'write' StandardFirmata:495: error: 'class FirmataClass' has no member named 'write' StandardFirmata:496: error: 'class FirmataClass' has no member named 'write' StandardFirmata:498: error: 'class FirmataClass' has no member named 'write' StandardFirmata:499: error: 'class FirmataClass' has no member named 'write' StandardFirmata:500: error: 'class FirmataClass' has no member named 'write' StandardFirmata:501: error: 'class FirmataClass' has no member named 'write' StandardFirmata:503: error: 'class FirmataClass' has no member named 'write' StandardFirmata:507: error: 'class FirmataClass' has no member named 'write' StandardFirmata:508: error: 'class FirmataClass' has no member named 'write' StandardFirmata:510: error: 'class FirmataClass' has no member named 'write' StandardFirmata:512: error: 'class FirmataClass' has no member named 'write' |
対処法
ソースファイルを読んだけど結局分からず。エラー内容としてはFirmataClassにwriteメソッドがない、というもの。
Firmataのバージョンをv2.3.2にダウンしたらうまくいった。このバージョンはwriteメソッドを使わずに書かれている。