About: The tension between novelty and familiarity...

This is a casing for the ATTINYPOWERMETER authored by moononournation.

It can continuous measure the voltage(V), current(mA) and accumulated power usage(mWh). And also plot a simple graph to visualise the figures. As simple hookup guide is splashed on the OLED screen on startup.

The code has been forked and modified for a smaller OLED Screen.

The breakouts are screw terminals; male pins screwed in make for easy connections.

I suggest you breadboard the project based on moononournation's Instructable first. I looked for optimizations but could not improve on his original design. I considered adding pullups on the I2C lines but "if it ain't broken, don't fix it".

Teacher Notes

Teachers! Did you use this instructable in your classroom?
Add a Teacher Note to share how you incorporated it into your lesson.

Step 1: Materials and Tools

There is a full Bill of Material and Sourcing list.

  1. 3D printed casing (1)
  2. 1" Double sided protoboard (1)
  3. OLED Screen (1)
  4. INA219 Module (1)
  5. ATTINY85 20PU (1)
  6. 2P Screw Connector (1)
  7. 3P Screw Connector (1)
  8. LIR2450 Battery (1)
  9. LIR2450 Holder (1)
  10. M2.2 x 6mm Countersunk screws (4)

  11. Cyanoacrylate glue (1)

  12. Hookup wire (7)
  13. Solder Iron (1)
  14. Solder (1)

Step 2: ​Download Source Code

Download source from GitHub: If you are not familiar GitHub, simple press "Clone or download" button and then "Download ZIP".

Step 3: ​Program ATtiny85

Step 4: Protoboard Assembly

There are a few occasions where soldering on the other side of a through hole is obstructed. When this is the case, I soldered a dob on the target through hole, then from the side melt the solder and push the exposed hookup wire into center hole, hold and remove heat.

  1. From the bottom, insert pins from 2P connector in RED1 & RED2 with opening to outside. Solder pins off on topside.
  2. From the bottom, insert pins from 3P connector in RED3, RED4 & RED5 with opening to outside. Solder pins off on topside.
  3. From the bottom, insert pins from ATTINY85 in RED6 - RED13 with chip marker as shown. Solder pins off on topside.
  4. From the bottom, solder a blue wire from YELLOW1 to YELLOW2.
  5. From the bottom, solder a green wire from YELLOW3 to YELLOW4.

  6. On the top, solder a black wire from RED1 to RED4.
  7. On the top, solder a black wire from BLUE1 to BLUE2.
  8. On the top, solder a black wire from BLUE3 to BLUE4.
  9. On the top, solder a red wire from PINK1 to PINK2 (leaving plenty of excess wire as shown).

  10. On the top, solder a red wire from PINK3 to PINK4 (leaving plenty of excess wire as shown).

  11. On the top, solder a red wire from PINK5 to PINK6.

  12. On the top, solder a red wire into PINK7 (leaving plenty of excess).

  13. On the top, solder a black wire into PINK8 (leaving plenty of excess).

  14. Solder 6P male headers onto the INA219 module as shown.

  15. From the top, insert the INA219 pins into ORANGE1 - ORANGE6 and solder.

  16. Solder 4P male headers onto the OLED module as shown.

  17. Remove the plastic collar from the 6P pins.

  18. Bend the pins into a slight S shape, dry fit to check boards are parallel.

  19. From the top, insert the OLED pins into ORANGE7 - ORANGE10 and solder.

Step 5: Casing Assembly

  1. Insert assembled protoboard/INA219/OLED into 3D printed casing and secure with screws.
  2. Assemble SPDT with 3D printed switch surround, with Cyanoacrylate on contacting surfaces.
  3. Tin pins on SPDT.
  4. Fasten switch assembly to casing with Cyanoacrylate.
  5. Tin pins on LIR2450 holder.
  6. Fasten LIR2450 holder to casing with Cyanoacrylate.

  7. Solder loose black wire from protoboard to -ve pin on battery holder.

  8. Solder loose red wire from protoboard to middle pin on SPDT switch.

  9. Solder a red wire from +ve pin on battery holder to bottom SPDT pin (closest to large opening on casing).

Although not necessary, easier connection can be achieved by attaching male header pins to the screw connectors.

  1. Connect 1x2P male pins to 2P screw connectors.
  2. On a 2x3P male pins bend and solder pins on one row to there adjacent pins on the other row.
  3. Connect this to the 3P screw connectors.

Step 6: Next Steps

If using the LIR2450, once inserted power up by pushing the switch down.

The splash screen shows the connector usage.

2P Connector (this is used when not using the LIR2450):

  • Outer PIN, Monitor Power Supply GND
  • Inner PIN, Monitor Power Supply +ve

3P Connector (this is used for the device to be monitored):

  • Inner PIN, Device +ve
  • Middle PIN, Device GND, Device Battery GND
  • Outer PIN, Device Battery +ve

Be the First to Share


    • CNC Contest

      CNC Contest
    • Make it Move

      Make it Move
    • Teacher Contest

      Teacher Contest

    2 Discussions

    Bob Innes

    4 months ago

    Great project! Your voltage/current meter using tiny85 and OLED do you have source code or hex file without graphs, and larger text display for voltage & current & power readings.
    My eyesight not so good!


    1 year ago

    neat and tiny, well done!
    ☆*:.。. o(≧▽≦)o .。.:*☆