Steve,
I tried that and it still just ramps up and doesn't seem to want to jump to the down label
Code:@ __CONFIG _INTRC_OSC_NOCLKOUT & _WDT_ON & _PWRTE_ON & _MCLRE_OFF & _BODEN_ON TRISIO.0 = 0 'Set GPIO.0 to output. ANSEL.0 = 0 'Set GPIO.0 to digital GPIO.0 = 0 CMCON = 7 ' PortA Digital inputs VRCON = 0 ' Voltage reference disabled OPTION_REG.7 = 0 led var GPIO.0 i var byte getout var bit main: for i = 1 to 254 Pwm GPIO.0,i,1 if i=253 then i=254 GetOut=1 endif next i if Getout=1 then goto down down: for i = 254 to 1 step -1 Pwm GPIO.0,i,1 if i=2 then i=1 GetOut=0 endif next i if Getout=0 then goto main




Bookmarks