Comments on: Raspberry Pi Pico: I2C Scanner (Arduino IDE) – Finding the Address of I2C Devices https://randomnerdtutorials.com/raspberry-pi-pico-i2c-scanner-arduino/ Learn ESP8266, ESP32, Arduino, and Raspberry Pi Thu, 13 Nov 2025 17:12:46 +0000 hourly 1 https://wordpress.org/?v=6.8.5 By: David Francis https://randomnerdtutorials.com/raspberry-pi-pico-i2c-scanner-arduino/#comment-1123468 Thu, 13 Nov 2025 17:12:46 +0000 https://randomnerdtutorials.com/?p=144601#comment-1123468 In reply to David Francis.

Follow-up:
The correct syntax in Arduino IDE for changing I2C pins is to insert the following code before Wire.begin():

Wire.setSDA(I2C_SDA);
Wire.setSCL(I2C_SCL);

where I2C_SDA and I2C_SCL are declared as:

pin_size_t I2C_SDA = your_pin_no;

Hope this is helpful.

]]>
By: David Francis https://randomnerdtutorials.com/raspberry-pi-pico-i2c-scanner-arduino/#comment-1123464 Thu, 13 Nov 2025 16:51:58 +0000 https://randomnerdtutorials.com/?p=144601#comment-1123464 Attempting to use alternative SDA/SCL pins, the code: ‘Wire.begin(I2C_SDA, I2C_SCL);’ is incorrect. Wire.begin(); only takes one optional parameter, which is the address of the device if operating in slave mode and is between 0 and 127.
Cannot yet find the correct code for using alternative pins.

]]>
By: Sara Santos https://randomnerdtutorials.com/raspberry-pi-pico-i2c-scanner-arduino/#comment-890155 Sun, 11 Feb 2024 18:58:56 +0000 https://randomnerdtutorials.com/?p=144601#comment-890155 In reply to Micha.

You’re welcome:)

]]>
By: Micha https://randomnerdtutorials.com/raspberry-pi-pico-i2c-scanner-arduino/#comment-889537 Fri, 09 Feb 2024 14:10:04 +0000 https://randomnerdtutorials.com/?p=144601#comment-889537 Thank you, works great!

]]>