Swadge 2024 2.0.0
APIs to develop games for the Magfest Swadge
All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
imu_utils.h
Go to the documentation of this file.
1
38
39#pragma once
40
41#include <stdbool.h>
42#include <stdint.h>
43#include "linked_list.h"
44
48typedef struct
49{
50 int16_t x;
51 int16_t y;
52 int16_t z;
53} vec3d_t;
54
55bool checkForShake(vec3d_t* lastOrientation, list_t* shakeHistory, bool* isShook);
int16_t z
The z component of the vector.
Definition imu_utils.h:52
int16_t x
The x component of the vector.
Definition imu_utils.h:50
bool checkForShake(vec3d_t *lastOrientation, list_t *shakeHistory, bool *isShook)
Check if a shake was detected. All of the arguments for this function are both inputs and outputs.
Definition imu_utils.c:26
int16_t y
The y component of the vector.
Definition imu_utils.h:51
A general purpose 3D vector.
Definition imu_utils.h:49
A doubly linked list with pointers to the first and last nodes.
Definition linked_list.h:87