Accelerometer data parsing
hi!
I'm running the stream_acc.py script and is working ok but am receiving what seems to be a 'CartesianFloat' for the type returned by '> parse_value(data)
' on line 21. this returns something like this: C3:CF:DF:88:22:43 -> {x : -0.031, y : -0.186, z : -0.987}
'
I would however like to get this data into a column form and manipulate it in pandas or something. It seems like what is returned is a single object-like structure and I can't separate the 'x','y','z', is there a helper function to do this? thank you
https://github.com/mbientlab/MetaWear-SDK-Python/blob/master/examples/stream_acc.py
Comments
https://docs.python.org/2/library/ctypes.html#structures-and-unions
thank you!
TL;DR
The answer is: x_value = parse_value(data).x, etc.