Timeline for Timer causes UART problem
Current License: CC BY-SA 3.0
11 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Jan 29, 2017 at 15:19 | comment | added | Johis | I can see I didn't fulfill my promise. I don't have any more insight. No idea what caused (or solved) the problem. It had something to do with the 65535ms, so an overflow somewhere would be logical, but the same code didn't cause the problem on another chip, so it'll remain a mystery to me. Thank you anyway! | |
Jan 29, 2017 at 11:10 | answer | added | Sagar | timeline score: -1 | |
Jun 26, 2016 at 12:14 | comment | added | Johis | Thanks for your valuable comments. I wanted to try your suggestions, however, I seem to be unable to reproduce the problem on another exact replica of the board that had the issue. On Tuesday, I will have access to the problematic board again and hope to be able to return with some more insight. For now, all I can say is that it seems to work just fine with the code above on another chip. Really weird... | |
Jun 25, 2016 at 14:04 | comment | added | Tom Carpenter | @Daniel DebugWire is not entirely compatible with ISP. In order to use it, you have to disable the reset pin which prevents the use of ISP programming - you then have to use HVSP or HVPP depending on the AVR in order to get ISP back. However, the 1284 and 2560 don't use debugWire - they have support for a full JTAG debugger. | |
Jun 25, 2016 at 14:01 | comment | added | Tom Carpenter | Probably more like it stops after exactly 65535ms, which implies something is overflowing somewhere. We need to see the rest of your code - the problem does not lie with what you have shown us. | |
Jun 25, 2016 at 7:34 | comment | added | Mark | Is there a timer-overflow interrupt that you should be servicing? | |
Jun 25, 2016 at 6:09 | comment | added | ThreePhaseEel | You should be able to use debugWire to debug the thing, yeah... | |
Jun 25, 2016 at 5:26 | comment | added | Daniel | Possibly/probably? I haven't used AVR in a while, but the one-wire debug was always a big bonus. | |
Jun 25, 2016 at 5:16 | comment | added | Johis | Unfortunately not with my hardware no. Both are custom built PCBs with ISP only. (or is that possible with ISP and I'm unaware of it?) I might be able to transmit the values over the working USART2. I will try that later and report back. | |
Jun 25, 2016 at 5:11 | comment | added | Daniel | Do you have a debugger that you can use to pull the register values of the UART before and after the error state? | |
Jun 25, 2016 at 5:09 | history | asked | Johis | CC BY-SA 3.0 |