add Kasli-SoC POR control program
This commit is contained in:
parent
f83ef218de
commit
759bf95a76
17
kasli_soc_por.py
Normal file
17
kasli_soc_por.py
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
from time import sleep
|
||||||
|
from pyftdi.ftdi import Ftdi
|
||||||
|
|
||||||
|
POR = 1 << 7
|
||||||
|
|
||||||
|
def main():
|
||||||
|
dev = Ftdi()
|
||||||
|
dev.open_bitbang_from_url("ftdi://ftdi:4232h/0")
|
||||||
|
dev.set_bitmode(POR, Ftdi.BitMode.BITBANG)
|
||||||
|
dev.write_data(bytes([0]))
|
||||||
|
sleep(0.1)
|
||||||
|
dev.write_data(bytes([POR]))
|
||||||
|
sleep(0.1)
|
||||||
|
dev.close()
|
||||||
|
|
||||||
|
if __name__ == "__main__":
|
||||||
|
main()
|
Loading…
Reference in New Issue
Block a user