From 4498bc7ca7d6817198948d583910dd806f7fb982 Mon Sep 17 00:00:00 2001 From: Zach Eveland Date: Fri, 21 Oct 2011 18:03:34 -0400 Subject: starting to port bootloader programming code - testing as I go --- bootloaders/nuevo_diskloader/src/DiskLoader.cpp | 21 +++++++++++++++++---- 1 file changed, 17 insertions(+), 4 deletions(-) (limited to 'bootloaders/nuevo_diskloader/src') diff --git a/bootloaders/nuevo_diskloader/src/DiskLoader.cpp b/bootloaders/nuevo_diskloader/src/DiskLoader.cpp index efd386f..2c91367 100644 --- a/bootloaders/nuevo_diskloader/src/DiskLoader.cpp +++ b/bootloaders/nuevo_diskloader/src/DiskLoader.cpp @@ -68,9 +68,22 @@ int main() for (;;) { - L_LED_ON(); - _delay_ms(250); - L_LED_OFF(); - _delay_ms(250); +// L_LED_ON(); +// _delay_ms(250); +// L_LED_OFF(); +// _delay_ms(250); + u8* packet = _flashbuf; + u16 address = 0; + for (;;) + { +// u8 cmd = getch(); + if (Serial.available() > 0) { + u8 cmd = Serial.read(); + if (cmd == '0') + L_LED_OFF(); + if (cmd == '1') + L_LED_ON(); + } + } } } -- cgit v1.2.3-18-g5258