SNLA267A March 2019 – June 2019 DS90UB953-Q1 , DS90UB954-Q1 , DS90UB960-Q1
## RemoteEnabledSER_GPIOs_toggle.py
##
## revision 1.0 6/13/17
##
########
#Makes 953 GPIO0-3 high and low by remote enabling them
print "\n"
import time
# Define 954 and 953 Addresses
UB953 = 0x18 #953 SER Alias ID, check 0x5C on 954 for confirmation
UB954 = 0x60 #954 Device ID, check 0x00 on 954 for confirmation
# Alias ID of SER
board.WriteI2C(UB954,0x5C,0x18)
# Be sure to check Passthrough Settings!!! in 0x58, BCC CONFIG
#board.WriteI2C(UB954,0x58,0x58)
# Port Select to enable writes to Port0
board.WriteI2C(UB954,0x4C,0x01)
# Enable GPIO0-3 as outputs on 953
board.WriteI2C(UB953,0x0E,0xF0)
# Remote Enable GPIO0-3 on 953
board.WriteI2C(UB953,0x0D,0xF0)
for y in range(0,300):
board.WriteI2C(UB954,0x6E,0x88) #Switch GPIO0 and GPIO1 to low or 0
board.WriteI2C(UB954,0x6F,0x88) #Switch GPIO2 and GPIO3 to low or 0
time.sleep(0.0000024)
board.WriteI2C(UB954,0x6E,0x99) #Switch GPIO0 and GPIO1 to high or 1
board.WriteI2C(UB954,0x6F,0x99) #Switch GPIO2 and GPIO3 to high or 1
time.sleep(0.0000024)