Hi, Have been playing around with your code and figured out what the possible problem is with the zero values. You essentially try to read 4 packets from the device in 1 read and then decode them into x,y and z assuming they are always send in the same order. However it looks like the sensor/driver does not send a string when the measured value is 0, (can even been seen with hexdump, I'm using SHR with updated kernel from bug 2145 to get around the threshold problem.) If that happens your xyz may get the wrong values resulting in , you'll have to check each message for type and code before you use the value. Efficiency is good, but be careful with shortcuts.... -- View this message in context: http://n2.nabble.com/Announce%3A-omnewrotate-0.5.0-tp1521019p1598202.html Sent from the Openmoko Community mailing list archive at Nabble.com.
_______________________________________________ Openmoko community mailing list community@lists.openmoko.org http://lists.openmoko.org/mailman/listinfo/community