Show Posts
Pages: [1] 2 3 ... 19
1  Using Arduino / Sensors / Re: Guide to gyro and accelerometer with Arduino including Kalman filtering on: April 17, 2014, 09:28:58 am
@AlexTeos
Please take a look at the following code: https://github.com/TKJElectronics/Example-Sketch-for-IMU-including-Kalman-filter/tree/master/IMU/MPU6050_HMC5883L.

You will need to buy a HMC5883L 3-axis magnetometer as well and use it together with the MPU-6050. Note that "GY-521" is just the name of the breakout board and not the sensor. The sensor on the "GY-521" is the MPU-6050.
2  Using Arduino / Sensors / Re: Guide to gyro and accelerometer with Arduino including Kalman filtering on: April 11, 2014, 02:13:20 pm
@juanvivo
It will only help to increase the resolution if you expect to do maneuvers that exceed +-2g.
What you could do instead is try to use the built in filter inside the MPU-6050. I am using that myself for the Balanduino: https://github.com/TKJElectronics/Balanduino/blob/aec22dafe8e98f0a16df6b5031a92354bb27ec5b/Firmware/Balanduino/Balanduino.ino#L225-L226 and the MPU-6050 datasheet: http://invensense.com/mems/gyro/documents/RM-MPU-6000A-00v4.2.pdf at page 13.

@Lany
Yes I know that you could do that as well, but it would be easier to for example just use a low pass filter on the raw acceleromter values.

@mariocaptain
Please read: http://www.freescale.com/files/sensors/doc/app_note/AN3461.pdf.

@grasshopper
These are zero-values for the accelerometer - just send set them to 0. I have added a note about it: https://github.com/TKJElectronics/Example-Sketch-for-IMU-including-Kalman-filter/commit/21c9f6fcdf781861cb461c3078f9bef25cf3d5ca.
I'm planning to make a short calibration routine as I have done for the Balanduino: https://github.com/TKJElectronics/Balanduino/blob/aec22dafe8e98f0a16df6b5031a92354bb27ec5b/Firmware/Balanduino/Tools.ino#L109-L144, but for now you have to enter them manually.
3  Using Arduino / Sensors / Re: Guide to gyro and accelerometer with Arduino including Kalman filtering on: March 14, 2014, 06:18:36 pm
@juanvivo
I have answered your question at my blog: http://blog.tkjelectronics.dk/2012/09/a-practical-approach-to-kalman-filter-and-how-to-implement-it/comment-page-4/#comment-486873.

@andremorais
I believe you can't use the angles directly, as the one of the angles is being restricted to +-90 degrees, you should instead modify your Processing code, so it shows the block correctly.
4  Using Arduino / Sensors / Re: Guide to gyro and accelerometer with Arduino including Kalman filtering on: March 02, 2014, 08:37:43 am
@mbedfordm
I just updated the MPU-6050 code. The changes newest code can be found in the Github repository: https://github.com/TKJElectronics/Example-Sketch-for-IMU-including-Kalman-filter/tree/master/IMU6DOF/MPU6050.
5  Using Arduino / Sensors / Re: Guide to gyro and accelerometer with Arduino including Kalman filtering on: March 02, 2014, 06:19:24 am
@mbedfordm
You can get the unbiased rate using the following function: https://github.com/TKJElectronics/KalmanFilter/blob/master/Kalman.h#L81.

I know what you are talking about and will upload a fix very soon. Please read this for now: http://www.freescale.com/files/sensors/doc/app_note/AN3461.pdf.
6  Using Arduino / Sensors / Re: Guide to gyro and accelerometer with Arduino including Kalman filtering on: February 19, 2014, 10:44:49 am
@kirky
I am aware of the problem and have actually solved it in my local repo, but I need to clean it a bit before I push it. You should take a look at this app-note: http://www.freescale.com/files/sensors/doc/app_note/AN3461.pdf for now smiley-wink

@PeterCheng
You should not open the Graph code in the Arduino IDE, but in Processing: http://processing.org/.

You can find more information in the readme: https://github.com/TKJElectronics/Example-Sketch-for-IMU-including-Kalman-filter/tree/master/IMU6DOF/MPU6050/Graph#developed-by-kristian-lauszus-tkj-electronics-2012.
7  Using Arduino / Sensors / Re: Guide to gyro and accelerometer with Arduino including Kalman filtering on: February 11, 2014, 11:28:06 am
@kirky
This is how I deal with it in the firmware for my balancing robot: https://github.com/TKJElectronics/Balanduino/blob/cc8beb5f3a78cfd615a00c490b6656bdcc1a9d8b/Firmware/Balanduino/Balanduino.ino#L290-L304.
8  Using Arduino / Sensors / Re: Guide to gyro and accelerometer with Arduino including Kalman filtering on: February 09, 2014, 03:15:45 pm
@ninor
You will need some other sensor like a GPS sensor to get the position. See my previous reply to Ked85: http://forum.arduino.cc/index.php?topic=58048.msg1551502#msg1551502.
9  Using Arduino / Sensors / Re: Guide to gyro and accelerometer with Arduino including Kalman filtering on: February 08, 2014, 07:11:53 am
@ninor
What do you mean by displacement?
10  Using Arduino / Sensors / Re: Guide to gyro and accelerometer with Arduino including Kalman filtering on: February 07, 2014, 08:50:01 am
@Pendax
Try to use the Kalman filter I have provided and see if that helps. You could also try to implement a low-pass filter of the accelerometer reading, to get rid of some of the noise.

@ninor
This graph code: https://github.com/TKJElectronics/Example-Sketch-for-IMU-including-Kalman-filter/tree/master/Graph is for these codes: https://github.com/TKJElectronics/Example-Sketch-for-IMU-including-Kalman-filter/tree/master/IMU6DOF/ITG3205_ADXL345 and https://github.com/TKJElectronics/Example-Sketch-for-IMU-including-Kalman-filter/tree/master/IMU6DOF/LPR530AL_LY530ALH_ADXL335.

While this one: https://github.com/TKJElectronics/Example-Sketch-for-IMU-including-Kalman-filter/tree/master/IMU6DOF/MPU6050/Graph is for the MPU-6050.

@ceciliazy13
You can find the code for my balancing robot here: https://github.com/TKJElectronics/Balanduino.

@siddhu99199
You need to download the I2C.ino and Kalman.h files in this directory: https://github.com/TKJElectronics/Example-Sketch-for-IMU-including-Kalman-filter/tree/master/IMU6DOF/MPU6050 as well. Then simply click on the file name MPU6050.ino.
11  Using Arduino / Sensors / Re: Guide to gyro and accelerometer with Arduino including Kalman filtering on: January 18, 2014, 06:19:29 am
@Pendax
That is the point of the sensor fusion. This example: https://github.com/TKJElectronics/Example-Sketch-for-IMU-including-Kalman-filter/tree/master/IMU6DOF/MPU6050 shows how to do it.

@Ked85
It is very difficult to get linear data, as you will need to integrate the accelerometer, so the error will also be integrated.
12  Using Arduino / Microcontrollers / Re: Guide: How to use an Arduino as an In System Programmer (ISP) on: January 18, 2014, 06:11:26 am
@Yigiter007
Try to follow this guide: http://www.ladyada.net/learn/avr/setup-win.html. This might help you get it compiled.

I have no idea if Sparkfun has updated their firmware. I haven't tried the serial backpack since I wrote this guide, so I have no idea.
13  Using Arduino / Sensors / Re: Guide to gyro and accelerometer with Arduino including Kalman filtering on: December 25, 2013, 10:39:38 am
@Pendax
I actually do not know. I have never tried to let it run for that long, but I believe it is able to do it.
Sorry for the delayed reply!
14  Using Arduino / Sensors / Re: Guide to gyro and accelerometer with Arduino including Kalman filtering on: October 29, 2013, 02:02:42 pm
It is not possible to calculate the rotation along the z-axis (yaw) using the accelerometer. More information can be found at the following comment on my blog: http://blog.tkjelectronics.dk/2012/09/a-practical-approach-to-kalman-filter-and-how-to-implement-it/comment-page-3/#comment-431999.

Instead you should use the code that you used snippets of, which I believe is this one: https://github.com/jrowberg/i2cdevlib/tree/master/Arduino/MPU6050, right?

But to get a precise yaw estimate you should use a magnetometer as well.
15  Using Arduino / Sensors / Re: Guide to gyro and accelerometer with Arduino including Kalman filtering on: October 29, 2013, 01:22:27 pm
Is called quaternions. You can find more information about it here: http://www.x-io.co.uk/quaternions/. Wikipedia is a good resource as well: http://en.wikipedia.org/wiki/Quaternion.
Pages: [1] 2 3 ... 19