PIC10F200 >> Assembly
Wake-up on Pin Change
GPWU用來設定是否開啟Wake-up from Sleep on Pin Change功能,特性跟Watchdog一樣,Wake-up後是直接Reset Device,而非繼續往下執行
main.s
list p=10f200, r=hex #include <p10f200.inc> __config _CONFIG, _IntRC_OSC & _WDTE_OFF & _MCLRE_OFF org 0x00 start: movlw b'00000000' option movlw b'00001100' tris GPIO bcf GPIO, 1 movlw 0x01 xorwf GPIO, f sleep goto $ end
編譯
$ gpasm main.s
完成