which doesn't as far as i can tell send anything.
I also tried sending 'hello world' to the Adruino through Realterm (using serialread/available) but again to no avail.
Ive read the the manual, and saw this line:
"Remember that this IS A UART DEVICE
and that all data must be properly framed"
does this disagree with Sparkfun's description.. meaning i have to somehow frame the data? (the RF has both TTL and RS232 com ports, i am using the TTL if thats any help).
Thanks for your help! its greatly appreciated as i am supposed to do a full systems test tomorow!
haha you got me. sorry, i should be more specific i know.
the power and ground pins are all connected, and the serial connection is too the 2nd serial port of the Arduino mega. I'm pretty confident the wiring is all correct, as it was not completed by me, but by our electronics workshop. Its just the sending of data thats getting me for as far as i can tell, what ive done based on Sparkfun's website should work, but it doesn't im thinking i might possible need data framing? or im just missing something simple about RF's i thought know..
unfortunately they do not have LED's... and im sure the workshop has, but they've gone home for the night.
could the oscilloscope show there's data sending though? I can't use one however though, as my test is tomorrow morning, and they only just finished the boards for my project (including RF) this afternoon.. So i'm cutting it pretty close i know. i'll just have to keep trying with it then. I'll re-trace the connections to make sure their correctly connected too.
I presume that you saw the "Translated manual" link on Sparkfun's site. Some interesting items on that page:
You must frame your data
according to the UART standard (at 9600bps for this particular unit) to get
proper operation from these units.
Not 1200! The 1200 is bytes per second. At 8 bits per byte, that's 9600 bits per second (or baud).
Also, remember to always
keep the transmit pin (pin 3 if you are using COM1-TTL level operation) to
logical 1 (TTL level 3.3 Volts) if you are not transmitting out data.
I don't see that you are controlling this at all.
A very odd problem I ran into was the need to send out a “1” before any
data was ever sent. This does not make sense because logical “1” is
always being sent out when no official data is being sent. For some odd
reason, I had to transmit out a “1” before all of my UART’ed data. This
preceding “1” was only sent out before the whole data transmission, not
before each 10-bit frame.
Additionally, one must let 6 clock cycles (6 / 9600 seconds) pass between
sending bytes.
Not 1200! The 1200 is bytes per second. At 8 bits per byte, that's 9600 bits per second (or baud).
I had read the manual yes, and i initially saw 9600, but found it wasn't working, then saw 1200 by Sparkfun (not realising the difference from bits and bytes) and thought to change it.. it did seem quite a low number.
The third piece you mentioned, i had seen aswell, and originally had a "1" sent in the setup code, after the Serial initialization, but again my code wasn't working.. i tried to make it the absolute bare minimum code, to reduce my chances of errors as i'm not a great at coding.
The second however.. has stumped me, being new to coding (and electronics) i had no idea what the logic of a non-sending serial port (Tx,Rx) was..
Is there a way to set them to high when not receiving? it just didn't make sense to me.. as i thought you couldnt send data over the Tx,Rx unless they were set to 3.3~5v.. I'm clearly mistaken though it seems.
The second however.. has stumped me, being new to coding (and electronics) i had no idea what the logic of a non-sending serial port (Tx,Rx) was..
Well, a non-sending serial port would be a receiving port.
Actually, I think this note was there for bit-banging serial data. The hardware serial class should take care that the TX pin is at the appropriate level. Actually, setting TX HIGH when not transmitting seems backwards.
it seemed backwards to me also.. (although i barely understand it in the first place i must admit)..
I 'might' have found the mistake.. although i would like to confirm it with you if possible before i attempt and re solder the workshops work
the RF to PC is:
RF > FTDI 5v Breakout > USBlaptop.
the RF > FTDI has Vcc, GND, SGND, Tx, Rx, and Reset pins wired (set to 5v)
as with all other instances ive found, should it go from the RF's Tx > FTDI Rx, and RF's Rx > FTDI Tx?? i.e Rx>Tx, Tx>Rx
because at the moment, the wiring is Rx > Rx, Tx > Tx.. which from what ive seen in the past (for example connecting my IMU using the same FTDI breakout and serial program) it is the opposite.
because at the moment, the wiring is Rx > Rx, Tx > Tx.. which from what ive seen in the past (for example connecting my IMU using the same FTDI breakout and serial program) it is the opposite.