nickelflippr
Member
Yes you can import the compiled.asm or yourfile.asm to a MPLAB project if you wish. Or better yet just import the compiled.hex directly to the Pickit 2, clone, or? programmer. With the auto import hex feature of the Pickit 2, you have a one button to download sequence.Cow Basic is wierd lol i changed or created a new compile bat to make it simpler:
Code:@ECHO OFF E: cd \PROGRA~1\GCBASIC GCBASIC /NC %1 /O:%1.asm PAUSE
This will compile your file and place it in same directory as original.
Then u would use mplab to load it i assume.
Here is some code for GCBasic, if you want to flash some leds on your 10F206. One could just paste into notepad, or any other editor, save to the GCBasic directory, drag and drop on download.bat, then import the compiled.hex to your programmer. A good editor program with a macro function is the best way to go to automate the process and keep your files organized.
Code:
#chip 10f206, 4
#config INTRC_OSC
dir GPIO b'001000'
Main:
For test = 1 to 3
SET GPIO.0 ON
SET GPIO.1 OFF
WAIT 50 10ms
SET GPIO.0 OFF
SET GPIO.1 ON
WAIT 50 10ms
Next
GPIO = 0
wait 1 s
For nib = 1 to 7
GPIO = nib
wait 50 10ms
Next
GPIO = 0
wait 1 s
goto Main
Code:
#define LED1 GPIO.0
#define LED2 GPIO.1
#define LED3 GPIO.2
Last edited: