Skip to content
  • MySensors
  • OpenHardware.io
  • Categories
  • Recent
  • Tags
  • Popular
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo
  1. Home
  2. My Project
  3. Voltage divider resistors - using different resistor values

Voltage divider resistors - using different resistor values

Scheduled Pinned Locked Moved My Project
battery
2 Posts 2 Posters 920 Views 2 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • M Offline
    M Offline
    mitchdes
    wrote on last edited by
    #1

    Hi everyone - Okay this is my first time with mysensors and really excited to get started. I’ve built a gateway with an ESP which seems to be working fine. It’s recognised in the Mozilla Webthings controller and the serial output all seems okay.

    I am making a sensor test board with which i can try out different sensors before building into standalone devices and just needing a bit of help with measuring the battery voltage using a voltage divider. The mysensors sketch uses a 1m and 470k resistors for the voltage divider.

    My issue is that I only have a 1m resistor and a 480k rather than the 470k and want to know if the sketch can be modified to work with this 480k resistor.

    My sensor will be powered with a single 18560 cell as I have lots freely available and boosted to 5v for my mini pro (again because i have quite a few of these). So max battery voltage will be 4.2v and minimum voltage around 2.7v.

    Divider using 470k resistor: 1.343v (Vbatt=4.2v) and 0.863v (Vbatt=2.7v)
    Divider using 480k resistor: 1.362v (Vbat=4.2v) and 0.876v (Vbatt=2.7v)

    Is as simple as altering the math in the sketch to account for the different readings?

    Thanks

    mfalkviddM 1 Reply Last reply
    0
    • M mitchdes

      Hi everyone - Okay this is my first time with mysensors and really excited to get started. I’ve built a gateway with an ESP which seems to be working fine. It’s recognised in the Mozilla Webthings controller and the serial output all seems okay.

      I am making a sensor test board with which i can try out different sensors before building into standalone devices and just needing a bit of help with measuring the battery voltage using a voltage divider. The mysensors sketch uses a 1m and 470k resistors for the voltage divider.

      My issue is that I only have a 1m resistor and a 480k rather than the 470k and want to know if the sketch can be modified to work with this 480k resistor.

      My sensor will be powered with a single 18560 cell as I have lots freely available and boosted to 5v for my mini pro (again because i have quite a few of these). So max battery voltage will be 4.2v and minimum voltage around 2.7v.

      Divider using 470k resistor: 1.343v (Vbatt=4.2v) and 0.863v (Vbatt=2.7v)
      Divider using 480k resistor: 1.362v (Vbat=4.2v) and 0.876v (Vbatt=2.7v)

      Is as simple as altering the math in the sketch to account for the different readings?

      Thanks

      mfalkviddM Offline
      mfalkviddM Offline
      mfalkvidd
      Mod
      wrote on last edited by
      #2

      Welcome to the forum @mitchdes

      Yes, you are correct.

      1 Reply Last reply
      1

      Hello! It looks like you're interested in this conversation, but you don't have an account yet.

      Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

      With your input, this post could be even better 💗

      Register Login
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      6

      Online

      12.0k

      Users

      11.2k

      Topics

      113.4k

      Posts


      Copyright 2025 TBD   |   Forum Guidelines   |   Privacy Policy   |   Terms of Service
      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • MySensors
      • OpenHardware.io
      • Categories
      • Recent
      • Tags
      • Popular