diff options
author | Nao Pross <naopross@thearcway.org> | 2017-09-07 14:25:39 +0200 |
---|---|---|
committer | Nao Pross <naopross@thearcway.org> | 2017-09-07 14:25:39 +0200 |
commit | cd89b3b3f30bdd98b725de0ea565f45fb4d9567c (patch) | |
tree | cea860c15430256cf0daebf903db10aae5879a23 /sw/programmer/avr | |
parent | add test program for z80 (diff) | |
download | z80uPC-cd89b3b3f30bdd98b725de0ea565f45fb4d9567c.tar.gz z80uPC-cd89b3b3f30bdd98b725de0ea565f45fb4d9567c.zip |
minor bug fix for ROM programmer
Diffstat (limited to '')
-rw-r--r-- | sw/programmer/avr/main.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/sw/programmer/avr/main.c b/sw/programmer/avr/main.c index 9cdc35d..4f39100 100644 --- a/sw/programmer/avr/main.c +++ b/sw/programmer/avr/main.c @@ -98,16 +98,21 @@ void eeprom_write(uint16_t addr, uint8_t byte) /* set data */ EEPROMDR = byte; + + // because EEPROMDR0 and EEPROMDR1 are used by Tx and Rx + EEPROMCR = (PINC & 0x07) | (byte & 0x03)<<3; EEPROMCR &= ~(_BV(ADDR_EH) | _BV(ADDR_EL)); /* write eeprom */ EEPROMCR &= ~_BV(EEPROM_WR); - eeprom_tick(); + + // eeprom_tick(); EEPROMCR |= _BV(EEPROM_WR); EEPROMCR |= _BV(ADDR_EH) | _BV(ADDR_EL); } +#if 0 /* pulse the clock line for the eeprom */ void eeprom_tick() { @@ -116,4 +121,4 @@ void eeprom_tick() EEPROMCR &= ~_BV(EEPROM_CLK); _delay_ms(EEPROM_TICK_MS); } - +#endif
\ No newline at end of file |