Přidat otázku mezi oblíbenéZasílat nové odpovědi e-mailemVyřešeno Zjištění MAC adresy v Pascal/assembler/DOS programu pod XP

Až do Windows98SE mi bez problémů fungovala funkce MS-DOS EEh, která vrací MAC adresu síťové karty. Pod XP mi to ale hází nějaký hausnumero.
Zřejmě Xp už nepodporují "staré" MS-DOS služby.
Poradíte někdo jestli existuje něco takového i pod XP? Zatím Googluju bezúspěchu :-(

PROCEDURE GetNode( var hex_addr: string; var retcode: integer );
{ get the physical station address }

Const
   Hex_Set  :packed array[0..15] of char = '0123456789ABCDEF';

Begin { GetNode }
   {Get the physical address from the Network Card}
   Regs.Ah := $EE;
   regs.ds := 0;
   regs.es := 0;
   MsDos(Regs);
   hex_addr := '';
   hex_addr := hex_addr + hex_set[(regs.ch shr 4)];
   hex_addr := hex_addr + hex_set[(regs.ch and $0f)];
   hex_addr := hex_addr + hex_set[(regs.cl shr 4) ];
   hex_addr := hex_addr + hex_set[(regs.cl and $0f)];
   hex_addr := hex_addr + hex_set[(regs.bh shr 4)];
   hex_addr := hex_addr + hex_set[(regs.bh and $0f)];
   hex_addr := hex_addr + hex_set[(regs.bl shr 4)];
   hex_addr := hex_addr + hex_set[(regs.bl and $0f)];
   hex_addr := hex_addr + hex_set[(regs.ah shr 4)];
   hex_addr := hex_addr + hex_set[(regs.ah and $0f)];
   hex_addr := hex_addr + hex_set[(regs.al shr 4)];
   hex_addr := hex_addr + hex_set[(regs.al and $0f)];
   retcode := 0;
End; { Getnode }

Jsou zobrazeny jen nové odpovědi. Zobrazit všechny
Předmět Autor Datum
Tak hlásím, že problém je vyřešen, použil jsem jinou službu: E3h, která funguje i pod XP. Vlastně ob… poslední
JoDiK 12.03.2009 12:44
JoDiK

Zpět do poradny Odpovědět na původní otázku Nahoru