doku fixes

This commit is contained in:
Olaf Rempel 2012-02-20 21:34:22 +01:00
parent d27cd42955
commit 84b160bcc7
2 changed files with 11 additions and 11 deletions

View File

@ -47,7 +47,5 @@ bin: $(PRG).bin
$(OBJCOPY) -j .text -j .data -O binary $< $@ $(OBJCOPY) -j .text -j .data -O binary $< $@
install: text install: text
# uisp -dprog=stk200 --erase --upload if=$(PRG).hex --verify # avrdude -p m32 -c dragon_isp -P usb -U flash:w:$(PRG).hex
# avrdude -p m16 -c butterfly -b 19200 -P /dev/ttyUSB0 -U flash:w:$(PRG).hex mpmboot -d /dev/ttyUSB0 -a 0x11 -w flash:$(PRG).hex
# avrdude -p m16 -c dragon_isp -P usb -U flash:w:$(PRG).hex
avrdude -p m32 -c dragon_isp -P usb -U flash:w:$(PRG).hex

16
main.c
View File

@ -31,10 +31,10 @@
* *
* PA0..7 -> COL1..8 * PA0..7 -> COL1..8
* PC0..7 -> COL9..16 * PC0..7 -> COL9..16
* PB0 / PD7(OC2) -> ROW4 (OC2 not used) * PB0 / PD7(OC2) -> ROW2/GREEN (OC2 not used)
* PB1 / PD5(OC1A) -> ROW3 (OC1A not used) * PB1 / PD5(OC1A) -> ROW1/RED (OC1A not used)
* PB2 / PD4(OC1B) -> ROW2 (OC1B not used) * PB2 / PD4(OC1B) -> ROW4 (OC1B not used)
* PB3(OC0) / PD6 -> ROW1 (OC0 not used) * PB3(OC0) / PD6 -> ROW3/BLUE (OC0 not used)
* PD0 -> RXD * PD0 -> RXD
* PD1 -> TXD * PD1 -> TXD
* PD2 -> /RX_TX * PD2 -> /RX_TX
@ -68,9 +68,9 @@ const static uint8_t versioninfo[16] = "rgb16mpm v0.99";
#define CMD_WAIT 0x00 #define CMD_WAIT 0x00
#define CMD_SWITCH_MODE 0x01 #define CMD_SWITCH_MODE 0x01
#define CMD_GET_VERSION 0x02 #define CMD_GET_VERSION 0x02
// #define CMD_GET_CHIPINFO 0x03 #define CMD_GET_CHIPINFO 0x03 /* bootloader / mpmboot */
// #define CMD_READ_MEMORY 0x11 #define CMD_READ_MEMORY 0x11 /* bootloader / mpmboot */
// #define CMD_WRITE_MEMORY 0x12 #define CMD_WRITE_MEMORY 0x12 /* bootloader / mpmboot */
#define CMD_WRITE_COLOR 0x81 #define CMD_WRITE_COLOR 0x81
#define CMD_WRITE_RAW_COLOR 0x82 #define CMD_WRITE_RAW_COLOR 0x82
#define CMD_READ_RAW_COLOR 0x83 #define CMD_READ_RAW_COLOR 0x83
@ -414,9 +414,11 @@ ISR(USART_TXC_vect, ISR_NOBLOCK)
UCSRA |= (1<<MPCM); UCSRA |= (1<<MPCM);
rx_bcnt = 0xFF; // FIXME: cli? rx_bcnt = 0xFF; // FIXME: cli?
#if !(STANDALONE)
if (tx_cmd == CMD_SWITCH_MODE) { // FIXME: check mode if (tx_cmd == CMD_SWITCH_MODE) { // FIXME: check mode
wdt_enable(WDTO_15MS); wdt_enable(WDTO_15MS);
} }
#endif /* !(STANDALONE) */
} }
int main(void) __attribute__ ((noreturn)); int main(void) __attribute__ ((noreturn));