value gets lost?

Hello,

I have a variable declared to an absolute memroy location:

#define H1Utol MVAR (unsigned short, 0x12301C)
and a function that starts like this:
void func (void)
{ unsigned short H1;

  H1 = H1Utol;
No matter what the value of H1Utol is at the moment the function is entered, H1 is zero after the assignment... for some reason.

The preprocessor output for these lines looks good:
 H1 = (*((unsigned short volatile far *) (0x12301C)));

What could be the problem?

Thank you,
Holger

More questions in this forum