File tree Expand file tree Collapse file tree 4 files changed +17
-17
lines changed
ui/console/command_dispatcher Expand file tree Collapse file tree 4 files changed +17
-17
lines changed Original file line number Diff line number Diff line change @@ -56,8 +56,8 @@ module UDSErrors
56
56
0x78 => "RCRRP" ,
57
57
0x7E => "SFNSIAS" ,
58
58
0x7F => "SNSIAS" ,
59
- 0x81 => "RTH " ,
60
- 0x82 => "RTL " ,
59
+ 0x81 => "RPMTH " ,
60
+ 0x82 => "RPMTL " ,
61
61
0x83 => "EIR" ,
62
62
0x84 => "EINR" ,
63
63
0x85 => "ERTTL" ,
Original file line number Diff line number Diff line change @@ -219,7 +219,7 @@ def cmd_isotpsend(*args)
219
219
bytes = data . scan ( /../ ) # Break up data string into 2 char (byte) chunks
220
220
if bytes . size > 8
221
221
print_error ( "Data section can only contain a max of 8 bytes (for now)" )
222
- return result
222
+ return
223
223
end
224
224
opt = { }
225
225
opt [ 'TIMEOUT' ] = timeout unless timeout . nil?
@@ -281,7 +281,15 @@ def cmd_testerpresent(*args)
281
281
end
282
282
return
283
283
end
284
- unless stop
284
+ if stop
285
+ if self . tpjobs [ stopid ]
286
+ self . tpjobs [ stopid ] . kill
287
+ self . tpjobs [ stopid ] = nil
288
+ print_status ( "Stopped TesterPresent #{ stopid } " )
289
+ else
290
+ print_error ( "TesterPresent #{ stopid } was not running" )
291
+ end
292
+ else
285
293
jid = self . tpjob_id
286
294
print_status ( "Starting TesterPresent sender (#{ self . tpjob_id } )" )
287
295
self . tpjob_id += 1
@@ -300,14 +308,6 @@ def cmd_testerpresent(*args)
300
308
self . tpjobs [ myjid ] = nil
301
309
print_status ( "TesterPreset #{ myjid } has stopped (#{ ::Thread . current [ :args ] . inspect } )" )
302
310
end
303
- else
304
- if self . tpjobs [ stopid ]
305
- self . tpjobs [ stopid ] . kill
306
- self . tpjobs [ stopid ] = nil
307
- print_status ( "Stopped TesterPresent #{ stopid } " )
308
- else
309
- print_error ( "TesterPresent #{ stopid } was not running" )
310
- end
311
311
end
312
312
end
313
313
Original file line number Diff line number Diff line change @@ -219,10 +219,10 @@ def cmd_status(*args)
219
219
print_status ( "Device: #{ status [ 'device_name' ] } " ) if status . key? 'device_name'
220
220
print_status ( "FW Version: #{ status [ 'fw_version' ] } " ) if status . key? 'fw_version'
221
221
print_status ( "HW Version: #{ status [ 'hw_version' ] } " ) if status . key? 'hw_version'
222
- print_status ( "Uptime: #{ stats [ " uptime" ] } seconds" ) if stats . key? " uptime"
223
- print_status ( "Packets Sent: #{ stats [ " packet_stats" ] } " ) if stats . key? " packet_stats"
224
- print_status ( "Last packet Sent: #{ Time . at ( stats [ " last_request" ] ) } " ) if stats . key? " last_request"
225
- print_status ( "Voltage: #{ stats [ " voltage" ] } " ) if stats . key? " voltage" and not stats [ " voltage" ] == " not supported"
222
+ print_status ( "Uptime: #{ stats [ ' uptime' ] } seconds" ) if stats . key? ' uptime'
223
+ print_status ( "Packets Sent: #{ stats [ ' packet_stats' ] } " ) if stats . key? ' packet_stats'
224
+ print_status ( "Last packet Sent: #{ Time . at ( stats [ ' last_request' ] ) } " ) if stats . key? ' last_request'
225
+ print_status ( "Voltage: #{ stats [ ' voltage' ] } " ) if stats . key? ' voltage' and not stats [ ' voltage' ] == ' not supported'
226
226
end
227
227
228
228
def cmd_specialty_help
Original file line number Diff line number Diff line change @@ -290,7 +290,7 @@ def cmd_recv(*args)
290
290
arg [ 'blocksize' ] = blocksize unless blocksize == -1
291
291
arg [ 'timeout' ] = timeout unless timeout == -1
292
292
r = client . rftransceiver . rfrecv ( idx , arg )
293
- if r . key? ( 'data' ) && r . has_key ?( 'timestamp' )
293
+ if r . key? ( 'data' ) && r . key ?( 'timestamp' )
294
294
print_line ( " #{ r [ 'timestamp' ] } : #{ r [ 'data' ] . inspect } " )
295
295
else
296
296
print_line ( "Error" )
You can’t perform that action at this time.
0 commit comments