Add Python flasher
This commit is contained in:
parent
9e784fc82c
commit
3882a07ae5
|
@ -0,0 +1,15 @@
|
|||
#!/usr/bin/env python3
|
||||
|
||||
import sys, argparse
|
||||
import programmer
|
||||
|
||||
if __name__ == "__main__":
|
||||
parser = argparse.ArgumentParser(description="Program extra data to flash memory.")
|
||||
parser.add_argument("-f", "--flash-proxy-dir", default=None, help="set search directory for flash proxy bitstreams")
|
||||
parser.add_argument("platform", help="target platform")
|
||||
parser.add_argument("file", help="file to flash")
|
||||
parser.add_argument("address", help="flash address to write")
|
||||
args = parser.parse_args()
|
||||
|
||||
prog = programmer.create_programmer(args.platform, args.flash_proxy_dir)
|
||||
prog.flash(int(args.address, 0), args.file)
|
|
@ -70,7 +70,7 @@ load: videomixer.bin
|
|||
$(MSCDIR)/tools/flterm --port /dev/ttyUSB0 --kernel videomixer.bin
|
||||
|
||||
flash: videomixer.fbi
|
||||
m1nor-ng videomixer.fbi
|
||||
$(MSCDIR)/flash_extra.py mixxeo videomixer.fbi 0x001a0000
|
||||
|
||||
clean:
|
||||
$(RM) $(OBJECTS) $(OBJECTS:.o=.d) videomixer.elf videomixer.bin videomixer.fbi
|
||||
|
|
Loading…
Reference in New Issue