Skip to content

Fixed Issue with MCP3xxx Sensors #3

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

Merged
merged 3 commits into from
Apr 23, 2020
Merged

Fixed Issue with MCP3xxx Sensors #3

merged 3 commits into from
Apr 23, 2020

Conversation

P33ry
Copy link
Contributor

@P33ry P33ry commented Apr 23, 2020

MCP3xxx KeyError

There was a contradiction of the Pins of the MCP3xxx being specified as strings while the input was always casted to int.
The Pins are now referenced internally via Integer and correctly cast strings (containing numbers) to it. No Config change should be needed.

KeyErrors in mudpi.py

Also added stack traces to be printed for many KeyErrors inside mudpi.py to help with future troubleshooting.
This will not interrupt the program though and introduced traceback as an import.

I've also omitted keys like 'camera' as they are no list that can be kept empty.

P33ry added 3 commits April 23, 2020 15:09
Added stacktraces without interrupting/exiting whenever a KeyError while reading the config occurs.
Added traceback to the imports
Fixed an Issue where a correct configuration with an MCP3008 worker
and a Soil Sensor resulted in KeyErrors.

Internal pin reference is now made by int's.
Copy link
Member

@olixr olixr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I beleive the version would be v0.8.10 now. Minor tweak.

@olixr olixr merged commit ca42b38 into mudpi:master Apr 23, 2020
olixr pushed a commit that referenced this pull request Nov 11, 2020
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

Successfully merging this pull request may close these issues.

2 participants