# Mpu6050 and drawing

I have an arduino program that calculates gyroscope,accelerometer(also with kalman filter) values. And c# program that receives data(x-y axis) and uses it to draw on canvas. I'm a novice at this, so i wonder what data(gyro,accel or maybe needed to integrate this?) i must send to c# program to draw? Is it possible?

By other words, i need to track trajectory of sensor

shank923:
I have an arduino program that calculates gyroscope,accelerometer(also with kalman filter) values. And c# program that receives data(x-y axis) and uses it to draw on canvas. I'm a novice at this, so i wonder what data(gyro,accel or maybe needed to integrate this?) i must send to c# program to draw? Is it possible?

Not sure why you would need gyro data to draw. All you need is accel data. The math will be non-trivial, but very doable.

Power_Broker:
Not sure why you would need gyro data to draw. All you need is accel data. The math will be non-trivial, but very doable.

But what algorithm i must use? When i send pure accel data it makes just a lot of random dots.

Up

I'm not sure what you mean by "trajectory". Do you mean position? As in, move the sensor 10cm left and the output does something with that information?

The basic problem is you're doing all of these sensitive measurements inside a dragster car that's about to break the 7-second barrier for the quarter mile. That's 1g acceleration. If the alignment of the accelerometers and gyros is not perfect, a small difference in angle will mean you end up several kilometers out of place when you were trying to measure 10cm.

Just try to use it as a tilt sensor to steer the output around.

MorganS:
I'm not sure what you mean by "trajectory". Do you mean position? As in, move the sensor 10cm left and the output does something with that information?

The basic problem is you're doing all of these sensitive measurements inside a dragster car that's about to break the 7-second barrier for the quarter mile. That's 1g acceleration. If the alignment of the accelerometers and gyros is not perfect, a small difference in angle will mean you end up several kilometers out of place when you were trying to measure 10cm.

Just try to use it as a tilt sensor to steer the output around.

For example - if i move mpu6050 to the left, there in application will be drawn a line to the left. So i don't know the algorithm, should i use accel or gyro or maybe both?

You still haven’t defined the operation well enough. What is in your head might be incredibly difficult or a walk in the park for this sensor.

Look around for the sensor-fusion libraries that will give you acceleration of the sensor with gravity removed. If you think you can use acceleration (not position) to do what you want then it’s not too hard.