firmata / arduino

Firmata firmware for Arduino
GNU Lesser General Public License v2.1
1.54k stars 515 forks source link

Documentation and sample output #207

Open bitcraft opened 9 years ago

bitcraft commented 9 years ago

Thanks everyone for putting together and maintaining firmata. Its been great using it, and I look forward to new changes and features! I'm developing a python application that needs robust arduino support (unit tested, full protocol support) and I've been developing my own python lib with integrated unit and protocol testing...since there isn't one available.

I'm wondering if there is a resource that has a breaks down of all firmata commands with sample output from an ideal firmata communication session? Right now I am reading the docs, writing out sample output in bytes, then developing the python code to parse and build the packets. The tests only pass if the sample output bytes can be parsed, then remade into bytes, and the inputs and outputs match.

Anyway, it would help me a great deal (and others, too!) if there was a standard file with sample outputs that could be used to testing...rather than relying on integration tests using a real board. Is there such a thing? Would the maintainers be interested in the files I am compiling with sample data?

Thanks!

soundanalogous commented 9 years ago

You can find a set here that includes output from a few different Arduino boards: https://github.com/soundanalogous/Breakout/blob/master/test/core/fixtures/fixtures.js

soundanalogous commented 9 years ago

I could convert that to a json file and host it in the firmata repo. Then others could add to it.

bitcraft commented 9 years ago

That would be brilliant. The file you linked is almost exactly what I had in mind. I think that it would be useful for more people. I agree, converting it to JSON would be best. On Sat, Jul 25, 2015 at 12:36 PM Jeff Hoefs notifications@github.com wrote:

I could convert that to a json file and host it in the firmata repo. Then others could add to it.

— Reply to this email directly or view it on GitHub https://github.com/firmata/arduino/issues/207#issuecomment-124866438.