diff --git a/avr/usbload/inflate.c b/avr/usbload/inflate.c index a2ad6d1..9652c10 100644 --- a/avr/usbload/inflate.c +++ b/avr/usbload/inflate.c @@ -21,9 +21,17 @@ #include "neginf/neginf.h" #include "inflate.h" +#include "sram.h" + + char inflate_done = 0; +void inflate_init(){ + neginf_init(0); + sram_bulk_write_start(0x000000); +} + void neginf_cb_completed() { inflate_done = 1; @@ -31,10 +39,28 @@ void neginf_cb_completed() void neginf_cb_seq_byte(nbyte byte) { - // TODO: implement this + sram_bulk_write(byte); } +uint8_t buffer[512]; + void neginf_cb_copy(nsize from, nsize to, nint length) { - // TODO: implement this + uint32_t addr; + uint8_t c; + +/* + sram_bulk_addr_save(); + for (addr=from; addr