Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions doc/source/udsoncan/examples.rst
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ In the following examples, we will request an ECU reset in 4 different ways. We
my_connection.send(req.get_payload())
payload = my_connection.wait_frame(timeout=1)
response = Response.from_payload(payload)
if response.service == service.ECUReset and response.code == Response.PositiveResponse and response.data == b'\x01':
if response.service == service.ECUReset and response.code == Response.Code.PositiveResponse and response.data == b'\x01':
print('Success!')
else:
print('Reset failed')
Expand All @@ -44,7 +44,7 @@ In the following examples, we will request an ECU reset in 4 different ways. We
payload = my_connection.wait_frame(timeout=1)
response = Response.from_payload(payload)
services.ECUReset.interpret_response(response)
if response.service == service.ECUReset and response.code == Response.PositiveResponse and response.service_data.reset_type_echo == 1:
if response.service == service.ECUReset and response.code == Response.Code.PositiveResponse and response.service_data.reset_type_echo == 1:
print('Success!')
else:
print('Reset failed')
Expand Down