Setting configuration bits in code

Mar 05, 2008 1 Replies

Dear friends,



I have a MPLAB IDE project where configuration bits for the device are set in project options. I want all configuration data for the application to be contained in source code.



How do I set set configuration bits in code?



My CPU is PIC18F452, compiler is HI-TECH PICC-18 V8.35 PL3



Regards, Nickolai Leschov


The HiTech compiler has macros for this. I believe it is CONFIG or _CONFIG. To see the permissible options, look at the header file for your particular processor.

Thad

Join the Discussion

Have something to add? Share your thoughts — no account required.

Didn't find your answer?

Ask the community — no account required