Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Passing Through Raw Vehicle Response Info In Custom Commands #259

Open
peszaber opened this issue Feb 17, 2023 · 1 comment
Open

Passing Through Raw Vehicle Response Info In Custom Commands #259

peszaber opened this issue Feb 17, 2023 · 1 comment

Comments

@peszaber
Copy link

peszaber commented Feb 17, 2023

I'm currently trying to request some non-standard OBD Modes/Service IDs using the Custom Command feature, the "OBDCommand" object.

I'd like to be able to get the response back I get from the vehicle without any sort of decoding, however this does not seem to be possible. Using a decoder function within the OBDCommand object that just returns the same input, the only output I get when I query the custom command is "<obd.OBDResponse.OBDResponse at 0x1fc7ac58130>", which I assume is just the memory address of the object. However, if I enable debugging I can see that I am actually able to see the byte array response from the vehicle, but since this is not a part of the actual output I am unable to manipulate it further.

@peszaber peszaber changed the title Passing Through Raw CAN Info In Custom Commands Passing Through Raw Vehicle Response Info In Custom Commands Feb 17, 2023
@csurf
Copy link

csurf commented Jul 3, 2023

what you're looking for is the 'message' attribute for that response object that's returned by your custom command:

r = obd.query(my_custom_command)
print(r.message) # <--- your raw, un-decoded data should be here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants