forked from Blendman974/faceclaw
Port developer debug tests to iOS
This commit is contained in:
1 parent
bc57557f04
commit
a5eda29368
16 files changed
+737
-151
No files matched your search
+3
-15
@@ -12,7 +12,9 @@ declare const com: any;
|
||||
* static, so it works from any isolate without threading the bridge through.
|
||||
*/
|
||||
|
||||
export type ImuReading = { x: number; y: number; z: number; source: number };
|
||||
import { type ImuReading } from "./imu-types";
|
||||
|
||||
export * from "./imu-types";
|
||||
|
||||
function activeCommunicator(): any {
|
||||
if (!global.isAndroid) return null;
|
||||
@@ -52,17 +54,3 @@ export function addImuListener(listener: (reading: ImuReading) => void): () => v
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
/** Map an IMU sample's EventSource to a short label. */
|
||||
export function imuSourceLabel(source: number): string {
|
||||
switch (source) {
|
||||
case 1:
|
||||
return "R arm";
|
||||
case 2:
|
||||
return "ring";
|
||||
case 3:
|
||||
return "L arm";
|
||||
default:
|
||||
return "device";
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user