Conversion FC5/6 to Flowcode 7 that contains C code
Posted: Tue Jul 05, 2016 4:50 pm
Before compiling Flowcode V7 that has been loaded with Flowchart from Flowcode V5 or Flowcode V6 you must convert C code from BoostC to XC8 as that is what's shipped with Flowcode V7
In Boost C lower case is used for register and uppercase for bits.
In XC8 Upper case is used for both.
Examples
If bit is a NOT bit, for example to enable weak pullups the register bit could have a bar above:
Then you need to place a lower case n preceding the bit name.
for example to enable weak pull-ups on 16F1825 you will need to use:
If I find any more examples I will post them.
In Boost C lower case is used for register and uppercase for bits.
In XC8 Upper case is used for both.
Examples
Code: Select all
BoostC (Up to FC6) XC (FC7)
osccon = 0x70; OSCCON = 0x70;
st_bit(iocap,IOCAP3); st_bit(IOCAP,IOCAP3); or set_bit(IOCAP,IOCAP3);for example to enable weak pull-ups on 16F1825 you will need to use:
Code: Select all
clear_bit(OPTION_REG,nWPUEN); or cr_bit(OPTION_REG,nWPUEN);