Skip to content

.begin fails on Thing Plus RP2040 - need to edit pins_arduino.h #176

Closed
@StressedDave

Description

@StressedDave

I'm having an issue interfacing the library with anything with a RP2040 processor (I've tried the code on a ThingPlus, Feather and Trinkey). It may be someone has messed around with the Arduino core. Put very simply, 99% of the time a call to begin() throws up a 'unable to connect' error. I know the board is there because:

`#include <Wire.h> //Needed for I2C to GNSS
#include <SparkFun_u-blox_GNSS_Arduino_Library.h> //http://librarymanager/All#SparkFun_u-blox_GNSS

SFE_UBLOX_GNSS GNSS;

boolean UDR = false;
char Model[30];

void setup()
{
Serial.begin(115200); // You may need to increase this for high navigation rates!
while (!Serial)
; //Wait for user to open terminal
Serial.println("Configuration check");
Wire1.begin();
Wire1.beginTransmission(0x42);
if((Wire1.endTransmission() == 0)){
Serial.println("YES - I am definitely here");
}
else{
Serial.println("NO - I am not here");
}
GNSS.begin(Wire1);
if (GNSS.begin(Wire1) == false) //Connect to the u-blox module using Wire port
{
Serial.println(F("u-blox GNSS not detected. Please check wiring. Freezing."));
while (1)
;
}
GNSS.setI2COutput(COM_TYPE_UBX); //Set the I2C port to output UBX only (turn off NMEA noise)
}

void loop()
{
}`

Confirms that the board is there but throws up the error when I go to start the library. A quick zoom through the source code suggests that you're using the same code in 'isConnected'. (Sorry, I'm of an age where Pascal/Fortran was king of languages for University). Am I missing something? The library starts correctly on every other processor I've tried (SAMD M0 & M4 and STM32) and used to work fine on RP2040 architecture.

I'm trying to interface a M8U (and I spotted in the source that they occasionally throw up issues), but a M9N shows the same behaviour.

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