My previous post was too long I guess… (sorry) That may be the reason why I did not get any answer.
So lets focus on this part : <<I've tried the "loopback" test >>
I've set my arduino uno in test mode (reset-ground) and (tx-rx) then I used the serial console from my mac.
When I type a string, I don't get back the exact string I sent (but both leds blinks and I got somethig back in the serial monitor)
Exemple "ABCDE" returns "P¨èTô" when using 14400 bauds, returns "P¨(Tô" at 19200 bauds, etc. I've tried every bauds values of the serial monitor but none of them succeeded sending back the same string.
Would you consider that as a hardware failure ? or not ? What should I do next ?
Thank's
Roland,
Paris, France
(email : roland -at- lannuzel - dot - net)
What happens at 115200 baud?
at 115200 bauds : same "garbage" in return; But always the SAME garbage for a specific string
exemple :
"ABCDE" -> "P¨(Tô"
"FGHIJ" -> "ÔJú"
"ABCDE" -> "P¨(Tô" << same answer
"FGHIJ" -> "ÔJú" << same answer
What is output in Serial Monitor at 115200 baud if you press the reset button on the Uno?
I guess you mean without the "reset <-> gnd" strip ?
With : nothing
Without : nothing either (except the blinking leds on the board)
There is no doubt the ATmega16U2 (or a supporting part) is broken. The questions are: what exactly is broken, can it be fixed, how difficult is the fix, is it worth your time.
when I send "AAAAA" I get "PPPPÐ" (the last is NOT a "D")
when i Type "aaaaa" I get "XXXXXØ"
I consider "my time" rather expensive, but less expensive than my intellectual curiosity… so IF there is a solution I will send time to solve the issue, but I already bought new ones(s) !
The letter A in binary is 0100 0001. The letter P in binary is 0101 0000. If we lay out the five As...
01000001 01000001 01000001 01000001 01000001
...then shift left six bits...
01010000 01010000 01010000 01010000 01
...we get four Ps with two bits left over.
The same thing is true with the lowercase As; shift left six bits and you get Xs.
I think with a few more experiments we can suss out how the last byte is generated but I don't think it is worth the effort.
I cannot think of any software or hardware explanation for what's happening. Consistently shifting by six bits is just so unlikely to be the result of a hardware failure or software bug.
Does a very long string of As produce a very long string of Ps with one fewer P than A?
I will send back the board tomorrow, the seller is ok to test it and send a new one if anything wrong… So, THANKS again for spending time answering me… but I resign ;o)