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

Exception with VA18B #882

Closed
bowsi opened this issue May 12, 2022 · 3 comments
Closed

Exception with VA18B #882

bowsi opened this issue May 12, 2022 · 3 comments
Labels
Milestone

Comments

@bowsi
Copy link

bowsi commented May 12, 2022

When using a VA18B multimeter the error "a bytes-like object is required, not 'int' "
occurs in function TEVA18Btemperature in source file comm.py at this line:
s201 = binascii.hexlify(r[1])
I have found that if this line (and the following eight or so similar lines) is changed to
s201 = binascii.hexlify(r[1].to_bytes(1,'big'))
then the exception goes away and the temperatures are correctly read.
I'm using PyCharm 2021.2 on Windows to debug this but first found the error when I installed Artisan on a linux machine recently.

image

@MAKOMO MAKOMO added the bug label May 13, 2022
@MAKOMO MAKOMO added this to the v2.6.2 milestone May 13, 2022
@MAKOMO
Copy link
Member

MAKOMO commented May 13, 2022

Excellent contribution! I just applied your fix to the current trunk. Could you please test if the current continuous build works for you as expected?

https://github.com/artisan-roaster-scope/artisan/releases/tag/continuous

@bowsi
Copy link
Author

bowsi commented May 13, 2022

Thanks Marko. I have tested and can confirm that the problem is now fixed.

@MAKOMO
Copy link
Member

MAKOMO commented May 13, 2022

Wow! That was fast. Thus I close this issue. Thanks again for your fix.

@MAKOMO MAKOMO closed this as completed May 13, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants