From: SourceForge.net <no...@so...> - 2008-05-26 11:54:23
|
Patches item #1667981, was opened at 2007-02-24 20:05 Message generated for change (Settings changed) made by joerg_wunsch You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=425409&aid=1667981&group_id=39505 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: New Feature Group: None >Status: Pending >Resolution: Out of Date Priority: 5 Private: No Submitted By: Shaun Jackman (tsirc) >Assigned to: Joerg Wunsch (joerg_wunsch) Summary: IDR (OCDR) support Initial Comment: The attached short patch enables support for the I/O Debug Register (IDR). The result is that any byte written to the On-chip Debug Register (OCDR) will appear on stdout of the avarice process. Other options exist, such as sending a `O' console-output packet to GDB, but I prefer stdout. Following is an example of how to use this feature with avr-libc. Cheers, Shaun #include <avr/io.h> #include <stdio.h> static int ocd_putchar(char c, FILE *stream) { (void)stream; while (OCDR & 1<<IDRD); OCDR = c; return 0; } int main() { static FILE ocdout = FDEV_SETUP_STREAM(ocd_putchar, NULL, _FDEV_SETUP_WRITE); stdout = &ocdout; puts("Hello, world!"); return 0; } ---------------------------------------------------------------------- >Comment By: Joerg Wunsch (joerg_wunsch) Date: 2008-05-26 13:54 Message: Logged In: YES user_id=1097648 Originator: NO This has been obsoleted with the user-configurable ICE event handling as of revision 1.8 of src/jtag2run.cc. The major difference now is that a user break to the debugger is synthesized upon receiving an IDE dirty event. Would it make more sense to just continue looping for further events in that case? The current solution appears to be a bit more flexible to me (because the code could contain "controlled break to debugger" statements) but it's slower in case you just want to continue. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=425409&aid=1667981&group_id=39505 |