OPEnSLab-OSU / Loom

Arduino library for Internet of Things Rapid Prototyping in environmental sensing
GNU General Public License v3.0
26 stars 3 forks source link

Test Loom_MB1232 - Winnie #168

Closed BGoto808 closed 2 years ago

BGoto808 commented 2 years ago

According to page 2 of the datasheet (https://www.maxbotix.com/documents/I2CXL-MaxSonar-EZ_Datasheet.pdf), there is one pin that needs to be pulled HIGH or LOW depending on the task its doing which is pin 2 on the sensor. Looking at the Loom code, there is no way for the user to specify which pin that is being used for that and as a result, the program hangs when the Feather tries to communicate with the sensor.

udellc commented 2 years ago

Let's make this low priority. No need to hold up Loom 3 on this.

winniiew commented 2 years ago

Note: Try to find an external library that supports I2C

udellc commented 2 years ago

I think we can ignore the Pin 2 thing and can use the Loom i2c functionality as-is. It's possible the default address of the sonar was changed during testing. Looking at the example code at the bottom of the datasheet, there are functions to set a new default address in addition to functions for taking a sonar reading. I think someone in CS with i2c experience could translate the bare example code into loom formatted functions. We would need to change the address back to factory default ourselves.

udellc commented 2 years ago

I am inclined to table this until after the Loom 3 release though.