2015-02-26 06:10:41 -05:00
|
|
|
import subprocess
|
|
|
|
|
|
|
|
from mibuild.generic_programmer import GenericProgrammer
|
|
|
|
|
2015-04-13 14:45:35 -04:00
|
|
|
|
2015-02-26 06:10:41 -05:00
|
|
|
class USBBlaster(GenericProgrammer):
|
2015-04-13 14:07:07 -04:00
|
|
|
needs_bitreverse = False
|
2015-02-26 06:10:41 -05:00
|
|
|
|
2015-04-13 14:07:07 -04:00
|
|
|
def load_bitstream(self, bitstream_file, port=0):
|
2015-04-13 15:33:44 -04:00
|
|
|
usb_port = "[USB-"+str(port) + "]"
|
|
|
|
subprocess.call(["quartus_pgm", "-m", "jtag", "-c", "USB-Blaster" + usb_port, "-o", "p;" + bitstream_file])
|