Dec 20, 2004 #1 SphinX Advanced Member level 3 Joined Jan 25, 2002 Messages 822 Helped 58 Reputation 116 Reaction score 29 Trophy points 1,308 Location EGYPT Activity points 7,045 Salam, Code: BYTE far *Temp; Temp = (BYTE far *)0xA0005555; /* set up address to be A000:5555h */ *Temp = 0xAA; /* write data 0xAA to the address */ Please what does "far" mean here ? Thanks
Salam, Code: BYTE far *Temp; Temp = (BYTE far *)0xA0005555; /* set up address to be A000:5555h */ *Temp = 0xAA; /* write data 0xAA to the address */ Please what does "far" mean here ? Thanks
Dec 20, 2004 #2 M Moof Full Member level 2 Joined Nov 21, 2003 Messages 149 Helped 7 Reputation 14 Reaction score 3 Trophy points 1,298 Location Argentina Activity points 1,230 Re: BYTE far *Temp; Far, means that the pointer is double word address, insted of word. So you can point more than the segment your are working. (generaly Data segment).
Re: BYTE far *Temp; Far, means that the pointer is double word address, insted of word. So you can point more than the segment your are working. (generaly Data segment).
Dec 21, 2004 #3 C conkhicon Advanced Member level 4 Joined Aug 31, 2004 Messages 107 Helped 3 Reputation 6 Reaction score 0 Trophy points 1,296 Activity points 1,015 Re: BYTE far *Temp; Hi Far prefix mean that a variable declared have a size of LARGE MODE in memory mode. if you selected LARGE MODE in memory mode then Far don't need. Far only use when select COMPACT MODE or SMALL MODE but use LARGE MODE for a variable.(MIXER MODE)
Re: BYTE far *Temp; Hi Far prefix mean that a variable declared have a size of LARGE MODE in memory mode. if you selected LARGE MODE in memory mode then Far don't need. Far only use when select COMPACT MODE or SMALL MODE but use LARGE MODE for a variable.(MIXER MODE)
Dec 29, 2004 #4 A aamiralikhoja Member level 5 Joined Aug 11, 2004 Messages 90 Helped 1 Reputation 2 Reaction score 1 Trophy points 1,288 Activity points 708 Re: BYTE far *Temp; in small memory model pointer only poins to offset inside the segment but in far pointer both segment and offset are stored .this is only in 16 bit compilers.
Re: BYTE far *Temp; in small memory model pointer only poins to offset inside the segment but in far pointer both segment and offset are stored .this is only in 16 bit compilers.