-
Notifications
You must be signed in to change notification settings - Fork 34
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
Problem with this on a Pi Pico #33
Comments
I have never tried my library on the pico, can you give me some more details on how you installed it? Regards, |
I presume you have installed the Micropython port for the Pico https://github.com/micropython/micropython/tree/master/ports/rp2 from https://micropython.org/download/?port=rp2? In any case as this a microcontroller you probably need this version of that library https://github.com/chrisb2/pyb_ina219. The readme includes instructions for installing the logging library. I have never tried this library on the Pico, but I do have a Pico so could have a go at the weekend if you have any problems. regards, |
OK. Got muddled. Thought I was responding to a response to my ticket on the I2C GPS unit. With no battery connected to the voltage sensor I get: Voltage: 0.856 V Voltage: 0.856 V With a brand new 1.5v battery connected I get... Voltage: 0.696 V Voltage: 0.680 V With a brand new 9v battery I get Voltage: 0.796 V Voltage: 0.804 V Voltage: 0.804 V It just seems to be giving me very random figures and I just can't make sense of them. With a worn out 9v battery I get: Voltage: 0.732 V Voltage: 0.708 V Voltage: 0.704 V |
The code I'm using is... I think I took the logfile out.
|
The weird results sound like you may not have a common ground. A good explanation of required circuit can be found in https://www.rototron.info/raspberry-pi-ina219-tutorial/ Chris |
I had an interesting experience with a couple of other addons that I bought for the Pi Pico. One was an LCD display I was having issues with. It transpired that when I squeezed the display, the text appeared. Clearly a faulty display. That had me thinking about the INA219 and wondering if that too was faulty since we never want to believe something we have just purchased is already broken. Here's a photo of the offending INA219. Given that I've just had a pile of Buck converters that don't work, a broken LCD and now this - all from different suppliers on eBay - it sounds like I'm running into the same kind of situation I've had before. eBay has periods when nothing I buy from there ever works or is ever as described. I quit eBay for a few months and then go back and the stuff I order from then on is never faulty until the next period. I can't explain that as it defies logic what with it always being different suppliers and different products. So, I'm wondering about the INA219. I have a second INA219 but given that so much from eBay just hasn't been in working condition when it arrived, I might just toss it in the trash untested and go to somewhere like DigiKey or Mouser to buy another. |
R100 is 0.1 Ohms, this is the std shunt resistor value. Your INA219 breakout looks pretty much identical to mine. Maybe make a sketch of your circuit and attach a photo of it and I will see if anything comes to mind. Chris |
I tried this on a Pi Pico and this is what came up:
The text was updated successfully, but these errors were encountered: