home *** CD-ROM | disk | FTP | other *** search
/ Power-Programmierung / CD1.mdf / lan / driver6s / getea.asm < prev    next >
Assembly Source File  |  1990-01-12  |  495b  |  27 lines

  1. ;put into the public domain by Russell Nelson, nelson@clutx.clarkson.edu
  2.  
  3. ether_byte    db    ?,?,?,?
  4.  
  5. get_address:
  6.     mov    cx,EADDR_LEN
  7. get_address_2:
  8.     push    cx
  9.     push    di
  10.     mov    di,offset ether_byte
  11.     call    get_hex
  12.     mov    al,cl            ;remember the number in al.
  13.     pop    di
  14.     pop    cx
  15.     jc    get_address_3        ;exit if no number at all.
  16.     stosb                ;store a byte.
  17.     cmp    byte ptr [si],':'    ;skip colons between bytes.
  18.     jne    get_address_4
  19.     inc    si
  20. get_address_4:
  21.     loop    get_address_2
  22.     clc
  23. get_address_3:
  24.     ret
  25.  
  26.  
  27.