Page 3 of 4
Re: Pic12629 + Pic12f675 not working!
Posted: Wed Jul 27, 2022 1:47 pm
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.
Re: Pic12629 + Pic12f675 not working!
Posted: Thu Jul 28, 2022 8:27 am
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
Br Jorgen.
Re: Pic12629 + Pic12f675 not working!
Posted: Thu Jul 28, 2022 9:41 am
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".
Re: Pic12629 + Pic12f675 not working!
Posted: Thu Jul 28, 2022 9:24 pm
by jgu1
Hi Steve!
Test your suggest, it doesn´t work either, same result as if I use FC9. ?
Jorgen
Re: Pic12629 + Pic12f675 not working!
Posted: Fri Jul 29, 2022 11:01 am
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.
Re: Pic12629 + Pic12f675 not working!
Posted: Fri Jul 29, 2022 7:06 pm
by jgu1
Hi Steve!
Your welcome. Sorry still nothing on the output?
Jorgen
Re: Pic12629 + Pic12f675 not working!
Posted: Mon Aug 01, 2022 4:16 pm
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.
Re: Pic12629 + Pic12f675 not working!
Posted: Tue Aug 02, 2022 6:51 am
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
Jorgen
Re: Pic12629 + Pic12f675 not working!
Posted: Wed Aug 03, 2022 6:47 am
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
Re: Pic12629 + Pic12f675 not working!
Posted: Wed Aug 03, 2022 10:02 am
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.