# Animation led lors du solo et chronometre
onevent timer0
if debut==1 then
    temps=temps+1
end
etat=(etat+1)%8
if etat==0 and solo==1 then
    call leds.circle(0,0,0,0,0,0,0,32)
elseif etat==1 and solo==1 then
    call leds.circle(32,0,0,0,0,0,0,0)
elseif etat==2 and solo==1 then
    call leds.circle(0,32,0,0,0,0,0,0)
elseif etat==3 and solo==1 then
    call leds.circle(0,0,32,0,0,0,0,0)
elseif etat==4 and solo==1 then
    call leds.circle(0,0,0,32,0,0,0,0)
elseif etat==5 and solo==1 then
    call leds.circle(0,0,0,0,32,0,0,0)
elseif etat==6 and solo==1 then
    call leds.circle(0,0,0,0,0,32,0,0)
elseif etat==7 and solo==1 then
    call leds.circle(0,0,0,0,0,0,32,0)
end        

# Animation led
onevent timer1
#(lux,0,0)=Dirty,(0,lux,0)=Bass,(0,lux,lux)=Acoustique,(lux,0,lux)=Clean,(lux,lux,0)=Batterie
call leds.top(0,lux,0) 
if lux<32 and dir==0 and debut==1 then
    lux=(lux+1)
elseif lux==32 and debut==1 then
    dir=1
    lux=(lux-1)
elseif lux>0 and dir==1 and debut==1 then
    lux=(lux-1)
elseif lux==0 and debut==1 then
    dir=0
    lux=(lux+1)
end