Hex compile error

For Flowcode users to discuss projects, flowcharts, and any other issues related to Flowcode 5.
To post in this forum you must have a registered copy of Flowcode 5 or higher.

Moderator: Benj

Post Reply
alanwms
Posts: 67
Joined: Tue Sep 16, 2008 2:09 pm
Location: Minnesota USA
Has thanked: 4 times
Been thanked: 17 times
Contact:

Hex compile error

Post by alanwms »

Hello - I'm working with FC5 due to an old program I am updating. A few questions:

1. The program will not compile to Hex - Give me an error 120 telling me about C code.
I do have I block with C code changing the osccon and intcon. I deleted this block, and the 120 error remains.

2. Can this program be imported into my FC9?

I think I experienced the 120 error before, and overcome it but don't remember. I searched the forum without luck.

Can you assist?
FLOWCODE 5 Dracular BUZZ WC100218-1910.fcf
(266.72 KiB) Downloaded 17 times

medelec35
Valued Contributor
Valued Contributor
Posts: 9269
Joined: Sat May 05, 2007 2:27 pm
Location: Northamptonshire, UK
Has thanked: 2548 times
Been thanked: 3749 times
Contact:

Re: Hex compile error

Post by medelec35 »

Hi.
The attached FC9 version compiles OK for me.
Attachments
FLOWCODE 5 Dracular BUZZ WC100218-1910_v9.fcfx
(318.5 KiB) Downloaded 16 times
Martin

alanwms
Posts: 67
Joined: Tue Sep 16, 2008 2:09 pm
Location: Minnesota USA
Has thanked: 4 times
Been thanked: 17 times
Contact:

Re: Hex compile error

Post by alanwms »

Thanks Martin - How did you convert to FC9?

medelec35
Valued Contributor
Valued Contributor
Posts: 9269
Joined: Sat May 05, 2007 2:27 pm
Location: Northamptonshire, UK
Has thanked: 2548 times
Been thanked: 3749 times
Contact:

Re: Hex compile error

Post by medelec35 »

You're welcome.
I have all Flowcode versions from v3.
v6 and V7 allow you to convert the older fcf type to the newer fcfx.
I also had to modify the C code so it's XC8 compatible.
Is the v9 version working for you?
Martin

alanwms
Posts: 67
Joined: Tue Sep 16, 2008 2:09 pm
Location: Minnesota USA
Has thanked: 4 times
Been thanked: 17 times
Contact:

Re: Hex compile error

Post by alanwms »

The converted file is working for me - A few hickupps, mainly for the analog inputs. I used to have a number in the program looking for <1500. Now that code only works with <500.

I think I have concluded that the FC9 thinks that the pic18f2553 is an 8 bit analog - It's actually 12 bits (4096)

I'm trapping the DC voltage and running an eeprom save below a certain value - My sample voltage is developed from the 17VDC power using a potential divider, bringing me to around 4V. When the DC analog is around 2.5V I presume the power is going away, and Irun the eeprom save routing which saves all my values for next power up - Works great.

I checked the voltage on the AN input and the routine runs at 2.5V which should equate to around 2000 counts. It thinks that 500 counts is around 2.5V.

Should I post this on the V9 site? DId you want to take a quick look at that?

I have the older FC versions too, and will familiarize myself with the conversion process. Thank you

medelec35
Valued Contributor
Valued Contributor
Posts: 9269
Joined: Sat May 05, 2007 2:27 pm
Location: Northamptonshire, UK
Has thanked: 2548 times
Been thanked: 3749 times
Contact:

Re: Hex compile error

Post by medelec35 »

Hi.
alanwms wrote:
Mon Jun 21, 2021 3:11 am
I checked the voltage on the AN input and the routine runs at 2.5V which should equate to around 2000 counts. It thinks that 500 counts is around 2.5V.

Should I post this on the V9 site? DId you want to take a quick look at that?
If you post it on the V9 site, it will help anyone else who has v9 and facing the same issue.
I have resolved a similar issue before.
Martin

alanwms
Posts: 67
Joined: Tue Sep 16, 2008 2:09 pm
Location: Minnesota USA
Has thanked: 4 times
Been thanked: 17 times
Contact:

Re: Hex compile error

Post by alanwms »

Thanks Martin

Post Reply