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

memory problem on pic18f452

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



Joined: 09 Jun 2004
Posts: 25
Location: Monterey, CA

View user's profile Send private message

memory problem on pic18f452
PostPosted: Thu Aug 19, 2004 1:25 am     Reply with quote

Hi, there.
I have built in a tcp/ip ppp protocol stack on pic18f452 which is connected with a GPRS modem through RS232. As is known, the standard buffer of tcp/ip protocol stack should be 1024 bytes, but due to the RAM size of pic18f452, i have modify it into 256 bytes. It works fine if the data packet transmitted is less than 190 bytes. but if the data packet is bigger than 196 bytes, it won't work ... ...
anyone has good idea on that? Or for the declare of static array, can i put it on the FRAM (flash memory thr i2c)??

Thx in advanced!
treitmey



Joined: 23 Jan 2004
Posts: 1094
Location: Appleton,WI USA

View user's profile Send private message Visit poster's website

PostPosted: Thu Aug 19, 2004 8:18 am     Reply with quote

I think(I don't know for sure) that the FRAM would be to slow.
experiment and find out. I would try (2) 256 buffers. toggle between them.
buffer1[255]
buffer2[255]
store Rx data in 1 via and IRQ
while the I2C write happens on the other.

- - - - then swap - - -
AND by all means try to do the I2C FRAM write of all 255 bytes at once.

then maybe try 3-255 buffers or 4. Past 4 I think your done. The limiting factor then is probably the slow FRAM.

I would love to give you and equation that says YES or NO the FRAM is too slow,... but I don't have that info. Post your results.
puppie7777



Joined: 09 Jun 2004
Posts: 25
Location: Monterey, CA

View user's profile Send private message

PostPosted: Thu Sep 09, 2004 9:35 pm     Reply with quote

HI,
There! I am so sorry that i came back to this forum so late, cos leave for quite time.

For the problem of the RAM size of pic18f452, i have to modify the RWIN size for the receive window size advertising to a small buffer. For my application seems OK, cos no require of such high transmission rate.

Thx, anyway!
Guest








PostPosted: Fri Sep 10, 2004 3:15 am     Reply with quote

18F4525 and 18F4620 are now available with almost 4 K RAM !
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