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

pic18f4525

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



Joined: 04 Apr 2006
Posts: 117
Location: Brasil

View user's profile Send private message Send e-mail MSN Messenger

pic18f4525
PostPosted: Tue May 16, 2006 4:47 pm     Reply with quote

hi people

my compiler's version is 3.221 and im having problems with pic 18f4525

does it compiler's version compiles softwares for 18f4525 ??

and which address i need to use to pre-write values on eeprom ??

0x2100 ??

att.
_________________
Andre
PCM programmer



Joined: 06 Sep 2003
Posts: 21708

View user's profile Send private message

PostPosted: Tue May 16, 2006 4:55 pm     Reply with quote

http://www.ccsinfo.com/forum/viewtopic.php?t=23208
andreluizeng



Joined: 04 Apr 2006
Posts: 117
Location: Brasil

View user's profile Send private message Send e-mail MSN Messenger

PostPosted: Tue May 16, 2006 5:08 pm     Reply with quote

thanks.. but doesnt work good

#rom 0xF0000 = {0x00, 0x00, 0x00, 0x00, 0x50, 0x00, 0x00, 0x00, 0x00, 0x00}

this is the values that i need, and after program the pic, i read again and got these values:

address 00 01 02 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F
0000 00 00 00 00 00 00 00 00 50 00 00 00 00 00 00 00
0001 00 00 00 ff ff ff ff....


whats wrong ?
_________________
Andre
PCM programmer



Joined: 06 Sep 2003
Posts: 21708

View user's profile Send private message

PostPosted: Tue May 16, 2006 5:17 pm     Reply with quote

Quote:
#rom 0xF0000

One important key to success in electronics is attention to detail.
andreluizeng



Joined: 04 Apr 2006
Posts: 117
Location: Brasil

View user's profile Send private message Send e-mail MSN Messenger

PostPosted: Tue May 16, 2006 5:17 pm     Reply with quote

i wrote wrong,

#rom 0xf000000....


regards.
_________________
Andre
andreluizeng



Joined: 04 Apr 2006
Posts: 117
Location: Brasil

View user's profile Send private message Send e-mail MSN Messenger

PostPosted: Tue May 16, 2006 5:18 pm     Reply with quote

my keyboard sux..

i put #rom 0xf00000


yeah...
_________________
Andre
andreluizeng



Joined: 04 Apr 2006
Posts: 117
Location: Brasil

View user's profile Send private message Send e-mail MSN Messenger

PostPosted: Tue May 16, 2006 5:32 pm     Reply with quote

hello again.

the eeprom's data size of 18f4525 is 2 bytes long..


now its working..

thanks
_________________
Andre
PCM programmer



Joined: 06 Sep 2003
Posts: 21708

View user's profile Send private message

PostPosted: Tue May 16, 2006 5:36 pm     Reply with quote

Quote:
the eeprom's data size of 18f4525 is 2 bytes long..

http://www.ccsinfo.com/forum/viewtopic.php?t=25373
andreluizeng



Joined: 04 Apr 2006
Posts: 117
Location: Brasil

View user's profile Send private message Send e-mail MSN Messenger

PostPosted: Tue May 16, 2006 5:47 pm     Reply with quote

hey pcm, thanks for the help..

so.. i have 2 more problems.


the pic is reseting when i use set_pwm1_duty (), and timer 0 stops working.


do you have some link talking about this ?

regards..
_________________
Andre
PCM programmer



Joined: 06 Sep 2003
Posts: 21708

View user's profile Send private message

PostPosted: Tue May 16, 2006 6:13 pm     Reply with quote

Disconnect the external components from the PWM output pin
on the PIC, and run the program. Does the PIC still reset ?
andreluizeng



Joined: 04 Apr 2006
Posts: 117
Location: Brasil

View user's profile Send private message Send e-mail MSN Messenger

PostPosted: Tue May 16, 2006 6:38 pm     Reply with quote

pcm, no the pic stops reset, but i was using a 16f877on this project and its working good, i had to change because 877 hasnt program memory enough to my application..

what i have to do to is works ?
_________________
Andre
PCM programmer



Joined: 06 Sep 2003
Posts: 21708

View user's profile Send private message

PostPosted: Tue May 16, 2006 6:54 pm     Reply with quote

It probably means that when you turn on the PWM pulses, the external
circuit draws too much current and loads down your power supply to
a voltage level which is below the Brownout Voltage setting. This will
cause the PIC to reset.

There could be some other reason. But look closely at your external
circuit. Look for problems with it.
andreluizeng



Joined: 04 Apr 2006
Posts: 117
Location: Brasil

View user's profile Send private message Send e-mail MSN Messenger

PostPosted: Tue May 16, 2006 6:56 pm     Reply with quote

ok, i will change de value of my brownout...

thanks for the help..

regards
_________________
Andre
PCM programmer



Joined: 06 Sep 2003
Posts: 21708

View user's profile Send private message

PostPosted: Wed May 17, 2006 12:18 am     Reply with quote

My suggestion was really to check if a Brownout reset is occuring when
the PWM output is enabled. If so, then improve the power supply so it
can supply enough current and keep proper regulation of the Vdd voltage.
andreluizeng



Joined: 04 Apr 2006
Posts: 117
Location: Brasil

View user's profile Send private message Send e-mail MSN Messenger

PostPosted: Wed May 17, 2006 10:33 am     Reply with quote

pcm,

im going to check it, but i dont really think that is the problem,
i changed the value of brownout detect to 2.1V and still not working.
but when i disconnect the load it doesnt happen.

maybe my power supply is not working well, but it was working with the same code on 16f877, just with 18f4525 im having this problem.

the difference is that 16f877 i dont need to set the value of brownout, and the 18f4525 i do.

regards.

(sorry for my english)
_________________
Andre
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