# Getting Issue wile Interfacing OLED,MPU6050 with AMB82-Mini Board

**URL:** <https://forum.amebaiot.com/t/getting-issue-wile-interfacing-oled-mpu6050-with-amb82-mini-board/4204>\
**Category:** Peripherals\
**Tags:** evb-amb82, rtl8735b\
**Created:** [June 26, 2025, 8:54pm UTC](https://forum.amebaiot.com/t/getting-issue-wile-interfacing-oled-mpu6050-with-amb82-mini-board/4204 "2025-06-26T20:54:14Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![Pradumn\_Porwal](https://sea2.discourse-cdn.com/flex016/user_avatar/forum.amebaiot.com/pradumn_porwal/32/2697_2.png) [@Pradumn\_Porwal](https://forum.amebaiot.com/u/Pradumn_Porwal)\
**Post date:** [June 26, 2025, 8:54pm UTC](https://forum.amebaiot.com/t/getting-issue-wile-interfacing-oled-mpu6050-with-amb82-mini-board/4204/1 "2025-06-26T20:54:15Z")

</div>

I am currently exploring the I2C Communication using AMB82 Board.  
When I interfaced MPU6050 with AMB82 and got raw\_data, acceleration Values  
which is working fine.  
But When I want to display that data on OLED then it’s not working properly.

**here is the code**

#include “I2Cdev.h”  
#include “MPU6050\_IMU\_libraries/MPU6050.h”

#if I2CDEV\_IMPLEMENTATION == I2CDEV\_ARDUINO\_WIRE  
#include “Wire.h”  
#endif

#include \<Adafruit\_OLED\_libraries/Adafruit\_GFX.h\>  
#include \<Adafruit\_OLED\_libraries/Adafruit\_SSD1306.h\>

// OLED definitions  
#define SCREEN\_WIDTH 128  
#define SCREEN\_HEIGHT 64  
#define SCREEN\_ADDRESS 0x3C // OLED I2C address checked by I2C scanner  
Adafruit\_SSD1306 display(SCREEN\_WIDTH, SCREEN\_HEIGHT, &Wire, OLED\_RESET);

MPU6050 mpu;

int16\_t ax\_raw, ay\_raw, az\_raw;  
float ax, ay, az;

void setup() {  
#if I2CDEV\_IMPLEMENTATION == I2CDEV\_ARDUINO\_WIRE  
Wire.begin();  
#elif I2CDEV\_IMPLEMENTATION == I2CDEV\_BUILTIN\_FASTWIRE  
Fastwire::setup(400, true);  
#endif

Serial.begin(115200);  
Serial.println(“Initializing MPU6050…”);  
mpu.initialize();  
if (mpu.testConnection()) {  
Serial.println(“MPU6050 connection successful”);  
} else {  
Serial.println(“MPU6050 connection failed”);  
}

// Initialize OLED  
if (!display.begin(SSD1306\_SWITCHCAPVCC, SCREEN\_ADDRESS)) {  
Serial.println(F(“SSD1306 allocation failed”));  
while (true)  
; // Stop execution  
}

delay(1000); // Let OLED settle  
display.clearDisplay();  
display.setTextSize(1);  
display.setTextColor(SSD1306\_WHITE);  
display.setCursor(0, 0);  
display.println(“MPU6050 Ready”);  
display.display();  
}

void loop() {  
mpu.getAcceleration(&ax\_raw, &ay\_raw, &az\_raw);

// Convert raw to m/s²  
ax = ax\_raw \* 9.81 / 16384.0;  
ay = ay\_raw \* 9.81 / 16384.0;  
az = az\_raw \* 9.81 / 16384.0;

#ifdef OUTPUT\_READABLE\_ACCEL\_ONLY  
Serial.print(“Accel (X, Y, Z):\t”);  
Serial.print(ax\_raw);  
Serial.print(“\t”);  
Serial.print(ay\_raw);  
Serial.print(“\t”);  
Serial.println(az\_raw);  
#endif

// Serial print  
Serial.print(“Accel (X, Y, Z) [m/s²]:\t”);  
Serial.print(ax, 2);  
Serial.print(“\t”);  
Serial.print(ay, 2);  
Serial.print(“\t”);  
Serial.println(az, 2);

// OLED display update  
display.clearDisplay();  
display.setCursor(0, 0);  
display.setTextSize(1);  
display.setTextColor(SSD1306\_WHITE);  
display.println(“Acceleration (m/s²)”);  
display.print("X: ");  
display.println(ax, 2);  
display.print("Y: ");  
display.println(ay, 2);  
display.print("Z: ");  
display.println(az, 2);  
display.display();

delay(500);  
}"

**And I got Error like this :**

> “01:12:08.108 →   
> [MISC Err]Pin 0[0] is conflicted  
> 01:12:08.108 →   
> [MISC Err]It’s configured as RFAFE\_CTRL/JTAG now.  
> 01:12:08.108 →   
> [MISC Err]It’s using by peripheral 30000000  
> 01:12:08.108 →   
> [MISC Err]Pin un-register caller (10000000) is not the owner (30000000)  
> 01:12:08.142 →   
> [MISC Err]Pin un-register caller (10000000) is not the owner (30000000)  
> 01:12:08.142 →   
> [MISC Err]Pin 0[0] is conflicted  
> 01:12:08.142 →   
> [MISC Err]It’s configured as RFAFE\_CTRL/JTAG now.  
> 01:12:08.142 →   
> [MISC Err]It’s using by peripheral 30000000  
> 01:12:08.142 →   
> [MISC Err]Pin 0[0] is conflicted  
> 01:12:08.142 →   
> [MISC Err]It’s configured as RFAFE\_CTRL/JTAG now.  
> 01:12:08.142 →   
> [MISC Err]It’s using by peripheral 30000000  
> 01:12:08.174 →   
> [MISC Err]Pin un-register caller (10000000) is not the owner (30000000)  
> 01:12:08.174 →   
> [MISC Err]Pin un-register caller (10000000) is not the owner (30000000)  
> 01:12:08.220 →   
> [MISC Err]Pin 0[0] is conflicted  
> 01:12:08.220 →   
> [MISC Err]It’s configured as RFAFE\_CTRL/JTAG now.  
> 01:12:08.220 →   
> [MISC Err]It’s using by peripheral 30000000  
> 01:12:08.220 →   
> [MISC Err]Pin 0[0] is conflicted  
> 01:12:08.220 →   
> [MISC Err]It’s configured as RFAFE\_CTRL/JTAG now.  
> 01:12:08.220 →   
> [MISC Err]It’s using by peripheral 30000000”

@Kelvin_Huang @KaiFai_Y @M-ichae-l Please Help Sir

---

<div class="post-metadata">

**Author:** ![KaiFai\_Y](https://sea2.discourse-cdn.com/flex016/user_avatar/forum.amebaiot.com/kaifai_y/32/2252_2.png) [@KaiFai\_Y](https://forum.amebaiot.com/u/KaiFai_Y)\
**Post date:** [June 27, 2025, 1:27am UTC](https://forum.amebaiot.com/t/getting-issue-wile-interfacing-oled-mpu6050-with-amb82-mini-board/4204/2 "2025-06-27T01:27:27Z")

</div>

Hi @Pradumn_Porwal, The error message you provided indicates that Pin 0 is conflicting with another hardware function, such as JTAG or RFAFE\_CTRL. It seems that the `OLED_RESET` pin might be defaulting to Pin 0, which is likely causing the issue.

Could you please check how `OLED_RESET` is defined in your code? For reference, in the [OLED\_SSD1306 example](https://github.com/Ameba-AIoT/ameba-arduino-pro2/blob/dev/Arduino_package/hardware/libraries/Wire/examples/OLED_SSD1306/OLED_SSD1306.ino), `OLED_RESET` is defined as:

```auto
#define OLED_RESET -1

```

This means no reset pin is used, which avoids the conflict. You might want to adopt the same definition. Thank you.

---

<div class="post-metadata">

**Author:** ![Pradumn\_Porwal](https://sea2.discourse-cdn.com/flex016/user_avatar/forum.amebaiot.com/pradumn_porwal/32/2697_2.png) [@Pradumn\_Porwal](https://forum.amebaiot.com/u/Pradumn_Porwal)\
**Post date:** [June 29, 2025, 9:15pm UTC](https://forum.amebaiot.com/t/getting-issue-wile-interfacing-oled-mpu6050-with-amb82-mini-board/4204/3 "2025-06-29T21:15:10Z")

</div>

@KaiFai_Y Sir I tried to upload code with

> #define OLED\_RESET -1

 ![image](https://us1.discourse-cdn.com/flex016/uploads/ameba/original/2X/5/52ddfbf6690b15ee8b5fa542fb91a302bc78c872.png)  
But the Error remained as it is

> 01:12:03.281 → $8735b\>Initializing MPU6050…  
> 01:12:03.281 → MPU6050 connection successful  
> 01:12:03.281 → [MISC Err]Pin 0[0] is conflicted  
> 01:12:03.281 → [MISC Err]It’s configured as RFAFE\_CTRL/JTAG now.  
> 01:12:03.281 → [MISC Err]It’s using by peripheral 30000000  
> this error is repeating continuously on serial monitor

---

<div class="post-metadata">

**Author:** ![Kelvin\_Huang](https://sea2.discourse-cdn.com/flex016/user_avatar/forum.amebaiot.com/kelvin_huang/32/2130_2.png) [@Kelvin\_Huang](https://forum.amebaiot.com/u/Kelvin_Huang)\
**Post date:** [June 30, 2025, 1:47am UTC](https://forum.amebaiot.com/t/getting-issue-wile-interfacing-oled-mpu6050-with-amb82-mini-board/4204/4 "2025-06-30T01:47:43Z")

</div>

Hi @Pradumn_Porwal ,

Are you connecting any JTAG debugger to the I2C pins?

May I know how you are connecting your I2C devices to AMB82-Mini?

Thank you.

---

<div class="post-metadata">

**Author:** ![Pradumn\_Porwal](https://sea2.discourse-cdn.com/flex016/user_avatar/forum.amebaiot.com/pradumn_porwal/32/2697_2.png) [@Pradumn\_Porwal](https://forum.amebaiot.com/u/Pradumn_Porwal)\
**Post date:** [June 30, 2025, 7:04pm UTC](https://forum.amebaiot.com/t/getting-issue-wile-interfacing-oled-mpu6050-with-amb82-mini-board/4204/5 "2025-06-30T19:04:02Z")

</div>

@Kelvin_Huang Sir I only connected MPU6050 and OLED Display on AMB82 I2C Periferals[Pin12:SDA, Pin13:SCL]

And when I connect MPU6050 only.  
The board is perfectly fine with this code and display the acceleration in X,Y & Z Axis

> //AMB82 with MPU6050  
> #include “I2Cdev.h”  
> #include “MPU6050\_IMU\_libraries/MPU6050.h”
> 
> #if I2CDEV\_IMPLEMENTATION == I2CDEV\_ARDUINO\_WIRE  
> #include “Wire.h”  
> #endif
> 
> MPU6050 accelgyro;
> 
> int16\_t ax\_raw, ay\_raw, az\_raw;  
> float ax, ay, az;
> 
> #define OUTPUT\_READABLE\_ACCEL\_ONLY
> 
> void setup() {  
> #if I2CDEV\_IMPLEMENTATION == I2CDEV\_ARDUINO\_WIRE  
> Wire.begin();  
> #elif I2CDEV\_IMPLEMENTATION == I2CDEV\_BUILTIN\_FASTWIRE  
> Fastwire::setup(400, true);  
> #endif
> 
> Serial.begin(115200);
> 
> Serial.println(“Initializing I2C devices…”);  
> accelgyro.initialize();
> 
> Serial.println(“Testing device connections…”);  
> Serial.println(accelgyro.testConnection() ? “MPU6050 connection successful” : “MPU6050 connection failed”);
> 
> }
> 
> void loop() {  
> accelgyro.getAcceleration(&ax\_raw, &ay\_raw, &az\_raw);  
> // Convert to m/s²  
> ax = ax\_raw \* 9.81 / 16384.0;  
> ay = ay\_raw \* 9.81 / 16384.0;  
> az = az\_raw \* 9.81 / 16384.0;
> 
> #ifdef OUTPUT\_READABLE\_ACCEL\_ONLY  
> Serial.print(“Accel (X, Y, Z):\t”);  
> Serial.print(ax\_raw);  
> Serial.print(“\t”);  
> Serial.print(ay\_raw);  
> Serial.print(“\t”);  
> Serial.println(az\_raw);  
> #endif
> 
> // Print to Serial  
> Serial.print(“Accel (X, Y, Z) in m/s²:\t”);  
> Serial.print(ax, 2);  
> Serial.print(“\t”);  
> Serial.print(ay, 2);  
> Serial.print(“\t”);  
> Serial.println(az, 2);
> 
> delay(500); // Optional: adjust for readability  
> }

But When I try to connect the OLED too  
I got this error

> 01:12:03.281 → [MISC Err]Pin 0[0] is conflicted
> 
> 01:12:03.281 → [MISC Err]It’s configured as RFAFE\_CTRL/JTAG now.
> 
> 01:12:03.281 → [MISC Err]It’s using by peripheral 30000000

---

<div class="post-metadata">

**Author:** ![KaiFai\_Y](https://sea2.discourse-cdn.com/flex016/user_avatar/forum.amebaiot.com/kaifai_y/32/2252_2.png) [@KaiFai\_Y](https://forum.amebaiot.com/u/KaiFai_Y)\
**Post date:** [July 3, 2025, 1:11am UTC](https://forum.amebaiot.com/t/getting-issue-wile-interfacing-oled-mpu6050-with-amb82-mini-board/4204/6 "2025-07-03T01:11:04Z")

</div>

Hi @Pradumn_Porwal, you mean both oled and mpu6050 was connected using pin 12 and 13? if so, can you try on separating using another set i2c for oled or mpu6050. You can refer to this [document](https://ameba-doc-arduino-sdk.readthedocs-hosted.com/en/latest/ameba_pro2/amb82-mini/Getting_Started/Getting%20Started%20with%20Ameba.html) to check on others i2c pins for amb82 mini. Thank you.

---

<div class="post-metadata">

**Author:** ![bandit](https://avatars.discourse-cdn.com/v4/letter/b/4491bb/32.png) [@bandit](https://forum.amebaiot.com/u/bandit)\
**Post date:** [February 21, 2026, 1:58pm UTC](https://forum.amebaiot.com/t/getting-issue-wile-interfacing-oled-mpu6050-with-amb82-mini-board/4204/7 "2026-02-21T13:58:06Z")

</div>

我之前也遇到同样的问题，SPI与I2C总线共用9-13引脚。我的解决方法是mpu6050使用9-13这边的I2C0总线，然后oled使用1-4引脚的SPI1总线。

不在电脑旁，引脚的号码忘记了。I2C设备使用开发板左边的总线，OLED使用开发板右边的总线，这样就避免了引脚冲突的问题了。
