Jump to content
Sign in to follow this  
lutcho

asm error: not enough RAM

Recommended Posts

I'm working on a LCD panel and need to code the fonte table. I'm doing something like this:

 

char TabelaChr(char letter, char position){

char FontLookup[] ={

0x00, 0x00, 0x2f, 0x00, 0x00,   // !

0x24, 0x2a, 0x7f, 0x2a, 0x12,   // $

0xc4, 0xc8, 0x10, 0x26, 0x46,   // %

0x00, 0x60, 0x60, 0x00, 0x00,   // .

(and so on)

 

When compiling, SouceBoost 5.3 & 5.4 says: Not enough RAM.

If I delete parts of the table, it goes OK.

 

The point is that my code is quite small and the whole table has 225 chars and everything fits inside a 16F628 leaving a lot of room.

 

I would like to know how to fix this behaviour.

 

Regards,

Luiz Cressoni Filho

Brazil

Share this post


Link to post
Share on other sites
Guest Pavel

This is not a bug. A variable must fit into a register bank and array 'FontLookup' that you use in the code is too big for this.

 

Regards,

Pavel

Share this post


Link to post
Share on other sites
Guest Lutcho

Sorry for this. Just after I posted, I found out what was wrong:

 

This should be a CONST char[] and not a char[].

The compiler was trying to allocate register RAM for my table data.

OOps ;)

 

Anyway, thanks for the quick reply!

Regards

Share this post


Link to post
Share on other sites

Join the conversation

You are posting as a guest. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

×
×
  • Create New...