from machine import Pin
from time import sleep
import neopixel
gumbZ = Pin(16, Pin.IN, Pin.PULL_UP)
gumbM = Pin(4, Pin.IN, Pin.PULL_UP)
num_leds = 16
ring =neopixel.NeoPixel(Pin(12),num_leds)
barva=([0,0,0])
while True:
if gumbZ.value() == 0:
for i in range(num_leds):
ring[i] = [0, 255, 0]
ring.write()
sleep(0.5)
elif gumbM.value()==0:
for i in range(num_leds):
ring[i]= [0,0,0]
ring.write()