Skip to content

Pin numbering #96

Open
Open
@davepruitt

Description

@davepruitt

In the setup function in sketch.ino.cpp we find the following code:

pinMode(5, INPUT);
if (digitalRead(5) == LOW) 
{
    setupBluetooth();
} 
else 
{
    setupWiFi();
}

I don't see anywhere in code where pin numbers are defined, nor is there a variant.cpp or variant.h file like in a typical Arduino sketch where these numbers would normally be defined. Are we to understand that pin 5 in this context is GPIO 5 as defined in the NINA-W102 datasheet? (page 15 of this PDF: https://content.u-blox.com/sites/default/files/NINA-W10_DataSheet_UBX-17065507.pdf)

Or is it GPIO28, which the Arduino Nano 33 IoT's schematic weirdly names as GPIO5 (seen here: https://content.arduino.cc/assets/NANO33IoTV2.0_sch.pdf)?

Or is it something else?

Where can these pin definitions be found?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions