#chip 10f200, 4 'mhz #config MCLRE=off, WDT=off
start: set gpio.0 on set gpio.1 on set gpio.3 on goto start
But nothing happens why? it compiles and programs fine
Don't you have to do "DIR GPIO.x OUT" to set it up as an output?
Joe
It's like that, but with the baseline devices the TRIS or direction has to be set all at once. Also suspect the config for the internal osc needs to be set. Here's the setup for blinky leds:
#chip 10f200, 4 #config INTRC_OSC
#define LED1 GPIO.0 #define LED2 GPIO.1 #define LED3 GPIO.2 dir GPIO b'001000'
Log in to post a comment.
#chip 10f200, 4 'mhz
#config MCLRE=off, WDT=off
start:
set gpio.0 on
set gpio.1 on
set gpio.3 on
goto start
But nothing happens why? it compiles and programs fine
Don't you have to do "DIR GPIO.x OUT" to set it up as an output?
Joe
It's like that, but with the baseline devices the TRIS or direction has to be set all at once. Also suspect the config for the internal osc needs to be set. Here's the setup for blinky leds:
#chip 10f200, 4
#config INTRC_OSC
#define LED1 GPIO.0
#define LED2 GPIO.1
#define LED3 GPIO.2
dir GPIO b'001000'