justintconroy / MdbBillValidator

Libraries for a Vending Machine Controller to communicate with a Bill Validator Peripheral.
19 stars 8 forks source link

How to compile this code? #2

Closed asiniy closed 9 years ago

asiniy commented 9 years ago

Can you explain briefly how can you compile & upload this code, please?

justintconroy commented 9 years ago

I used the Arduino IDE to compile and upload this to an Arduino Uno. This is just a library that can be called by an arduino program. You need to find your Libraries folder for your arduino environment. I might be able to upload a more detailed readme and a sample program in a couple of days...

asiniy commented 9 years ago

Justin, thx!

asiniy commented 9 years ago

It still will be great if you'll share an examples.

BTW, I'm use arduino mega 2560 now, and I want to use port 0 as serial monitor for arduino mega ide, and port 1 as mdb connector. How can I do that?

justintconroy commented 9 years ago

It won't be possible to use the hardware serial port on an Arduino as a serial monitor if you use this library. This library is basically a modification of the HardwareSerial library that comes with the standard Arduino stuff. So it uses the standard hardware serial port. If you want to have a serial monitor, you'll have to use SoftwareSerial.

justintconroy commented 9 years ago

I added a couple of sample programs to the repository. Again, I haven't had a chance to test this recently, so no guarantee that they actually work, and definitely no guarantee that they'll work on a Mega, but they should at least sort of show how to use the library.