wilsonz91 WROTE:My friend gave me the code with #include<pic.h> and he told me to use mikroC so I just did as he told. Anyway,since that's for Hi-tech compiler, is there any '#include' needed for programming the pic using mikroC? i tried doing simple programming such as LED turning on and it worked.
Another question, for mikroC and Hi-tech C, is the initialization the same? eg.
TRISA0 = 0;
Is it applicable to both mikroC and Hi-tech C in initializing only port A0 as output port?
If you need to compile it into MikroC, take out the "#include <pic.h>".
You then go to Project->Edit Project (or Control+Shift+E) and edit whatever configurations that suits you and the microcontroller.
Different compilers have different ways of describing the ports.
In MikroC, it's just simply TRISA = 0 if you want them all outputs.
PIC - UIC00B from Cytron (replacement for my broken PICKit 2), Pickit 3, MikroC for PIC
dsPIC - MikroC for dsPIC, mikromedia board (dsPIC33)
AVR - AVR Dragon
Parallax - Prop tool