Guide to creating your own PICmicro definition files

For Flowcode users to discuss projects, flowcharts, and any other issues related to Flowcode 2 and 3.

Moderators: Benj, Mods

User avatar
Benj
Matrix Staff
Posts: 14226
Joined: Mon Oct 16, 2006 10:48 am
Location: Matrix TS Ltd
Has thanked: 4363 times
Been thanked: 4096 times
Contact:

Guide to creating your own PICmicro definition files

Postby Benj » Thu Jul 26, 2007 3:20 pm

For those of you wanting to use PICmicro devices that are not already part of Flowcode there is now a step by step guide on how to create your own definition file.

The target PICmicro devices that you create will not be compatible with our hardware. However if you are already using your own hardware then this is not a problem.

The guide is available as unsupported so please post any problems you have on the forum and we will do our best to help out.

The guide is available from here.

http://www.matrixmultimedia.com/softwar ... _files.pdf

If you get a target device working correctly and you think it should be included into the next release of Flowcode then please email me the new FCD file.

jimhumphries
Posts: 112
Joined: Wed Oct 12, 2005 6:29 pm
Location: USA
Been thanked: 1 time
Contact:

Re: Guide to creating your own PICmicro definition files

Postby jimhumphries » Wed Feb 20, 2008 8:30 pm

Ben:

I copied the 16F876 fcd file, made changes to the A/D code then renamed (16f876m4) and saved the copy to the v3 fcd folder, however, when I open Flowcode and look for the new device it doesn't show up. Am I missing a step?

Jim

User avatar
Benj
Matrix Staff
Posts: 14226
Joined: Mon Oct 16, 2006 10:48 am
Location: Matrix TS Ltd
Has thanked: 4363 times
Been thanked: 4096 times
Contact:

Re: Guide to creating your own PICmicro definition files

Postby Benj » Mon Feb 25, 2008 1:42 pm

Hello Jim

Make sure that the file extension is .fcd and not .txt

You may have to modify your folder settings to be able to view the file type extension.

Windows Explorer -> Tools -> Folder Options -> View -> Untick hide extensions for known file types.

jimhumphries
Posts: 112
Joined: Wed Oct 12, 2005 6:29 pm
Location: USA
Been thanked: 1 time
Contact:

Re: Guide to creating your own PICmicro definition files

Postby jimhumphries » Sun Mar 02, 2008 8:19 am

Ben:

That was the problem. Thanks.

Jim

jimhumphries
Posts: 112
Joined: Wed Oct 12, 2005 6:29 pm
Location: USA
Been thanked: 1 time
Contact:

Re: Guide to creating your own PICmicro definition files

Postby jimhumphries » Sun Apr 05, 2009 7:19 pm

Ben:

I'm having trouble with modified .fcd files under v3.6. If I modify the .fcd file code (using Notepad) and then save it without renaming it everything works fine. If I rename the file (either by "saving as" or by directly modifying the file name) it shows up as a target choice in the "chip" pull down menu but I get an error message and a compile failure if I use it as the target. In the example below I added "B" to the fcd file name for the 16F876 (16F876B) and tried to compile:

===============================================================
File name: C:\Documents and Settings\Jim Humphries\Desktop\pump current build\Pump Software\2009 files\4MHz files\Pump\V316pumpt41aa4M.c
Generated by: Flowcode v3.6.11.53
Date: Sunday, April 05, 2009 12:13:00
Licence: Professional
Registered to: Jim Humphries


http://www.matrixmultimedia.com



Launching the compiler...

C:\Program Files\Matrix Multimedia\Flowcode V3\BoostC\boostc.pic16.flowcode.exe -v -t PIC16F876B "V316pumpt41aa4M.c"

BoostC Optimizing C Compiler Version 6.70 (for PIC16 architecture)
http://www.sourceboost.com
Copyright(C) 2004-2007 Pavel Baranov
Copyright(C) 2004-2007 David Hobday

Licensed to FlowCode User under Single user Pro License for 1 node(s)
Limitations: PIC12,PIC16 max code size:Unlimited, max RAM banks:Unlimited


V316pumpt41aa4M.c
Starting preprocessor: "C:\Program Files\Matrix Multimedia\Flowcode V3\BoostC\pp.exe" "C:\Documents and Settings\Jim Humphries\Desktop\pump current build\Pump Software\2009 files\4MHz files\Pump\V316pumpt41aa4M.c" -i "C:\Program Files\Matrix Multimedia\Flowcode V3\BoostC\include" -d _PIC16F876B -la -c2 -o V316pumpt41aa4M.pp -v -d _BOOSTC -d _PIC16

C:\Documents and Settings\Jim Humphries\Desktop\pump current build\Pump Software\2009 files\4MHz files\Pump\V316pumpt41aa4M.c(1197): EEPROM error - MX_EEADR not set
C:\Documents and Settings\Jim Humphries\Desktop\pump current build\Pump Software\2009 files\4MHz files\Pump\V316pumpt41aa4M.c(1201): EEPROM error - MX_EEDATA not set
C:\Documents and Settings\Jim Humphries\Desktop\pump current build\Pump Software\2009 files\4MHz files\Pump\V316pumpt41aa4M.c(1254): EEPROM error - MX_EEADR not set
C:\Documents and Settings\Jim Humphries\Desktop\pump current build\Pump Software\2009 files\4MHz files\Pump\V316pumpt41aa4M.c(1258): EEPROM error - MX_EEDATA not set

4 errors detected
Error: preprocessing error

failure

......................
Return code = 1

Flowcode was unable to compile the flowchart's C code due to the following errors:


If your flowchart contains C code, please review this carefully. If your flowchart contains no C-code or you have thoroughly reviewed the code, contact Technical Support.

FINISHED
====================================================

I didn't have this problem with v3.2. What am I missing?

Jim

User avatar
Benj
Matrix Staff
Posts: 14226
Joined: Mon Oct 16, 2006 10:48 am
Location: Matrix TS Ltd
Has thanked: 4363 times
Been thanked: 4096 times
Contact:

Re: Guide to creating your own PICmicro definition files

Postby Benj » Mon Apr 06, 2009 10:50 am

Hi Jim

Now if you are changing the FCD filename then you have to add the chip type to the device section of the FCD file. This lets the compiler know which chip it is going to be using.

eg.

ChipName=16F876

jimhumphries
Posts: 112
Joined: Wed Oct 12, 2005 6:29 pm
Location: USA
Been thanked: 1 time
Contact:

Re: Guide to creating your own PICmicro definition files

Postby jimhumphries » Mon Apr 06, 2009 3:40 pm

Ben:

That did it. Thanks!

Jim