Connecting MPU6050 with Arduino without using A0-A5 pins.


You could use a Software I2C library, like this one on github, which can be used on almost any pin of a board. But keep in mind, that doing such communication in software imposes some limits (for example the linked library can only be a master). Keeping it in hardware is often the better choice, depending on your requirements.

  • Thanks. I want to connect 5 flex sensors and MPU6050 to arduino uno and i don't know how to make the circuit and code it. Can you help me. – user9600686 Feb 26 at 13:13
  • 1
    Have you tried to google the individual parts of your project? That should help you a lot. Depending on your flex sensor, they are either a resitive voltage divider by themselves (in which case they exactly behave like a potentiometer, where you can easily google tons of tutorials) or you need an additional resistor to build a voltage divider. For the MPU: With a quick google I haven't found a library for it, that can directly use Software I2C. Depending on how deep you wanna go: You can create your own library or modify an existing one for the MPU6050 to use SoftwareI2C. – chrisl Feb 26 at 14:57
  • 1
    Or you can change your plan: Using an external ADC board for measuring the flex sensors or using a different MPU board, which can for example use SPI (like the MPU6000). Think about how you want to build your project and how much time you wanna invest. You can always come to this site and as a specific question – chrisl Feb 26 at 15:00

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for?Browse other questions tagged or ask your own question.