projects
/
goodfet
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Added basic AVR flashing support, and an associated avrdude patch
[goodfet]
/
firmware
/
include
/
avr.h
diff --git
a/firmware/include/avr.h
b/firmware/include/avr.h
index
9d71b24
..
f0e8614
100644
(file)
--- a/
firmware/include/avr.h
+++ b/
firmware/include/avr.h
@@
-19,7
+19,11
@@
u8 avr_sig(u8 i);
void avr_erase();
//! Read lock bits.
u8 avr_lockbits();
void avr_erase();
//! Read lock bits.
u8 avr_lockbits();
+//! Write lock bits.
+void avr_setlock(u8 bits);
+//! Read a byte of Flash
+u8 avr_peekflash(u16 adr);
//! Read a byte of EEPROM.
u8 avr_peekeeprom(u16 adr);
//! Read a byte of EEPROM.
u8 avr_peekeeprom(u16 adr);
@@
-30,7
+34,7
@@
u8 avr_pokeeeprom(u16 adr, u8 val);
u8 avr_isready();
//Command codes.
u8 avr_isready();
//Command codes.
-//! Perform
a
chip erase.
+//! Perform
a
chip erase.
#define AVR_ERASE 0xF0
//! Fetch RDY/!BSY byte.
#define AVR_RDYBSY 0xF1
#define AVR_ERASE 0xF0
//! Fetch RDY/!BSY byte.
#define AVR_RDYBSY 0xF1
@@
-43,9
+47,13
@@
u8 avr_isready();
#define AVR_POKEEEPROM 0x91
//! Read lock bits.
#define AVR_PEEKLOCK 0x82
#define AVR_POKEEEPROM 0x91
//! Read lock bits.
#define AVR_PEEKLOCK 0x82
+//! Write lock its.
+#define AVR_POKELOCK 0x92
//! Read signature.
#define AVR_PEEKSIG 0x83
//! Read fuse bits.
#define AVR_READFUSES 0x84
//! Read calibration byte.
#define AVR_READCAL 0x85
//! Read signature.
#define AVR_PEEKSIG 0x83
//! Read fuse bits.
#define AVR_READFUSES 0x84
//! Read calibration byte.
#define AVR_READCAL 0x85
+//! Bulk load data
+#define AVR_BULKLOAD 0x86