Hello, please let me bring you into my world of confusion.
So I first upload master_writer onto my mega. This is in the example for Wire.h.
Computer says it's on COM4..ok..Upload goes fine and I unplug the MEGA and keep it alive with a 9V battery on it.
Upload slave_reveiver onto the UNO.. computer says COM5? Okay, I'm still using the same usb port here so I'm a tad confused.... Upload goes through, I leave the UNO on and open up the Serial Board..I've already linked SDA (20) to A4 and SCL(21) to A5 on the mega and uno respectively.
Set the baud rate... nothing...any reasons why perhaps?
Again I haven't changed any bit of either code which is why I'm not posting it.
Ideas? Help on the COM issues?
I unplug the MEGA and keep it alive with a 9V battery on it.
Did you connect the grounds of the Uno and the Mega? When you leave them both on USB connections from the computer, they are grounded together through the computer, but when one is on a battery the grounds need to be connected.
Help on the COM issues?
What you describes sounds like normal behaviour. Each Arduino shows as a different COM Port.
cattledog:
Did you connect the grounds of the Uno and the Mega? When you leave them both on USB connections from the computer, they are grounded together through the computer, but when one is on a battery the grounds need to be connected.
My apology; the grounds are connected
cattledog:
What you describes sounds like normal behaviour. Each Arduino shows as a different COM Port.
I just got it to work by playing with the script. For some reason just beginning the transmission, sending one message, and ending transmission was the way to go.. Now I know the transmission works I need to play with the code to see what works and what doesn't! Thanks for the help.
For the record now I'm changing the board and port before I upload and everything is going swimmingly
You can launch two instances of the IDE and have independent boards, ports, and serial monitors. The saved setup will come from the last instance closed.