Lines Matching full:imu

119 /* SPI storage addresses of IMU factory calibration data */
124 /* SPI storage addresses of IMU user calibration data */
138 /* Under most circumstances IMU reports are pushed every 15ms; use as default */
140 /* How many samples to sum before calculating average IMU report delta */
142 /* Controls how many dropped IMU packets at once trigger a warning message */
397 /* IMU input reports contain 3 samples */
473 /* imu */
477 unsigned int imu_last_pkt_ms; /* used to calc imu report delta */
478 /* the following are used to track the average imu report time delta */
894 * dependent on the IMU calibration values. They are used when processing the
895 * IMU input reports.
919 hid_warn(ctlr->hdev, "inaccurate IMU divisors (%d)\n", divz); in joycon_calc_imu_cal_divisors()
936 hid_info(ctlr->hdev, "using user cal for IMU\n"); in joycon_request_imu_calibration()
938 hid_info(ctlr->hdev, "using factory cal for IMU\n"); in joycon_request_imu_calibration()
941 /* request IMU calibration data */ in joycon_request_imu_calibration()
942 hid_dbg(ctlr->hdev, "requesting IMU cal data\n"); in joycon_request_imu_calibration()
947 "Failed to read IMU cal, using defaults; ret=%d\n", in joycon_request_imu_calibration()
960 /* IMU calibration parsing */ in joycon_request_imu_calibration()
972 hid_dbg(ctlr->hdev, "IMU calibration:\n" in joycon_request_imu_calibration()
1028 hid_dbg(ctlr->hdev, "enabling IMU\n"); in joycon_enable_imu()
1066 /* point to next imu sample */ in joycon_input_report_parse_imu_data()
1085 * associate with the samples we pass to userspace. The IMU input in joycon_parse_imu_report()
1094 * - The controller samples the IMU every 1.35ms. It then does some of in joycon_parse_imu_report()
1096 * - Each imu input report contains 3 IMU samples, (usually 5ms apart). in joycon_parse_imu_report()
1110 * reports IMU sample batches every 11ms or every 15ms. This rate is in joycon_parse_imu_report()
1117 * time delta between IMU input reports. In testing, this value has in joycon_parse_imu_report()
1125 * samples, so the IMU sampling rate should be avg_time_delta/3. We can in joycon_parse_imu_report()
1141 /* avg imu report delta housekeeping */ in joycon_parse_imu_report()
1155 hid_warn(ctlr->hdev, "calculated avg imu delta of 0\n"); in joycon_parse_imu_report()
1158 /* useful for debugging IMU sample rate */ in joycon_parse_imu_report()
1170 "compensating for %u dropped IMU reports\n", in joycon_parse_imu_report()
1179 /* Each IMU input report contains three samples */ in joycon_parse_imu_report()
1237 * the orientation of the IMU in the controller. We negate those in joycon_parse_imu_report()
1455 /* parse IMU data if present */ in joycon_parse_report()
1701 imu_name = "Nintendo Switch Pro Controller IMU"; in joycon_input_create()
1706 imu_name = "Nintendo Switch Left Joy-Con IMU (Grip)"; in joycon_input_create()
1709 imu_name = "Nintendo Switch Right Joy-Con IMU (Grip)"; in joycon_input_create()
1714 imu_name = "Nintendo Switch Left Joy-Con IMU"; in joycon_input_create()
1718 imu_name = "Nintendo Switch Right Joy-Con IMU"; in joycon_input_create()
1803 /* configure the imu input device */ in joycon_input_create()
1817 /* configure imu axes */ in joycon_input_create()
2178 /* get IMU calibration data, and parse it */ in joycon_init()
2185 hid_warn(hdev, "Unable to read IMU calibration data\n"); in joycon_init()
2202 /* Enable the IMU */ in joycon_init()
2205 hid_err(hdev, "Failed to enable the IMU; ret=%d\n", ret); in joycon_init()