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. Troubleshooting
  3. Assign sensor ID so it never changes

Assign sensor ID so it never changes

Scheduled Pinned Locked Moved Troubleshooting
3 Posts 2 Posters 382 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.
  • HomerH Offline
    HomerH Offline
    Homer
    wrote on last edited by
    #1

    Hi all

    At the moment, whenever I test a sensor I add it to my controller (Vera) and if it doesn't work correctly I delete all the sensors, clear my sensor using the wipe sketch and then upload the corrected sketch again. Turn obviously my controller is populated with the new sensors.

    Is there a way so I don't have to delete the sensors in my controller and for the newly uploaded sketch be associated with the previous sensors in my controller? Should I not bother wiping the Arduino and would that mean that the new sketch would be applied to the existing sensors in my controller? Or is there a better way?

    Thanks in advance!

    1 Reply Last reply
    0
    • HonkH Offline
      HonkH Offline
      Honk
      wrote on last edited by
      #2

      If you want to force the ID for the Sensor node you can add

      #define MY_NODE_ID 200
      

      before

      #include <MySensors.h>
      

      This will overwrite the Node ID in the Arduino EEPROM. If the Unit is powered up and connected to the Gateway you can remove the define. The ID should now be stored in the EEPROM.

      HomerH 1 Reply Last reply
      1
      • HonkH Honk

        If you want to force the ID for the Sensor node you can add

        #define MY_NODE_ID 200
        

        before

        #include <MySensors.h>
        

        This will overwrite the Node ID in the Arduino EEPROM. If the Unit is powered up and connected to the Gateway you can remove the define. The ID should now be stored in the EEPROM.

        HomerH Offline
        HomerH Offline
        Homer
        wrote on last edited by
        #3

        @hermann-kaiser

        Thank you

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        14

        Online

        11.7k

        Users

        11.2k

        Topics

        113.1k

        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