@@ -58,32 +58,32 @@ def run_example():
5858
5959 print ("\n Button ready!" )
6060
61- print ("\n Enter a new I2C address for the Qwiic Button to use." )
62- print ("\n Don't use the 0x prefix. For instance, if you wanted to" )
63- print ("\n change the address to 0x5B, you would type 5B and hit enter." )
61+ print ("Enter a new I2C address for the Qwiic Button to use." )
6462 print ("Any address from 0x08 to 0x77 works." )
63+ print ("Don't use the 0x prefix. For instance, if you wanted to" )
64+ print ("change the address to 0x5B, you would type 5B and hit enter." )
6565
66- new_address = input ("\n New Address: " )
66+ new_address = input ("New Address: " )
6767 new_address = int (new_address , 16 )
6868
6969 # Check if the user entered a valid address
70- print ("\n Characters received and new address valid!" )
71- print ("\n Attempting to set Qwiic Button address..." )
7270 if new_address >= 0x08 and new_address <= 0x77 :
71+ print ("Characters received and new address valid!" )
72+ print ("Attempting to set Qwiic Button address..." )
7373
7474 my_button .set_I2C_address (new_address )
75- print ("\n Address successfully changed!" )
75+ print ("Address successfully changed!" )
7676 # Check that the Qwiic Button acknowledges on the new address
7777 time .sleep (0.02 )
7878 if my_button .begin () == False :
79- print ("\n The Qwiic Button isn't connected to the system. Please check your connection" , \
79+ print ("The Qwiic Button isn't connected to the system. Please check your connection" , \
8080 file = sys .stderr )
8181
8282 else :
83- print ("\n Button acknowledged on new address!" )
83+ print ("Button acknowledged on new address!" )
8484
8585 else :
86- print ("\n Address entered not a valid I2C address" )
86+ print ("Address entered not a valid I2C address" )
8787
8888if __name__ == '__main__' :
8989 try :
0 commit comments