Update 3D_Printed_Guardian_Sword.py
got rid of some magic numbers from the code, since range() in python ensures no overlapping
This commit is contained in:
parent
070ca6d8c3
commit
398ef6a7bc
1 changed files with 2 additions and 2 deletions
|
|
@ -31,7 +31,7 @@ while True:
|
|||
|
||||
# Fill up 84 pixels with blue,
|
||||
# starting with pixel number 14.
|
||||
for i in range(14, BPIXELS):
|
||||
for i in range(APIXELS, BPIXELS):
|
||||
# Set Pixels to Orange Color
|
||||
pixels[i] = (0, 250, 200)
|
||||
# This sends the updated pixel color to the hardware.
|
||||
|
|
@ -41,7 +41,7 @@ while True:
|
|||
|
||||
# Fill up 9 pixels with orange,
|
||||
# starting from pixel number 84.
|
||||
for i in range(84, CPIXELS):
|
||||
for i in range(BPIXELS, CPIXELS):
|
||||
# Set Pixels to Orange Color
|
||||
pixels[i] = (250, 50, 0)
|
||||
# This sends the updated pixel color to the hardware.
|
||||
|
|
|
|||
Loading…
Reference in a new issue