EB-006 and PPPv3 can not ID chip
Moderator: Benj
-
- Flowcode v5 User
- Posts: 118
- Joined: Wed Jun 29, 2011 1:09 pm
- Has thanked: 17 times
- Been thanked: 6 times
- Contact:
EB-006 and PPPv3 can not ID chip
Hi,
I am trying to program a file onto a PIC 18F4525 but I am having difficulty in getting flowcode and PPPv3 to recognise this MCU. 90% of the time it says "cannot ID onboard chip" or "USB not connected". Sometimes it will recognise the chip and program it or sometes it will stop half way and again say can not ID onboard chip.
I have managed to get the mcu program a couple of times and it does work but the program runs very slow. There are a lot of settings in the configuration screen therefore I have been tinckering with settings that I understand such as "Extended cpu" which is off, " watchdog timer" which is off. I am not sure where to set the oscilator as there are quite a few options for that one. What should I set it to if I intend on using the internal oscilator inside 18F4525?
I was going to try and program a 1 second flasher onto the chip bit so far nothing will recognise the mcu.
Any suggestions will be very gratefull.
Thanks
Phil
I am trying to program a file onto a PIC 18F4525 but I am having difficulty in getting flowcode and PPPv3 to recognise this MCU. 90% of the time it says "cannot ID onboard chip" or "USB not connected". Sometimes it will recognise the chip and program it or sometes it will stop half way and again say can not ID onboard chip.
I have managed to get the mcu program a couple of times and it does work but the program runs very slow. There are a lot of settings in the configuration screen therefore I have been tinckering with settings that I understand such as "Extended cpu" which is off, " watchdog timer" which is off. I am not sure where to set the oscilator as there are quite a few options for that one. What should I set it to if I intend on using the internal oscilator inside 18F4525?
I was going to try and program a 1 second flasher onto the chip bit so far nothing will recognise the mcu.
Any suggestions will be very gratefull.
Thanks
Phil
- Enamul
- Posts: 1772
- Joined: Mon Mar 05, 2012 11:34 pm
- Location: Nottingham, UK
- Has thanked: 271 times
- Been thanked: 814 times
- Contact:
Re: EB-006 and PPPv3 can not ID chip
Hi,
For most of the 18 series PIC, if you are using EB006 board to program IC, you have to remove all the other E-blocks or any circuit connection from ports specially from PORTB.
It's better to disable watchdog timer, extended cpu mode, stack overflow, lvp mode.
For most of the 18 series PIC, if you are using EB006 board to program IC, you have to remove all the other E-blocks or any circuit connection from ports specially from PORTB.
It's better to disable watchdog timer, extended cpu mode, stack overflow, lvp mode.
- DavidA
- Matrix Staff
- Posts: 1076
- Joined: Fri Apr 23, 2010 2:18 pm
- Location: Matrix Multimedia Ltd
- Has thanked: 58 times
- Been thanked: 258 times
- Contact:
Re: EB-006 and PPPv3 can not ID chip
As Enamul suggested, removing additional circuitry can help when programming, also, ensure you are powering the board correctly is essential, with a stable 13.5v in the PSU will give the most reliable results, programming by LVP if you are doing that isnt advised as it is flaky at best.
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: EB-006 and PPPv3 can not ID chip
Hello Phil,
The internal oscillator will by default run at 8MHz. Make sure you change the clock speed in the project options to match this or your delays will run slowly.
The config settings for the internal osc should look something like this.
The internal oscillator will by default run at 8MHz. Make sure you change the clock speed in the project options to match this or your delays will run slowly.
The config settings for the internal osc should look something like this.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
-
- Flowcode v5 User
- Posts: 118
- Joined: Wed Jun 29, 2011 1:09 pm
- Has thanked: 17 times
- Been thanked: 6 times
- Contact:
Re: EB-006 and PPPv3 can not ID chip
Thank you evryone for your reply. I have tried programming the mcu with the EB006 board without anything else connected to the board and that didn't work. I have not tried using an external PSU with the board as I don't have one yet but I do have a good quality and regulated 12v bench type psu - is 12v to low for this? If it is I will buy a 13.5v psu.
Benj - In my project options the simulator is set to run as fast as possible and the frequency is set to the quickest option which I think is 4MHz, not quite sure off hand but do I just make sure this is set to the highest setting to speed up the project?
Could the pic chip be faulty as it works sometimes and other times the PPPv3 software can't ID the chip?
Thanks again, I will try all your sugeations later this evening
Benj - In my project options the simulator is set to run as fast as possible and the frequency is set to the quickest option which I think is 4MHz, not quite sure off hand but do I just make sure this is set to the highest setting to speed up the project?
Could the pic chip be faulty as it works sometimes and other times the PPPv3 software can't ID the chip?
Thanks again, I will try all your sugeations later this evening
- Enamul
- Posts: 1772
- Joined: Mon Mar 05, 2012 11:34 pm
- Location: Nottingham, UK
- Has thanked: 271 times
- Been thanked: 814 times
- Contact:
Re: EB-006 and PPPv3 can not ID chip
Highest possible setting for clock for this chip in flowcode is 40 MHz not 4 MHz. so please make sure that is 4MHz (4,000,000 not 40,00,000).In my project options the simulator is set to run as fast as possible and the frequency is set to the quickest option which I think is 4MHz, not quite sure off hand but do I just make sure this is set to the highest setting to speed up the project?
I don't think so..If it is faulty you should not be able to find it working single time.Could the pic chip be faulty as it works sometimes and other times the PPPv3 software can't ID the chip?
The only issue I can see is your supply voltage. I would suggest you to try to write a PIC16f877a using your EB006 board with your 12V supply if that works fine in that case power supply isn't an issue. Can you please let us know which version of EB006 you have? I mean EB006-00-X is written in your EB006 board. Can you fill up the X....it will let help us to know the problem as I had similar problem with EB006-00-6 version.I have not tried using an external PSU with the board as I don't have one yet but I do have a good quality and regulated 12v bench type psu - is 12v to low for this? If it is I will buy a 13.5v psu.
-
- Flowcode v5 User
- Posts: 118
- Joined: Wed Jun 29, 2011 1:09 pm
- Has thanked: 17 times
- Been thanked: 6 times
- Contact:
Re: EB-006 and PPPv3 can not ID chip
Hi,
The programmer is an EB-006-00-8, It is roughly 6 or 7 months old maybe even a little older. I have to hand a regulated 18vdc power supply so I used that and made a simple voltage regulator using an LM317 voltage regulator and adjusted that to deliver 13.5vdc which seemed to solve the problem with the PPPv3 program not finding the MCU therefore I have managed to be able to change settings and try various clock speeds. I have tried 4MHz and also tried 8MHz but this makes no difference in speed and the clock speed still is slow. I have a 1 second flasher which is used to alternate a message on an lcd display. Instead of the message changing every second it takes 5 seconds for each change to happen on hardware.
Any ideas on what I could do in order to speed up the MCU to match the simulator speed?
Thanks again for your help.
P.S I attach the fcf of my flasher so that you can have a look.
Phil
The programmer is an EB-006-00-8, It is roughly 6 or 7 months old maybe even a little older. I have to hand a regulated 18vdc power supply so I used that and made a simple voltage regulator using an LM317 voltage regulator and adjusted that to deliver 13.5vdc which seemed to solve the problem with the PPPv3 program not finding the MCU therefore I have managed to be able to change settings and try various clock speeds. I have tried 4MHz and also tried 8MHz but this makes no difference in speed and the clock speed still is slow. I have a 1 second flasher which is used to alternate a message on an lcd display. Instead of the message changing every second it takes 5 seconds for each change to happen on hardware.
Any ideas on what I could do in order to speed up the MCU to match the simulator speed?
Thanks again for your help.
P.S I attach the fcf of my flasher so that you can have a look.
Phil
- Attachments
-
- 16F887_LCD_test for pic 18f4525.fcf
- (8.5 KiB) Downloaded 359 times
- Enamul
- Posts: 1772
- Joined: Mon Mar 05, 2012 11:34 pm
- Location: Nottingham, UK
- Has thanked: 271 times
- Been thanked: 814 times
- Contact:
Re: EB-006 and PPPv3 can not ID chip
Hi,
EB006-00-8 is the latest version. So no problem in version issue. Only problem was power supply in that case. I have tried to open your attached program in FCV4.5 as you are v4 user. But can't open that in v4 and have to open in FCV5.4. Your configuration setting wasn't correct. I have changed that for internal clock.
But the problem I have seen from the datasheet of the PIC18f4525 is the reset default clock frequency is 1 MHz not 4MHz. That's why your clock is running at 1 MHz not in 4 MHz. To set 4 MHz, you have to add the following code in c code...
I have added that in your program..please try that and let us know.
EB006-00-8 is the latest version. So no problem in version issue. Only problem was power supply in that case. I have tried to open your attached program in FCV4.5 as you are v4 user. But can't open that in v4 and have to open in FCV5.4. Your configuration setting wasn't correct. I have changed that for internal clock.
But the problem I have seen from the datasheet of the PIC18f4525 is the reset default clock frequency is 1 MHz not 4MHz. That's why your clock is running at 1 MHz not in 4 MHz. To set 4 MHz, you have to add the following code in c code...
Code: Select all
osccon = 0x6E;
- Attachments
-
- 16F887_LCD_test for pic 18f4525.fcf
- (8.5 KiB) Downloaded 363 times
-
- Flowcode v5 User
- Posts: 118
- Joined: Wed Jun 29, 2011 1:09 pm
- Has thanked: 17 times
- Been thanked: 6 times
- Contact:
Re: EB-006 and PPPv3 can not ID chip
Hi,
Thanks for midifying that. I shall give that a try this evening. The fcf file was originaly put together on fc4 but I made some changes using the latest version of fc5 which is probably why you couldn't open the file. I think I posted the wrong one - the file I posted on here was the original with out the changes made to the configurations so thanks for changing that for me as I now can compare it to what I have.
Thanks again,
Phil
Thanks for midifying that. I shall give that a try this evening. The fcf file was originaly put together on fc4 but I made some changes using the latest version of fc5 which is probably why you couldn't open the file. I think I posted the wrong one - the file I posted on here was the original with out the changes made to the configurations so thanks for changing that for me as I now can compare it to what I have.
Thanks again,
Phil
-
- Flowcode v5 User
- Posts: 118
- Joined: Wed Jun 29, 2011 1:09 pm
- Has thanked: 17 times
- Been thanked: 6 times
- Contact:
Re: EB-006 and PPPv3 can not ID chip
Hi,
After trying the new fcf file for some reason it won't compile to hex for the programmer. I have copied and pasted the error message that appears on the screen:-
Title:
Description:
Generated by: Flowcode v5.4.0.0
Date: Friday, September 21, 2012 19:44:40
Licence: Professional
Registered to: philip davies
Licence key: EKRKXZ
http://www.matrixmultimedia.com
Launching the compiler...
C:\Program Files (x86)\Flowcode\v5\Tools\boostc\boostc_pic18_flowcode.exe -v -t PIC18F4525 "16F887_LCD_test%20for%20pic%2018f4525-1.c"
BoostC Optimizing C Compiler Version 7.04 (for PIC18 architecture)
http://www.sourceboost.com
Copyright(C) 2004-2011 Pavel Baranov
Copyright(C) 2004-2011 David Hobday
Licensed to FlowCode User under Single user Pro License for 1 node(s)
Limitations: PIC18 max code size:Unlimited, max RAM banks:Unlimited
16F887_LCD_test%20for%20pic%2018f4525-1.c
Starting preprocessor: C:\PROGRA~2\Flowcode\v5\Tools\boostc\pp.exe 16F887_LCD_test%20for%20pic%2018f4525-1.c -i C:\PROGRA~2\Flowcode\v5\Tools\boostc\include -d _PIC18F4525 -la -c2 -o 16F887_LCD_test%20for%20pic%2018f4525-1.pp -v -d _BOOSTC -d _PIC18 -d _CHAR_INDEX
runtime error R6002
- floating point not loaded
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
Is it something to do with "osccon = 0x6E;"?
Thanks
Phil
After trying the new fcf file for some reason it won't compile to hex for the programmer. I have copied and pasted the error message that appears on the screen:-
Title:
Description:
Generated by: Flowcode v5.4.0.0
Date: Friday, September 21, 2012 19:44:40
Licence: Professional
Registered to: philip davies
Licence key: EKRKXZ
http://www.matrixmultimedia.com
Launching the compiler...
C:\Program Files (x86)\Flowcode\v5\Tools\boostc\boostc_pic18_flowcode.exe -v -t PIC18F4525 "16F887_LCD_test%20for%20pic%2018f4525-1.c"
BoostC Optimizing C Compiler Version 7.04 (for PIC18 architecture)
http://www.sourceboost.com
Copyright(C) 2004-2011 Pavel Baranov
Copyright(C) 2004-2011 David Hobday
Licensed to FlowCode User under Single user Pro License for 1 node(s)
Limitations: PIC18 max code size:Unlimited, max RAM banks:Unlimited
16F887_LCD_test%20for%20pic%2018f4525-1.c
Starting preprocessor: C:\PROGRA~2\Flowcode\v5\Tools\boostc\pp.exe 16F887_LCD_test%20for%20pic%2018f4525-1.c -i C:\PROGRA~2\Flowcode\v5\Tools\boostc\include -d _PIC18F4525 -la -c2 -o 16F887_LCD_test%20for%20pic%2018f4525-1.pp -v -d _BOOSTC -d _PIC18 -d _CHAR_INDEX
runtime error R6002
- floating point not loaded
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
Is it something to do with "osccon = 0x6E;"?
Thanks
Phil
- Enamul
- Posts: 1772
- Joined: Mon Mar 05, 2012 11:34 pm
- Location: Nottingham, UK
- Has thanked: 271 times
- Been thanked: 814 times
- Contact:
Re: EB-006 and PPPv3 can not ID chip
Can you post the flowcode you have tried to compile so that I can see whether I can replicate that or not?
I have tried to compile the version I posted earlier that compiles fine..
I have tried to compile the version I posted earlier that compiles fine..
-
- Flowcode v5 User
- Posts: 118
- Joined: Wed Jun 29, 2011 1:09 pm
- Has thanked: 17 times
- Been thanked: 6 times
- Contact:
Re: EB-006 and PPPv3 can not ID chip
Hi,
I tried to compiled the file you posted on here - I will attach it to this message. I haven't modified any settings so it should be as you set it.
Many thanks,
Phil
I tried to compiled the file you posted on here - I will attach it to this message. I haven't modified any settings so it should be as you set it.
Many thanks,
Phil
- Attachments
-
- 16F887_LCD_test%20for%20pic%2018f4525-1.fcf
- (8.5 KiB) Downloaded 308 times
-
- Matrix Staff
- Posts: 9520
- Joined: Sat May 05, 2007 2:27 pm
- Location: Northamptonshire, UK
- Has thanked: 2585 times
- Been thanked: 3815 times
- Contact:
Re: EB-006 and PPPv3 can not ID chip
The compile error will be caused by the file name of your flowchart.
Just rename to something like:
16F887_LCD_test-1.fcf
Then recompile.
Martin
Just rename to something like:
16F887_LCD_test-1.fcf
Then recompile.
Martin
Martin
-
- Flowcode v5 User
- Posts: 118
- Joined: Wed Jun 29, 2011 1:09 pm
- Has thanked: 17 times
- Been thanked: 6 times
- Contact:
Re: EB-006 and PPPv3 can not ID chip
Hi Martin,
You are correct with the file name. I thought that the file could be corrupt so I downloaded it again using internet explorer instead of safari and it compiled fine this time.
Hi Enamul,
After trying the modifications you made the test code for the display works but the delay still is quite slow on my hardware. Is it possible to use c. code in order to speed up the clock frequency a bit more?
Thanks for your help
Phil
You are correct with the file name. I thought that the file could be corrupt so I downloaded it again using internet explorer instead of safari and it compiled fine this time.
Hi Enamul,
After trying the modifications you made the test code for the display works but the delay still is quite slow on my hardware. Is it possible to use c. code in order to speed up the clock frequency a bit more?
Thanks for your help
Phil
- Enamul
- Posts: 1772
- Joined: Mon Mar 05, 2012 11:34 pm
- Location: Nottingham, UK
- Has thanked: 271 times
- Been thanked: 814 times
- Contact:
Re: EB-006 and PPPv3 can not ID chip
Hi,
I have checked the configuration and it seems fine..Can you test the attached flasher lef program and let us know is it working fine or not?
I have checked the configuration and it seems fine..Can you test the attached flasher lef program and let us know is it working fine or not?
- Attachments
-
- PIC18f4525_flasher.fcf
- (7 KiB) Downloaded 288 times
- Enamul
- Posts: 1772
- Joined: Mon Mar 05, 2012 11:34 pm
- Location: Nottingham, UK
- Has thanked: 271 times
- Been thanked: 814 times
- Contact:
Re: EB-006 and PPPv3 can not ID chip
Fortunately I had a PIC18f4520 chip in hand and I have just tested that using the program you are using...that works fine with proper delay..
Note: PIC 18f4525 and 18f4520 are almost similar in config and internal clock issues.
So only issue in your case could be chip which shouldn't be as you able to write that..
Note: PIC 18f4525 and 18f4520 are almost similar in config and internal clock issues.
So only issue in your case could be chip which shouldn't be as you able to write that..
-
- Flowcode v5 User
- Posts: 118
- Joined: Wed Jun 29, 2011 1:09 pm
- Has thanked: 17 times
- Been thanked: 6 times
- Contact:
Re: EB-006 and PPPv3 can not ID chip
Hi Enamul,
I have also tried the flasher cod you just posted here and it also worked fine until I disconnected the psu, waited for a few seconds and then reconnected it. After reconnecting the flasher has stopped working. I have tried disconnecting the psu again and reconnecting a few times and that results in the led switching on and staying on for a second and it then goes off and stays off continuously.
Unfortunately I don't have another one to replace it with.
Phil
I have also tried the flasher cod you just posted here and it also worked fine until I disconnected the psu, waited for a few seconds and then reconnected it. After reconnecting the flasher has stopped working. I have tried disconnecting the psu again and reconnecting a few times and that results in the led switching on and staying on for a second and it then goes off and stays off continuously.
Unfortunately I don't have another one to replace it with.
Phil
-
- Flowcode v5 User
- Posts: 118
- Joined: Wed Jun 29, 2011 1:09 pm
- Has thanked: 17 times
- Been thanked: 6 times
- Contact:
Re: EB-006 and PPPv3 can not ID chip
I thought I would try to add c. code "osccon = 0x6E;" into my original project and it appears to have made the hardware run at the correct speed
The only thing that currently does not work on my project is the RC5 commands for the remote control. It did work with the original 16F887. I currently have the RC5 sensor connected to RB.0 pin on my hardware.
Any ideas on what is stopping the RC5 to work with the 18F4525?
Thanks
Phil
The only thing that currently does not work on my project is the RC5 commands for the remote control. It did work with the original 16F887. I currently have the RC5 sensor connected to RB.0 pin on my hardware.
Any ideas on what is stopping the RC5 to work with the 18F4525?
Thanks
Phil
- Enamul
- Posts: 1772
- Joined: Mon Mar 05, 2012 11:34 pm
- Location: Nottingham, UK
- Has thanked: 271 times
- Been thanked: 814 times
- Contact:
Re: EB-006 and PPPv3 can not ID chip
Nice to hear that your code works...
Can you post your RC5 program using PIC18f4525 so that I can have a look what's going wrong?
You can also have a look at John's post about RC5...
http://www.matrixmultimedia.com/mmforum ... 47&t=11227
Can you post your RC5 program using PIC18f4525 so that I can have a look what's going wrong?
You can also have a look at John's post about RC5...
http://www.matrixmultimedia.com/mmforum ... 47&t=11227
-
- Flowcode v5 User
- Posts: 118
- Joined: Wed Jun 29, 2011 1:09 pm
- Has thanked: 17 times
- Been thanked: 6 times
- Contact:
Re: EB-006 and PPPv3 can not ID chip
Hi Enamul,
Is it possible for me to e-mail the fcf file to you as it is to large to upload on here?
Thanks
Phil
Is it possible for me to e-mail the fcf file to you as it is to large to upload on here?
Thanks
Phil
- Enamul
- Posts: 1772
- Joined: Mon Mar 05, 2012 11:34 pm
- Location: Nottingham, UK
- Has thanked: 271 times
- Been thanked: 814 times
- Contact:
-
- Flowcode v5 User
- Posts: 118
- Joined: Wed Jun 29, 2011 1:09 pm
- Has thanked: 17 times
- Been thanked: 6 times
- Contact:
-
- Flowcode v5 User
- Posts: 118
- Joined: Wed Jun 29, 2011 1:09 pm
- Has thanked: 17 times
- Been thanked: 6 times
- Contact:
Re: EB-006 and PPPv3 can not ID chip
Hi Enamul,
Did you get a chance to look at the flowchart I sent you?
Thanks again for your help.
Phil
Did you get a chance to look at the flowchart I sent you?
Thanks again for your help.
Phil
- Enamul
- Posts: 1772
- Joined: Mon Mar 05, 2012 11:34 pm
- Location: Nottingham, UK
- Has thanked: 271 times
- Been thanked: 814 times
- Contact:
Re: EB-006 and PPPv3 can not ID chip
Hi Phil,
I have had a look but it's really tough to debug a such a large code..I think it's better to try step-by-step. You can simply trying basic RC5 as John's one. If it works fine then move on latter portion..
I have had a look but it's really tough to debug a such a large code..I think it's better to try step-by-step. You can simply trying basic RC5 as John's one. If it works fine then move on latter portion..
-
- Flowcode v5 User
- Posts: 118
- Joined: Wed Jun 29, 2011 1:09 pm
- Has thanked: 17 times
- Been thanked: 6 times
- Contact:
Re: EB-006 and PPPv3 can not ID chip
Hi,
I have given the RC5 fcf test file a try and it does work with no problems. I tried it with both 18f4525 and 16f887 and they seem to work.
Thanks for your time
phil
I have given the RC5 fcf test file a try and it does work with no problems. I tried it with both 18f4525 and 16f887 and they seem to work.
Thanks for your time
phil