litex/mibuild/altera/programmer.py

12 lines
358 B
Python
Raw Normal View History

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