Pi Pico Power Meter

For my electronic developments I need more than one multimeter to get the power. Here it is!

Similar projects worth following
Starting from
pellematrose has 3 orders / 0reviews
Ships from Germany
Based on Raspberry RP2040 controller and the INA219 current sensor it is possible to get very precise measurements of current flowing through a shunt resistor. Additionally it is possible to measure the system voltage and get the calculated power.

Everything is shown on a 0.96" OLED display.

I will use it as a power meter for my power electronic development. With two of them I could use it to calculate the efficiency.

With the two header rows it is possible to use nearly all pins of the controller.
Maybe one could use it as a MPPT controller for solar charging batteries?
Or monitor the energy flow in a offgrid installation like a yacht or a camper van?

Absolute ratings:
VBUS = 26V
ILoad = 3.2A @0.1Ohm Shunt

You can find all the data on my github.

  • USB Power Measurement

    Per-Simon Saal04/21/2023 at 13:42 0 comments

    Some Code adjustments made it possible to track the charging power of my old Nexus 10 tablet.

    With a button push the data are logged to a csv file. Another press will stop the logging.

    For a decade I was wondering why the charge performance is bad. I can see that the charging current is variing all the time up and down.

    After I took the photo I added the ground wire to get the voltage.

  • Housing ref 2

    Per-Simon Saal03/19/2023 at 18:37 0 comments

    I have reworked the 3D printable housing.

    Just have a look yourself:

    It came out a bit ugly due to a dirty printer bed...
    You can find the .step data on my github repo.

  • Next Revision - nice features

    Per-Simon Saal03/06/2023 at 16:24 0 comments

    During testing the Power Meter I discovered some minor things I wish I had done different.

    First, and most important I wanted to get rid of the pin headers to solder the MCU module. This only adds costs and is unconvenient.
    I also added some TVS diodes for the measurement inputs and a mouse bite divideable protoboard for the controller headers.

    Before, I got a message from PCBway that they would like to sponsor the next revision of PCBs.

    That's a really nice circumstance and I used the offer for new PCBs. It was the first time I ordered there.
    The PCBs are really nice - like I expected. The HASL finish looks very even and the silkscreen is very clear and sharp. One thing I did not expect was the outer milling of the boards. Often the outline is not that important than the dimensions on top of the FR4. But nothing caught my eye that was not finished perfectly and all the dimensions are bang on!
    All in all a very good job! Thank you very much!

  • Home sweet housing

    Per-Simon Saal02/22/2023 at 15:51 0 comments

    I finally got the printed housing from my friend.

    It looks already quite good but some dimensions are not correct. I also need to think about the different height of the components: headers, button, display.

    Let's see what I will think of...

  • Housing tadaa

    Per-Simon Saal02/11/2023 at 12:05 0 comments

    After some trouble designing a 3D printable housing I have a first prototype.

    I've ordered the 4 parts from a friend who has a 3D printer.

    This design I need to glue. Don't know if it is the best approach. Let's see when I have the parts in my hands.

    But have a view on the renderings I've got from Fusion360:

  • It becomes real

    Per-Simon Saal02/05/2023 at 11:40 0 comments

    My PCB order was deliverd yesterday.

    After a bit of soldering and testing - everything works!

    It feels really good to have some working hardware in the hands.

    With the battery and the two resistors I made a quick energy measurement of this disposable rechargeable Li-Ion battery from a vape pen.

    It should contain 2.025Wh. With my measurement I calculated 1.92Wh. That is quite good!

  • I don't want to interrupt you...

    Per-Simon Saal02/03/2023 at 15:32 0 comments

    ... but actually I do!

    I switched the push button mode from polling to interrupt mode.

    Now it is possible to log the data as .csv file on the onboard flash. Does anybody now what happens when the file exceeds the available space?

    Furthermore, I created a github repo to share my HW and SW files with you.

    Additional ideas in my mind:

    • Make a  daughterboard with more switches
    • Create a menu to make settings
      • Logging: save single data set, save continous, ...
      • Set voltage and current resolution
      • Measurement mode
      • Timings

  • GUI Ahoi!

    Per-Simon Saal01/31/2023 at 20:51 0 comments

    It was time for a nice GUI.

    Well a really nice GUI on 2cm² is hard to realize but at least I could make everything good readable.

    Due to the lack of different fonts and sizes in the default micropython library I searched for something easy to implement.

    And I found it! Peter Hinch has written a really nice library in micropython hat is based on the official drivers for the frame buffer and the SSD1306 OLED display I use. 

    With some modifications in the code it just runs perfectly on my Pi Pico!

    So, if you need a good GUI library that offers some fonts in different sizes, nice widgeds and is portable to many microcontrollers check his repo!

    Now, here are some pictures of my 'pages'. With a push button it is possible to move from one 'page' to another.

  • Custom PCB

    Per-Simon Saal01/28/2023 at 15:40 0 comments

    A custom PCB is a nice feature to move from the protoboard to reliable connections.

    My goal is to make a nice small and space saving PCB. Thus, I will not just plug breakout boards to their headers on the PCB but will solder them directly to the PCB.

    With one exeption: The RP2040. I don't want to face any trouble doing the connections on my PCB - Controller - Crystal - Flash. I would like to take an off the shelf part - like the Pi Pico. But as already meantioned it is to large for my application.

    My research led me to the RP2050 Femto which is a pretty nice approach to shrink the size. With a form factor of only 11x11mm it is just bearly bigger than the Controller itself. But unfortunately I coundn't find it to buy.

    I heard also of the RP2040 stamp which is also a very nice board because it contains some extra features the Pico doesn't have. But 25x25mm is an unlikely formfactor for my project.

    Next, coincidental I came across the RP2040 Nano which has a formfactor that suits my needs! Yes, not all pins are easy accessible but I don't need all the pins. It contains also some extra features like an reset button, a Neopixel LED and is future proof with a USB-C connector.

    That's the board I take!

    Next the PCB design wich is quite easy. I added another user button and two user LEDs.
    To make use of the (so far) unused pins I added two rows of female headers. Their distance is in multiple of 2.54mm to easy stack-up another PCB.

    The INA219 chip is addressable with all 16 addresses. One just need to change the position of the pull-up resistor.
    In default assembly only one 2512 sized 100mOhm shunt is populated, but with higher currents in mind I added a second unpopulated footprint in parallel.

    The screw terminal is the biggest component but also very robust and can hold wires up to 2.5mm².

    Everything important is labeled in the silkscreen.

    The PCB has a size of 75x30mm.

    All files will be available on my github when everything is confirmed.

    Now I might need a 3D printable housing...

  • Mockup tested

    Per-Simon Saal01/28/2023 at 15:19 0 comments

    First firmware prototype in python is done and all trouble with the libraries is solved.

    Currently used libraries:

    • ina219
      • Inspired by Vantonyan but finished in functionality

    Now it is possible to display Voltage, Current and Power on the display.

    The measurements are taken every second.


    • Get rid of sleep functions in the main loop
    • Enable button and LED functionality
    • Increase font size
    • Create pages to show single values in a big font size
    • Layout PCB

View all 10 project logs

Enjoy this project?



Hexastorm wrote 07/16/2023 at 10:57 point

great project, there is a lot of need for power and voltage meters at industrial sites. I work at a plant where we want to reduce energy usage. It would be great if there would be an open hardware IOT device which can measure current or voltage and sent it to the cloud Just current could be helpful as well. The idea is that you can sent people a message to turn of a device that shouldnt be on or seems to be not functioning. Imagine that current is too high for the device being off and too low for thw device being working.

  Are you sure? yes | no

Per-Simon Saal wrote 07/16/2023 at 16:24 point

Hey @Hexastorm,

thank your for your comment!

Reducing energy usage is an important thing nowadays.

I will think about an IoT PPPM. With some IOs left you could program to turn off the device also over WIFI. The device only needs to be attached to a (onboard) relay.

  Are you sure? yes | no

Gustavo Laureano wrote 01/28/2023 at 15:38 point

Here is one that I remember:

  Are you sure? yes | no

Per-Simon Saal wrote 01/28/2023 at 15:44 point

I now. There are also two more board that are smaller ;)

  Are you sure? yes | no

Similar Projects

Does this project spark your interest?

Become a member to follow this project and never miss any updates