Re : Tasking Compiler v8.6

Hi, I am new user to Tasking, previously having spent my time with Keil and hence have the tendency to import my old programming idiosyncrasies over.

I have a question here. Is it possible to allocate a certain memory location to a pointer in Tasking? I have the following code :

unsigned int* Base; //base address pointer

Base = 0xE20000 //base address

*Base = 0xFF //content of base address

And I got the following error message : "pointer mismatch at '=' "

I was trying to allocate a fixed memory area, starting at 0xE20000 for certain data. Does anyone have any idea how this is done?

thanks for your help.

regards wombat.

Reply to
wombat001
Loading thread data ...

On 6 Mar 2007 21:35:54 -0800, snipped-for-privacy@gmail.com wrote in comp.arch.embedded:

C and C++ (whichever you are trying to use) do not allow an integer value to be automatically converted to a pointer. You need to use a cast:

Base = (unsigned int *)0xE20000;

--
Jack Klein
Home: http://JK-Technology.Com
 Click to see the full signature
Reply to
Jack Klein

Hi jack,

"C and C++ (whichever you are trying to use) do not allow an integer value to be automatically converted to a pointer. "

Thanks, will try that out. I was actually able to pull this off with Keil, maybe they have automatic conversion steps or something.

regards Wombat

Reply to
wombat001

Its normally called 'non-conformance', but it could be that you didn't turn on all the trype checking.

Peter

Reply to
Peter Dickerson

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.