Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- pruss = Icss("/dev/uio/pruss/module")
- core = pruss.core0 # CORE 0 is what we are using
- if core.halted: # this means the PRU hasn't been initialized
- pruss.initialize()
- print("Initializing both PRUs")
- else:
- core.full_reset() # reset the core
- print("PRU already initialized")
- # load program
- pru_firmware_file = "PRU_FW.bin"
- with open(pru_firmware_file, "rb") as f:
- core.iram.write(f.read())
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement