I2C boot loader with Blinky code Should test it with Freescale boards fingers crossed should work
Fork of I2Cboot_betav1 by
Revision 6:4d4ffd9fe1a2, committed 2015-05-24
- Comitter:
- Piasiv1206
- Date:
- Sun May 24 22:55:28 2015 +0000
- Parent:
- 5:0801179037cd
- Commit message:
- printf to pc.printf
Changed in this revision
main.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/main.cpp Sun May 24 22:46:31 2015 +0000 +++ b/main.cpp Sun May 24 22:55:28 2015 +0000 @@ -403,11 +403,11 @@ g_pui8Buffer[4] = (uint8_t)g_ui32StartAddress; if(SendPacket(g_pui8Buffer, 5, 0) < 0) { - printf("Failed to Send Run command\n"); + pc.printf("Failed to Send Run command\n"); } else { - printf("Running from address %08x\n",g_ui32StartAddress); + pc.printf("Running from address %08x\n",g_ui32StartAddress); } } @@ -436,21 +436,21 @@ if(SendCommand(g_pui8Buffer, 9) < 0) { - printf("Failed to Send Download Command\n"); + pc.printf("Failed to Send Download Command\n"); return(-1); } ui32Offset = 0; - printf("Remaining Bytes: "); + pc.printf("Remaining Bytes: "); do { uint8_t ui8BytesSent; g_pui8Buffer[0] = COMMAND_SEND_DATA; - printf("%08ld", ui32TransferLength); + pc.printf("%08ld", ui32TransferLength); // // Send out 8 bytes at a time to throttle download rate and avoid @@ -476,12 +476,12 @@ // if(SendCommand(g_pui8Buffer, ui8BytesSent) < 0) { - printf("Failed to Send Packet data\n"); + pc.printf("Failed to Send Packet data\n"); break; } - printf("\b\b\b\b\b\b\b\b"); + pc.printf("\b\b\b\b\b\b\b\b"); } while (ui32TransferLength); - printf("00000000\n"); + pc.printf("00000000\n"); } \ No newline at end of file