Pic12629 + Pic12f675 not working!

Any bugs you encounter with Flowcode should be discussed here.
BenR
Matrix Staff
Posts: 1707
http://meble-kuchenne.info.pl
Joined: Mon Dec 07, 2020 10:06 am
Has thanked: 435 times
Been thanked: 598 times

Re: Pic12629 + Pic12f675 not working!

Post by BenR »

This is hard, in MPLAB it's a setting you disable to turn off the OSCCAL initialisation. I cannot find the same thing in the XC8 manual so I'm guessing at what MPLAB might be doing to the compiler behind the scenes.

I'll see if I can dig out a chip and do some tests.

Does the program still run fine from v5? if it does then this could indicate that either the OSCCAL thing is a red herring or that the BoostC compiler doesn't fetch the OSCCAL on startup and hence doesn't have the problem.

jgu1
Posts: 602
Joined: Thu Dec 03, 2020 8:25 pm
Location: Denmark
Has thanked: 495 times
Been thanked: 132 times

Re: Pic12629 + Pic12f675 not working!

Post by jgu1 »

Hi Ben!

Yes, they working,there are no problems with these small units in Fc5, at lease the ones I have available work fine. Would it make any sense, for testing, to try and compile in fc9 and use the hex file in PPP and burn it to the Pic ?
But, anyway Ben, if it is too hard a nut to crack, let it be as it is, at least for my sake. Now I know the bug and can use Fc5 when I use these devices. But you know, when I make a program and want to compile to the Chip and discover it not working, you automaticly begin to troubleshooting, suddently many hours is gone and lot of frustration :roll: :roll: :lol: :lol:

Br Jorgen.

Steve-Matrix
Matrix Staff
Posts: 1234
Joined: Sat Dec 05, 2020 10:32 am
Has thanked: 167 times
Been thanked: 277 times

Re: Pic12629 + Pic12f675 not working!

Post by Steve-Matrix »

One thing you could try is to replace the config data in the non-working (v9) HEX file with those in the working (v5) HEX file and then send directly using PPP. That would rule out an issue with the config data being generated by Flowcode. It will be the complete line near the bottom of the HEX file beginning with ":02400E00".

jgu1
Posts: 602
Joined: Thu Dec 03, 2020 8:25 pm
Location: Denmark
Has thanked: 495 times
Been thanked: 132 times

Re: Pic12629 + Pic12f675 not working!

Post by jgu1 »

Hi Steve!

Test your suggest, it doesn´t work either, same result as if I use FC9. ?

Jorgen

Steve-Matrix
Matrix Staff
Posts: 1234
Joined: Sat Dec 05, 2020 10:32 am
Has thanked: 167 times
Been thanked: 277 times

Re: Pic12629 + Pic12f675 not working!

Post by Steve-Matrix »

Hi Jorgen,

Thanks for your patience in this. Another thought - you could try customising the C code for the output icons in your program to see if these allow it to work. See attached.
Attachments
629 customised.fcfx
(7.07 KiB) Downloaded 52 times

jgu1
Posts: 602
Joined: Thu Dec 03, 2020 8:25 pm
Location: Denmark
Has thanked: 495 times
Been thanked: 132 times

Re: Pic12629 + Pic12f675 not working!

Post by jgu1 »

Hi Steve!

Your welcome. Sorry still nothing on the output?

Jorgen

BenR
Matrix Staff
Posts: 1707
Joined: Mon Dec 07, 2020 10:06 am
Has thanked: 435 times
Been thanked: 598 times

Re: Pic12629 + Pic12f675 not working!

Post by BenR »

Hello,

RIght I've been hunting around for a fix for this problem and it looks like it's not simple. It seems to be something deep ni the XC8 compiler that's stopping this from working. The only way I have managed to make it work is to copy and paste the compiler calls from MPLABX and this seems to have worked.

If you go to Help -> Library Updates and do a full database update then there is a new batch file available for PIC.

You can then point to this new batch file using the Build -> Compiler options

Change the compiler location from
$(fcddir)PIC\batch\pic_xc8_comp.bat

to
$(fcddir)PIC\batch\pic_xc8_comp_a.bat

Abnd click the save button at the top of the window.

Give this new setting a name and ensure that the Default compiler checkbox is ticked on the new settings before clicking OK.

Fingers crossed it should now compile and run on the device.

Let us know how you get on.

jgu1
Posts: 602
Joined: Thu Dec 03, 2020 8:25 pm
Location: Denmark
Has thanked: 495 times
Been thanked: 132 times

Re: Pic12629 + Pic12f675 not working!

Post by jgu1 »

I will try that Ben if only we don't risk it have any bad affecting on other devices, or do I have to switch back and forth depending on which device I need to use?

**EDIT. Working with the compiler option, I think I managed to change it and now I see the ligth ;) **

Perform a compiler test to target later. So far thank´s.

You hear :D

Jorgen

jgu1
Posts: 602
Joined: Thu Dec 03, 2020 8:25 pm
Location: Denmark
Has thanked: 495 times
Been thanked: 132 times

Re: Pic12629 + Pic12f675 not working!

Post by jgu1 »

Hi Ben!

Doesn´t work, after changing according your description. when compiling it start emidiately coming with errors. Even if I try to go back to $(fcddir)PIC\batch\pic_xc8_comp.bat it doesn´t work, either if I go back to Eblock setting?

I give it up and will not more, frustrations and used so long time one this bug. I am afraid to "destroy" other thing in FC9. When I use these tiny device I may use FC5.

Is there a way I can get the "old " compiler option back in FC9 without reinstall FC9 so I am sure not have made any errors, please?


Jorgen
Attachments
Compiler.PNG
Compiler.PNG (48.05 KiB) Viewed 1834 times

BenR
Matrix Staff
Posts: 1707
Joined: Mon Dec 07, 2020 10:06 am
Has thanked: 435 times
Been thanked: 598 times

Re: Pic12629 + Pic12f675 not working!

Post by BenR »

Hi Jorgen,

Sorry I know it's frustrating, frustrating for us here too. Thanks for bearing with us while we try and work out the kinks.

I've not touched the original setting so that shouldn't be effected at all. Make sure you are ticking the Default Compiler checkbox when trying to go back to the E-block setting.

What errors are you getting? Are you using the default PIC compiler? We have two versions V7 (PIC) and V9 (PICv2) which are you using.

Can you send me your project and the .msg.txt file and I'll try and replicate here.

Post Reply