Hello,
I want to get data from 2 IMUs and when I ran the Motion_async, I found out that it print 2 IMUs data with their IDS altogether. While I need the individual data from each IMU and have some calculation combining them together. I first try to code like this so I can get only one set of data from one IMU each time but then I found out each time I unplug and plug the IMU again, the ID is different.
if (message->messageType == FREESPACE_MESSAGE_MOTIONENGINEOUTPUT) {
rc = freespace_util_getAcceleration(&(message->motionEngineOutput), &acc);
if (rc == 0&&id==9) {
printf ("X: % 6.2f, Y: % 6.2f, Z: % 6.2f\n", acc.x, acc.y, acc.z);
}
Can anyone helps that if each IMU has its own fixed ID like its name and How can I get it and use it to identify and get the set of data from a IMU of specific ID?
Thanks a lot.
Wei Zhang