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. What are the pin numbers for D3, D4, ...

What are the pin numbers for D3, D4, ...

Scheduled Pinned Locked Moved Troubleshooting
digitalwritedigital iopin numbers
8 Posts 5 Posters 1.8k Views 4 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.
  • B Offline
    B Offline
    Bens
    wrote on last edited by
    #1

    Hi All,

    I bought a couple of Sensebender Micro's and got them working with a Raspberry Pi 2 as a gateway and controller.
    I want to use the digital outputs of the Sensebender Micro's but don't know the pin numbers of D3-D7, nor am I able to find them.
    Simply using D3, and so on, in my scripts fails (although using A0 works).
    Please help.

    Never stop trying
    -Ben

    1 Reply Last reply
    0
    • hekH Offline
      hekH Offline
      hek
      Admin
      wrote on last edited by
      #2

      https://github.com/mysensors/SensebenderMicro/blob/master/MySensorMicro.pdf

      1 Reply Last reply
      0
      • B Offline
        B Offline
        Bens
        wrote on last edited by
        #3

        Hi Hek, Many thanks for the schematic,

        Nevertheless, I struggle a bit.
        I (serial) printed the values of A0..A3 and they are 14..17.
        On the schematic I see A0..A3 and for each one, I see two numbers: pcint8 and 23 for A0, pcint9 and 24 for A1 etc, but I don't see anywhere 14..17 in relationship to A0..A3. Or is there something simple like add 6 to the pcint value or subtract 9 from the other one.
        Help is appreciated!

        Never stop trying
        -Ben

        1 Reply Last reply
        0
        • B Offline
          B Offline
          Bens
          wrote on last edited by
          #4

          Hi Hek,
          I think I got it, When using PD3, PD4 it seems to work.
          I'll test a bit and see whether I can get it confirmed.
          Thanks

          Never stop trying
          -Ben

          1 Reply Last reply
          0
          • tbowmoT Offline
            tbowmoT Offline
            tbowmo
            Admin
            wrote on last edited by tbowmo
            #5

            @Bens

            Use the following to set D3 high

            pinMode(3, OUTPUT);
            digitalWrite(3, HIGH);
            

            Pins D3 - D7, and A0-A2 etc. is the same pins as on standard arduino. So you can address them in the same way, as with standard arduino (uno)

            https://www.arduino.cc/en/Reference/DigitalWrite

            Vuinne RyvmarV 1 Reply Last reply
            0
            • B Offline
              B Offline
              Bens
              wrote on last edited by
              #6

              Hi @tbowmo and @hek,
              Many thanks, I got it working!

              Never stop trying
              -Ben

              1 Reply Last reply
              0
              • tbowmoT tbowmo

                @Bens

                Use the following to set D3 high

                pinMode(3, OUTPUT);
                digitalWrite(3, HIGH);
                

                Pins D3 - D7, and A0-A2 etc. is the same pins as on standard arduino. So you can address them in the same way, as with standard arduino (uno)

                https://www.arduino.cc/en/Reference/DigitalWrite

                Vuinne RyvmarV Offline
                Vuinne RyvmarV Offline
                Vuinne Ryvmar
                wrote on last edited by
                #7

                @tbowmo are you still here man?so what is the pin? I also lost my PIN to d3 game controller and I want to get this connected to my phone to play, that's the third step and it won't connect unless I know the pin to this apparently.

                E 1 Reply Last reply
                0
                • Vuinne RyvmarV Vuinne Ryvmar

                  @tbowmo are you still here man?so what is the pin? I also lost my PIN to d3 game controller and I want to get this connected to my phone to play, that's the third step and it won't connect unless I know the pin to this apparently.

                  E Offline
                  E Offline
                  ejlane
                  wrote on last edited by ejlane
                  #8

                  @Vuinne-Ryvmar You seem to be confused about what this forum is. Maybe you just ended up here on a random Google search?

                  But in our case on an Arduino, D3 is literally the name for one of the metal legs coming off of the little controller, and we call it a pin sometimes. @tbowmo was looking for how to send the command to turn the power on or off to that part of the board, not a code to enable connecting up a controller to their phone.

                  I see that a D3 game controller is a thing, but I doubt you will have any luck getting help with that here. It's not what this site is about.

                  This is what we work with:
                  alt text

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


                  18

                  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