diff --git a/examples/circuitplayground_acceleration_neopixels.py b/examples/circuitplayground_acceleration_neopixels.py index 0961c6b..8bbd913 100644 --- a/examples/circuitplayground_acceleration_neopixels.py +++ b/examples/circuitplayground_acceleration_neopixels.py @@ -18,10 +18,4 @@ B = 0 x, y, z = cpx.acceleration print((x, y, z)) - if x: - R = R + abs(int(x)) - if y: - G = G + abs(int(y)) - if z: - B = B + abs(int(z)) - cpx.pixels.fill((R, G, B)) + cpx.pixels.fill(((R + abs(int(x))), (G + abs(int(y))), (B + abs(int(z)))))