Arduino sensor-fusion firmware for estimating orientation using accelerometers, rate-gyroscopes, and magnetometers.