CON 'Set clock speed to 80 MHz _clkmode = xtal1 + pll16x 'Sets the clock speed to 80 MHz using a times 16 multiplier _xinfreq = 5_000_000 'Crystal speed: 5 MHz PUB start cognew(@asm_start, 0) DAT org asm_start mov dira, #1 mov wait_time, short_wait_time mov test_reg, test_value wz ' This line sets the Z flag??? ' mov test_reg, #1 wz ' This line doesn't set the Z flag ' mov test_reg, #0 wz ' This line sets the Z flag if_z mov wait_time, long_wait_time mov wait_reg, cnt add wait_reg, wait_time :loop xor outa, #1 waitcnt wait_reg, wait_time jmp #:loop long_wait_time long $C000000 short_wait_time long $A00000 wait_time res 4 wait_reg res 4 test_value long $FFFF_FFFF test_reg res 4