EasyManua.ls Logo

Mesa 7i92 - Elbpcom

Mesa 7i92
41 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
7I92 34
REFERENCE INFORMATION
LBP16
ELBPCOM
ELBPCOM is a very simple demo program in Python (2.x) to allow simple checking
of LBP16 host communication to the 7I92. ELBPCOM accepts hexadecimal LBP16
commands and data and returns hexadecimal results. Note that the timeout value will need
to be increased to about 2 seconds to try flash sector erase commands.
import socket
s = socket.socket(socket.AF_INET,socket.SOCK_DGRAM,0)
sip = "192.168.1.121"
sport = 27181
s.settimeout(.2)
while(2 >0):
sdata = raw_input ('>')
sdata = sdata.decode('hex')
s.sendto(sdata,(sip,sport))
try:
data,addr = s.recvfrom(1280)
print ('>'),data.encode('hex')
except socket.timeout:
print ('No answer')
Sample run:
>01420001 ; read hostmot2 cookie at 0x100
> fecaaa55 ; 7I92 returns 0x55AACAFE
>82492000 ; read EEPROM IP address at 0x0020
> 450a5863 ; 63:58:0A:45 = 99.88.10.69
;(for example)
>01D91A00025A82C920000100a8C0 ; write EEPROM IP address
;(at 0x0020) with
; C0:A8:0:1 = 192.168.0.1