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

Code Protection with PIC18F2525 problem

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



Joined: 01 May 2007
Posts: 5
Location: Jackson, MS

View user's profile Send private message

Code Protection with PIC18F2525 problem
PostPosted: Tue May 01, 2007 2:46 pm     Reply with quote

I can't seem to get the CCS compiler to set the code protection bits on the PIC18F2525. I have #FUSES CPB and #FUSES PROTECT=8 in my file. I thought those two would do the trick, but they don't seem to do anything. I don't know how to check this in the CCS program but have found the ID section in the MachX programmer that shows them to me. They are never set. I can manually set them in the MachX, but really would like the CCS compiler to program them properly.

The code is running fine, but I would like to understand the code protection fuses.
Any ideas would be appreciated.
(Note: I have also emailed CCS support just now and will update this message if they help out.).
PCM programmer



Joined: 06 Sep 2003
Posts: 21708

View user's profile Send private message

PostPosted: Tue May 01, 2007 2:57 pm     Reply with quote

You can see the fuse settings and the Config Word(s) at the bottom
of the .LST file, after you compile your program.

1. Post a small test program that shows the problem.
2. Post your compiler version.
rdburghard



Joined: 01 May 2007
Posts: 5
Location: Jackson, MS

View user's profile Send private message

Code Protection with PIC18F2525 problem CURED!
PostPosted: Thu May 03, 2007 4:44 pm     Reply with quote

Thanks for all the help. I didn't know I could see the programmed fuse settings in the .LST file. That is great. I haven't been looking at that file. I need to study the assembly code anyway to learn more about it. Gotten 'spoiled' by C.

Also, CCS support emailed me and discovered my error. I had a #device=ICD line in the file that I had forgotten about. Had it in there for testing. The code protection fuses will work if I comment out that one line.

David
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