Hi! I am a newbie with arduino, and I am currently working on a project that uses MPU 5060 to measure the coordinates and make LEDs light up based on the tilting of the sensor.
So far I have used Jeff Rowberg and Luis Rodenas's code to measure and calibrate the data obtained from the MPU 5060 sensor. I wanted to attach 4 LED lights onto my breadboard and make them lit up whenever the sensor is tilted towards that direction (so left right up down or xy coordinates).
Can somebody give me any advice with coding this? I am not sure where to start...
I managed to use the two codes that I posted to get the MPU5060 running and get calibrated data. (IN xyzw coordinates)
The part I am confused is how to "connect" the data from the serial monitor and the LED lights. I am confused how to 1. only extract the xy coordinates from the serial monitor data 2. make the LED lights light up if there is a change in xy coordinates 3. selecting the appropriate keywords to google possible libraries or help I will need in general.
I am not so familiar with coding in general so it has been difficult to find resources that I can actually understand and follow