Rich D.
Active Member
Hi all,
I'm sure it's just me but I can't seem to figure out this Arduino software too easily. I find the arduino site's examples incomplete and unclear. Now, please realize I have done some amazing things with software both high and low-level over the years, but for some reason this simple task seems to elude me. What I am hoping to do is simple:
Serial communication; individual bytes and possibly strings (I'll take either!) between two Arduinos. One is your basic Arduino - the Leonardo, and the other is a MEGA2560. I'm looking to send/receive bytes that are not always visible ASCII characters - anything from 00 to FF (or 0-255).
If there is somebody out there who can create a very simple, no-frills example of transmit and receive code for each of these machines (if there is a difference), please, please, PLEASE, post it here for me to consume. (I don't sound too desperate, do I?)
Yes, I did use the same baud rate - 19.2k, and yes I did connect a common ground between the two boards. Tx->Rx and Rx->Tx. It's just the software is made to be so simple that I can't seem to make it work! I am also aware that the USB to program it and other hardware may share the same lines, and something about the Leonardo has both Serial and Serial1 (though I forget which is which).
Many thanks in advance for any useful information....you are awesome!
I'm sure it's just me but I can't seem to figure out this Arduino software too easily. I find the arduino site's examples incomplete and unclear. Now, please realize I have done some amazing things with software both high and low-level over the years, but for some reason this simple task seems to elude me. What I am hoping to do is simple:
Serial communication; individual bytes and possibly strings (I'll take either!) between two Arduinos. One is your basic Arduino - the Leonardo, and the other is a MEGA2560. I'm looking to send/receive bytes that are not always visible ASCII characters - anything from 00 to FF (or 0-255).
If there is somebody out there who can create a very simple, no-frills example of transmit and receive code for each of these machines (if there is a difference), please, please, PLEASE, post it here for me to consume. (I don't sound too desperate, do I?)
Yes, I did use the same baud rate - 19.2k, and yes I did connect a common ground between the two boards. Tx->Rx and Rx->Tx. It's just the software is made to be so simple that I can't seem to make it work! I am also aware that the USB to program it and other hardware may share the same lines, and something about the Leonardo has both Serial and Serial1 (though I forget which is which).
Many thanks in advance for any useful information....you are awesome!