CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to CCS Technical Support

Controller doesn`t start without programmer?!

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
stoyanoff



Joined: 20 Jul 2011
Posts: 375

View user's profile Send private message

Controller doesn`t start without programmer?!
PostPosted: Sat Oct 18, 2014 7:43 am     Reply with quote

Greetings. I`m using MPlab 8.91, CCS v5.025 and PIC18F67K22.
When I load the program, the microcontroller doesn`t start if the PICkit 3 programmer is not in the ICSP. It`s not in debug mode. When I turn on the power, I just have to put the PICkit into the connector and the controller starts. Otherwise it doesn`t.
Here are my fuses:

Code:

#include <18F67K22.h>
#fuses XT,NOWDT
#use delay(clock=10M)

Can you tell where to look for the problem?!
Thanks!
temtronic



Joined: 01 Jul 2010
Posts: 9218
Location: Greensville,Ontario

View user's profile Send private message

PostPosted: Sat Oct 18, 2014 7:51 am     Reply with quote

um....

how have you configured the _MCLR pin ??

I know silly to ask but I've been down THAT road before.....



are you powering the PIC from the PICkit instead of 'local' power?

I've done THAT as well.....


Jay
asmallri



Joined: 12 Aug 2004
Posts: 1634
Location: Perth, Australia

View user's profile Send private message Send e-mail Visit poster's website

Re: Controller doesn`t start without programmer?!
PostPosted: Sat Oct 18, 2014 8:09 am     Reply with quote

stoyanoff wrote:
Greetings. I`m using MPlab 8.91, CCS v5.025 and PIC18F67K22.
When I load the program, the microcontroller doesn`t start if the PICkit 3 programmer is not in the ICSP. It`s not in debug mode. When I turn on the power, I just have to put the PICkit into the connector and the controller starts. Otherwise it doesn`t.
Here are my fuses:

Code:

#include <18F67K22.h>
#fuses XT,NOWDT
#use delay(clock=10M)

Can you tell where to look for the problem?!
Thanks!


I do not use that specific PIC but the most common flaw with the PIC18F is the LVP where the fuse setting to enable LVP by default.

Try adding the fuse NOLVP
_________________
Regards, Andrew

http://www.brushelectronics.com/software
Home of Ethernet, SD card and Encrypted Serial Bootloaders for PICs!!


Last edited by asmallri on Sat Oct 18, 2014 12:13 pm; edited 1 time in total
stoyanoff



Joined: 20 Jul 2011
Posts: 375

View user's profile Send private message

PostPosted: Sat Oct 18, 2014 8:24 am     Reply with quote

I think this NOLVP helped!
Thanks!
PCM programmer



Joined: 06 Sep 2003
Posts: 21708

View user's profile Send private message

PostPosted: Sat Oct 18, 2014 8:53 am     Reply with quote

Quote:
#include <18F67K22.h>
#fuses XT,NOWDT
#use delay(clock=10M)

That's the wrong oscillator fuse for 10 MHz. In one of your old posts
you are using the HSH fuse (though it should be HSM for 10 MHz):
http://www.ccsinfo.com/forum/viewtopic.php?t=52538
Why did you change it to XT ?


Quote:
I think this NOLVP helped!

18F67K22 doesn't support LVP mode. There is no LVP config bit.
There is no NOLVP fuse. Using it causes the build to fail:
Quote:

Executing: "C:\Program files\Picc\CCSC.exe" +FH "PCH_Test.c" +DF +LY -T -A +M -Z +Y=9 +EA #__18F67K22=TRUE
*** Error 111 "PCH_Test.c" Line 2(7,23): Unknown keyword in #FUSES "NOLVP"
1 Errors, 0 Warnings.
Build Failed.

This was tested with vs. 5.025.

18F67K22 data sheet:
http://ww1.microchip.com/downloads/en/DeviceDoc/39960d.pdf

What are you doing ?

Do you have MPLAB configured for the correct PIC that you are using ?
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group