Get idents when screen is loading
This commit is contained in:
parent
957c44e9a2
commit
b2dba05257
@ -273,6 +273,22 @@ def run( elm, ecu, command, data ):
|
|||||||
paramToSend = ""
|
paramToSend = ""
|
||||||
params = getValuesToChange(title)
|
params = getValuesToChange(title)
|
||||||
|
|
||||||
|
if params:
|
||||||
|
idRangeKey = identsKeys[identsKeys.keys()[rangeKey]]
|
||||||
|
|
||||||
|
for k,v in params.iteritems():
|
||||||
|
if v in identsList.keys():
|
||||||
|
identsList[k] = ecu.get_id(identsList[v], 1)
|
||||||
|
else:
|
||||||
|
identsList[k] = v
|
||||||
|
|
||||||
|
for idKey in range(idRangeKey['begin'], idRangeKey['end'] + 1):
|
||||||
|
# print str(idKey), identsList["D" + str(idKey)]
|
||||||
|
if identsList["D" + str(idKey)].startswith("ID"):
|
||||||
|
identsList["D" + str(idKey)] = ecu.get_id(identsList["D" + str(idKey)], 1)
|
||||||
|
paramToSend += identsList["D" + str(idKey)]
|
||||||
|
# print str(idKey), identsList["D" + str(idKey)]
|
||||||
|
|
||||||
clearScreen()
|
clearScreen()
|
||||||
|
|
||||||
print mainText
|
print mainText
|
||||||
@ -305,21 +321,6 @@ def run( elm, ecu, command, data ):
|
|||||||
ch = raw_input('Press ENTER to exit')
|
ch = raw_input('Press ENTER to exit')
|
||||||
return
|
return
|
||||||
|
|
||||||
idRangeKey = identsKeys[identsKeys.keys()[rangeKey]]
|
|
||||||
|
|
||||||
for k,v in params.iteritems():
|
|
||||||
if v in identsList.keys():
|
|
||||||
identsList[k] = ecu.get_id(identsList[v], 1)
|
|
||||||
else:
|
|
||||||
identsList[k] = v
|
|
||||||
|
|
||||||
for idKey in range(idRangeKey['begin'], idRangeKey['end'] + 1):
|
|
||||||
# print str(idKey), identsList["D" + str(idKey)]
|
|
||||||
if identsList["D" + str(idKey)].startswith("ID"):
|
|
||||||
identsList["D" + str(idKey)] = ecu.get_id(identsList["D" + str(idKey)], 1)
|
|
||||||
paramToSend += identsList["D" + str(idKey)]
|
|
||||||
# print str(idKey), identsList["D" + str(idKey)]
|
|
||||||
|
|
||||||
print
|
print
|
||||||
response = ecu.run_cmd(command,paramToSend)
|
response = ecu.run_cmd(command,paramToSend)
|
||||||
print
|
print
|
||||||
|
Loading…
x
Reference in New Issue
Block a user