Skip to content
This repository has been archived by the owner on Sep 10, 2024. It is now read-only.

Spot when pressure sensor has stalled and reset it. #95

Closed
wants to merge 5 commits into from

Conversation

amcewen
Copy link

@amcewen amcewen commented Mar 14, 2019

What does this implement/fix? Explain your changes.

This fixes the problem with the MPL3115A2 on the pysense board occasionally hanging. The code gets into an infinite loop if the sensor fails to respond over I2C.

The code now spots if there hasn't been a response, and resets the MPL3115A2 sensor. The failure is communicated to the main code as an exception, and no result is returned, but the next time the call is made the sensor will be reset and will return values again.

Does this close any currently open issues?

This will close issue #46.

Where has this been tested?

  • Tested on a pysense board with a LoPy4
  • (sysname='LoPy4', nodename='LoPy4', release='1.18.1.r1', version='v1.8.6-849-b0520f1 on 2018-08-29', machine='LoPy4 with ESP32', lorawan='1.0.2', sigfox='1.0.1')

@CLAassistant
Copy link

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.


Adrian McEwen seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.
You have signed the CLA already but the status is still pending? Let us recheck it.

gijsio added a commit that referenced this pull request Apr 23, 2021
@gijsio gijsio mentioned this pull request Apr 23, 2021
@gijsio
Copy link
Contributor

gijsio commented Apr 23, 2021

Hi,
Sorry for the extremely long delay.
Thanks a lot for the contribution, in the meantime we moved some files around and, instead, merged your solution in #146.

Best,
Gijs

@gijsio gijsio closed this Apr 23, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants