Hi Tech Pic18f452 MediumConst

Microcontroller Topics
Post Reply
SukhdeepMankoo
Lieutenant
Lieutenant
Posts: 92
Joined: Tue Oct 27, 2009 7:50 pm

Hi Tech Pic18f452 MediumConst

Post by SukhdeepMankoo » Sat Nov 26, 2011 6:02 pm

Hi,
I am writing software in Hi Tech Pic IDE for Pic18f452. I have seen that when const code size comes in mediumconst. then i am not able to access the const data. But when i cut down the code, so that it fit into the smallconst. then i can access the const data.

how can i get my hand of mediumconst.


Routine used for accessing const data is
void f(cont unsigned char *p)
{ .............
}


Can anyone help me, how can i access when code comes in mediumconst. Note i have even check using
const far unsigned char *, but still not able to get.
User avatar
Shane
Captain
Captain
Posts: 226
Joined: Sun Jul 19, 2009 9:59 pm
Location: Jönköping, Sweden

Re: Hi Tech Pic18f452 MediumConst

Post by Shane » Mon Nov 28, 2011 12:55 am

There are limitations in compilers. If you are using HITECH C, this is likely the issue. Mostly you will need their Professional version. If you are using HITECH C, you can ask this question in their forum and let us know as well. I never faced this kind of issue since I use a professional version.
SukhdeepMankoo
Lieutenant
Lieutenant
Posts: 92
Joined: Tue Oct 27, 2009 7:50 pm

Re: Hi Tech Pic18f452 MediumConst

Post by SukhdeepMankoo » Wed Nov 30, 2011 9:16 am

Thanks,
Actually I have disabled the Table Read in configuration register. Now i have removed disable the table reading. All is working fine. Thanks to all of you for your support.
Post Reply

Return to “Microcontrollers”