[Dprglist] Ron's IMS presentation
Ron Grant
deltagraph at aol.com
Sun Mar 11 20:04:34 PDT 2018
Hello John, / All
Regarding my demo that wanted to freeze up/crash.
I am inclined to agree with you on some kind of buffering problem since my faster desktop machine at home had no trouble.
My quick and dirty fix was to add exception code (try catch block) on a string to floating point number conversion on my string data from controller. That is a line with accelerometer data and Euler angles might look like
A 0.003 0.002 1.004 E 0.0 0.1 0.1
where the program does a pretty dumb conversion of really just tokens longer than 2 characters expecting they are the numbers of interest. Usually I go for binary data, but wanted something very simple that is human readable if streamed to a terminal program...
By the way here is a link to Sebastian Madgwick's Paper which by the way does have ability to remove gyro bias provided the filter is tuned with adequate gain on the feedback of measurement errors that are not mean of 0, e.g. constant bias value.
http://x-io.co.uk/res/doc/madgwick_internal_report.pdf
(also includes C code)
I am not there yet on quaternion derivatives used in Madgwick's paper, looks like cool stuff. I think I got about as far as understanding of how to derive the sensor orientation knowing magnetic north and down vector which is pretty cool stuff. Will figured it out very fast then beat it into me.
In short, using the beauty of 3D vector cross product creating a vector perpendicular to the plane of the crossed vectors:
The cross product of the gravity vector (resultant of accelerometer XYZ vectors) pointing down crossed with magnetic north (resultant of magnetometer XYZ) (which points toward north, but below the horizon) gives you a vector pointing east along horizon then you can cross east vector onto down vector to get north (aligned with horizon). If I got that right. Anyway, interesting stuff that I used when processing raw sensor data before having access to Madgwick's code.
I will try to get my processing code and arduino code up for IMU soon.
Also, hope to play with BNO55 based sensor module from Adafruit that Scott Gibson mentioned works very well with his outdoor robot with compass (magnetometer) disabled.
https://www.bosch-sensortec.com/bst/products/all_products/bno055
Ron
-----Original Message-----
From: John Swindle <swindle at compuserve.com>
To: dprglist <dprglist at lists.dprg.org>
Sent: Sun, Mar 11, 2018 12:29 pm
Subject: [Dprglist] Ron's IMS presentation
Ron,
Thanks for the presentation on the very affordable and tiny IMS. Good stuff.
Not sure I had your email address, so this goes to the group, sorry if it's off topic.
The hang in the PC window that was displaying your raw data and the graphic might have been a console buffer overflow. I see this problem. I am running 24 small PCs that are searching for interesting numbers (no, it isn't bitcoin, but that would be nice), and after several days or weeks of running, displaying a few hundred thousand lines, several of them will hang in the output window of my program. While researching this, I found that there are bugs in the console libraries that result in the console overflowing and then hanging. In my case, after a few weeks of running, a console output window hang on one instance of the program sometimes causes another instance to crash completely. My systems that have the least memory crash first, and the ones with the most memory don't crash. (My program only uses 100KB of memory, so the program itself is not hogging memory.) Anyway, the console problem is fairly common problem and it might be biting you.
Best to you,
John Swindle
_______________________________________________
DPRGlist mailing list
DPRGlist at lists.dprg.org
http://lists.dprg.org/listinfo.cgi/dprglist-dprg.org
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.dprg.org/pipermail/dprglist-dprg.org/attachments/20180311/4f2caf60/attachment.html>
More information about the DPRGlist
mailing list