Skip to content

Incorrect/outdated code examples in documentation #270

Closed
@KingKeule

Description

@KingKeule

https://udsoncan.readthedocs.io/en/latest/index.html
Current: except InvalidResponseException, UnexpectedResponseException as e:
Correct: except (InvalidResponseException, UnexpectedResponseException) as e:

https://udsoncan.readthedocs.io/en/latest/udsoncan/examples.html
Current: req = services.ECUReset.make_request(reset_type=1, data=b'\x77\x88\x99')
Correct: req = udsoncan.services.ECUReset.make_request(reset_type=1)

Current: client.ecu_reset(reset_type=1, data=b'\x77\x88\x99')
Correct: client.ecu_reset(reset_type=1)

Current: import can.interfaces.vector import VectorBus
Correct: from can.interfaces.vector import VectorBus

Current: 0xF190 : udsoncan.AsciiCodec(15) # Codec that read ASCII string. We must tell the length of the string
Correct: 0xF190 : udsoncan.AsciiCodec(17) # Codec that read ASCII string. We must tell the length of the string

Current: print(vin) # 'ABCDE0123456789' (15 chars)
Correct: print(vin) # 'ABCDEFG0123456789' (17 chars)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions