16 Bit Compiler

For general Flowcode discussion that does not belong in the other sections.
Post Reply
simon-sandtcontrols
Posts: 30
http://meble-kuchenne.info.pl
Joined: Sun Mar 21, 2021 3:56 pm
Has thanked: 4 times
Been thanked: 5 times

16 Bit Compiler

Post by simon-sandtcontrols »

Hi Ben and Team,

I am not sure if I am doing something daft or if this is a bug, but I can't get the 16 Bit PIC compiler to work. This is the first time I have tried a 16 Bit PIC so I thought I would simply get a 1 second pulse working to give me a starting point. When I try and compile I get:

------------------------------------------

https://www.flowcode.co.uk
Using <PICkit2 PK2CMD External Power> inbuilt settings for compiler
Launching the compiler...
C:\ProgramData\MatrixTSL\FlowcodeV10\FCD\PIC16\batchfiles\pic16_C30_comp.bat "C:\Program Files (x86)\Flowcode\Common\Compilers\pic16\" "Myriad Mic Live V1_0" "C:\Test\" "24FJ128GB202"

C:\Test>REM CRC: 54CD51B8F484283E91B3AD9DE6F4F50C418D34178E0D3D0BD2659E1DA9D69F58D3529BB9468CFC85641793EB31F94A5F16CBA8333F125C7188ED8742865A1BBCF23BFF3064C25A11BAFA61B701B8D046E2B847C06A341BA1A924146F47BB51131AFA1B63045FF8EFD8DA408700E5719BD2897C22C80F0B985EDF8CE67A1404D62B8878703E3665631EAF018A0B6018ACC8FF364DB19D83FB389861B26F27604A1F36255EB2E4245255911F067119BEF7D5F89C133B93261A29D848A5DAD12E38FF9E5CFBC45304482C3050DA273BE4EEDBE038345E976FF7F0C03E6C1723E33C3CC5736D0D2DAB0D0DA6C43ED30373AA133F965729382C18

C:\Test>REM REVISION: 2.0

C:\Test>REM GUID: 7821ABE5-9E21-4744-81B7-3FF600B75DB7

C:\Test>REM DATE: 25\03\2024

C:\Test>REM DIR: FCD\PIC16\batchfiles\pic16_C30_comp.bat

C:\Test>xc16-gcc -c -mcpu="24FJ128GB202" -omf=coff -funsigned-char -fno-short-double -Os -I"C:\Program Files (x86)\Flowcode\Common\Compilers\pic16\support\h" -I"C:\Program Files (x86)\Flowcode\Common\Compilers\pic16\" -I"C:\Program Files (x86)\Flowcode\Common\Compilers\pic16\batchfiles\" -std=gnu99 "Myriad Mic Live V1_0".c -o "Myriad Mic Live V1_0".o
Options have been disabled due to restricted license
Visit http://www.microchip.com/ to purchase a new key.
coff-cc1.exe: fatal error: Myriad Mic Live V1_0.c: Permission denied
compilation terminated.

Error returned from [xc16-gcc.exe]

C:\ProgramData\MatrixTSL\FlowcodeV10\FCD\PIC16\batchfiles\pic16_C30_comp.bat reported error code 0x1

Autoclose turned off


FINISHED

-------------------------------------------------

I have attached the program as well. I have tried a restart, I am reading this as a complier licence problem, but I think I have seen this with the 8 bit PICs and it's then complied fine, so I am questioning that being the case. Any ideas please?

Ultimately I want to use the USB-Midi component!!

Many Thanks.

Simon
Attachments
Myriad Mic Live V1_0.fcfx
(9.47 KiB) Downloaded 75 times

medelec35
Matrix Staff
Posts: 1560
Joined: Wed Dec 02, 2020 11:07 pm
Has thanked: 555 times
Been thanked: 514 times

Re: 16 Bit Compiler

Post by medelec35 »

Hello.
You can ignore the compiler license message, I get the same.

Your project file compiles OK for me:

Code: Select all

https://www.flowcode.co.uk
Using <PICkit2 PK2CMD External Power> inbuilt settings for compiler
Launching the compiler...
C:\ProgramData\MatrixTSL\FlowcodeV10\FCD\PIC16\batchfiles\pic16_C30_comp.bat  "C:\Program Files (x86)\Flowcode\Common\Compilers\pic16\" "Myriad Mic Live V1_0" "C:\Users\medel\Downloads\" "24FJ128GB202"

C:\Users\medel\Downloads>REM CRC: 54CD51B8F484283E91B3AD9DE6F4F50C418D34178E0D3D0BD2659E1DA9D69F58D3529BB9468CFC85641793EB31F94A5F16CBA8333F125C7188ED8742865A1BBCF23BFF3064C25A11BAFA61B701B8D046E2B847C06A341BA1A924146F47BB51131AFA1B63045FF8EFD8DA408700E5719BD2897C22C80F0B985EDF8CE67A1404D62B8878703E3665631EAF018A0B6018ACC8FF364DB19D83FB389861B26F27604A1F36255EB2E4245255911F067119BEF7D5F89C133B93261A29D848A5DAD12E38FF9E5CFBC45304482C3050DA273BE4EEDBE038345E976FF7F0C03E6C1723E33C3CC5736D0D2DAB0D0DA6C43ED30373AA133F965729382C18 

C:\Users\medel\Downloads>REM REVISION: 2.0 

C:\Users\medel\Downloads>REM GUID: 7821ABE5-9E21-4744-81B7-3FF600B75DB7 

C:\Users\medel\Downloads>REM DATE: 25\03\2024 

C:\Users\medel\Downloads>REM DIR: FCD\PIC16\batchfiles\pic16_C30_comp.bat 

C:\Users\medel\Downloads>xc16-gcc -c -mcpu="24FJ128GB202" -omf=coff -funsigned-char -fno-short-double -Os -I"C:\Program Files (x86)\Flowcode\Common\Compilers\pic16\support\h" -I"C:\Program Files (x86)\Flowcode\Common\Compilers\pic16\" -I"C:\Program Files (x86)\Flowcode\Common\Compilers\pic16\batchfiles\" -std=gnu99 "Myriad Mic Live V1_0".c -o "Myriad Mic Live V1_0".o 
Options have been disabled due to restricted license
Visit http://www.microchip.com/ to purchase a new key.
Myriad Mic Live V1_0.c: In function 'main':
Myriad Mic Live V1_0.c:181:2: warning: 'return' with a value, in function returning void
Myriad Mic Live V1_0.c: At top level:
Myriad Mic Live V1_0.c:182:1: warning: '_CONFIG1' definition has been deprecated: consider migrating to #pragma config
Myriad Mic Live V1_0.c:182:1: warning: '_CONFIG2' definition has been deprecated: consider migrating to #pragma config
Myriad Mic Live V1_0.c:182:1: warning: '_CONFIG3' definition has been deprecated: consider migrating to #pragma config
Myriad Mic Live V1_0.c:182:1: warning: '_CONFIG4' definition has been deprecated: consider migrating to #pragma config

Compilation successful!

Using <PICkit2 PK2CMD External Power> inbuilt settings for linker
Launching the linker/assembler...
C:\ProgramData\MatrixTSL\FlowcodeV10\FCD\PIC16\batchfiles\pic16_C30_link.bat  "C:\Program Files (x86)\Flowcode\Common\Compilers\pic16\" "C:\Users\medel\Downloads\Myriad Mic Live V1_0" 24FJ128GB202 24F

C:\Users\medel\Downloads>REM CRC: 54CD51B8F484283E91B3AD9DE6F4F50C418D34178E0D3D0BD2659E1DA9D69F58D3529BB9468CFC85641793EB31F94A5FFDAF254055AA86A84DE7CC2C2B62544EA5031FD5F734A12219A4FB808A9F55649A0D46BD3B6AACB92DE4D84759EBB5079CA9DA2D2BBCDAE2A4D1C56CD1580BF592D3B3FD9EE90C5974272EC426D793A1AFE86FBDB7D736D8673CE585EC070B87491F441E1C9BB7FB5F3ECAD07D3BE6B346BB010096F343D3261FF4042EDA9A4E3FB62EBE9DD4F0911BC1411822B9A04BC2856CDC24100DB22C3050DA273BE4EE7DFC48FBC2CCDAA60362CA7E4DC0F30221D4703A769EA3E3B64C1696A7E966BD4B005A56FBFB0362 

C:\Users\medel\Downloads>REM REVISION: 1.0 

C:\Users\medel\Downloads>REM GUID: 868F3881-DC22-4531-8E0A-50426848D1C1 

C:\Users\medel\Downloads>REM DATE: 08\08\2022 

C:\Users\medel\Downloads>REM DIR: FCD\PIC16\batchfiles\pic16_C30_link.bat 


xc16-ld 1.26 (A)

Program Memory  [Origin = 0x200, Length = 0x155f8]

section                    address   length (PC units)   length (bytes) (dec)
-------                    -------   -----------------   --------------------
.text                        0x200               0x38c           0x552  (1362)
.text                        0x58c               0x1f6           0x2f1  (753)
.dinit                       0x782                 0x8             0xc  (12)

                 Total program memory used (bytes):          0x84f  (2127) 1%


Data Memory  [Origin = 0x800, Length = 0x2000]

section                    address      alignment gaps    total length  (dec)
-------                    -------      --------------    -------------------
.nbss                        0x800                   0             0x2  (2)

                 Total data memory used (bytes):            0x2  (2) <1%


Dynamic Memory Usage

region                     address                      maximum length  (dec)
------                     -------                      ---------------------
heap                             0                                   0  (0)
stack                        0x802                              0x1ffe  (8190)

                 Maximum dynamic memory (bytes):         0x1ffe  (8190)

Generating HEX file

C:\Users\medel\Downloads>xc16-bin2hex -omf=coff "C:\Users\medel\Downloads\Myriad Mic Live V1_0".cof 
Generating Assembler file

C:\Users\medel\Downloads>xc16-objdump -omf=coff -S "C:\Users\medel\Downloads\Myriad Mic Live V1_0".cof  1>"C:\Users\medel\Downloads\Myriad Mic Live V1_0".asm 

HEX file creation successful!


FINISHED
There appears to be an issue with your setup, rather than a Flowcode bug.

An antivirus could be restricting access to some files.

Assuming you have downloaded the 16bit toolchain from here

Or it could be a path issue within File > Global Settings.. > Locations

Check you have PIC16 path as

Code: Select all

C:\Program Files (x86)\Flowcode\Common\Compilers\pic16\
Another thing is to make sure you are fully UpToDate using FC 10.1.1.39 and latest components
Martin

simon-sandtcontrols
Posts: 30
Joined: Sun Mar 21, 2021 3:56 pm
Has thanked: 4 times
Been thanked: 5 times

Re: 16 Bit Compiler

Post by simon-sandtcontrols »

Thanks Martin,

You hit it first time, I have just turned off the fire wall in the anti virus and it worked first time. Sorry, I should have thought of that.

Thanks very much for your help.

Simon

medelec35
Matrix Staff
Posts: 1560
Joined: Wed Dec 02, 2020 11:07 pm
Has thanked: 555 times
Been thanked: 514 times

Re: 16 Bit Compiler

Post by medelec35 »

Hi Simon,
Thats great news!
You should be able to whitelist the affected files.

Thanks for the update.
Martin

Post Reply