recorder 0.48: Add ability to log average acceleration values
parent
5f052d9a8f
commit
16a25f245a
|
|
@ -60,4 +60,5 @@
|
||||||
Lower accuracy of barometer data to ~1cm (saves about 15b/record)
|
Lower accuracy of barometer data to ~1cm (saves about 15b/record)
|
||||||
0.47: Fix 'blip' on speed map on some recordings
|
0.47: Fix 'blip' on speed map on some recordings
|
||||||
Ensure Battery voltage is only stored to 0.01v
|
Ensure Battery voltage is only stored to 0.01v
|
||||||
Add graphs for Steps+Battery
|
Add graphs for Steps+Battery
|
||||||
|
0.48: Add ability to log average acceleration values
|
||||||
|
|
@ -19,6 +19,7 @@ You can record
|
||||||
* **BAT** Battery percentage and voltage
|
* **BAT** Battery percentage and voltage
|
||||||
* **Steps** Steps counted by the step counter
|
* **Steps** Steps counted by the step counter
|
||||||
* **Baro** (Bangle.js 2) Using the built-in barometer to record Temperature, Pressure and Altitude
|
* **Baro** (Bangle.js 2) Using the built-in barometer to record Temperature, Pressure and Altitude
|
||||||
|
* **Accel** Average acceleration values in X,Y and Z
|
||||||
* **Core** CoreTemp body temperature *if* you have a CoreTemp device and the https://banglejs.com/apps/?id=coretemp app installed
|
* **Core** CoreTemp body temperature *if* you have a CoreTemp device and the https://banglejs.com/apps/?id=coretemp app installed
|
||||||
|
|
||||||
You can then start/stop recording from the Recorder app itself (and as long as widgets are
|
You can then start/stop recording from the Recorder app itself (and as long as widgets are
|
||||||
|
|
|
||||||
|
|
@ -114,6 +114,28 @@ exports.getRecorders = function() {
|
||||||
stop : () => {},
|
stop : () => {},
|
||||||
draw : (x,y) => g.reset().drawImage(atob("DAwBAAMMeeeeeeeecOMMAAMMMMAA"),x,y)
|
draw : (x,y) => g.reset().drawImage(atob("DAwBAAMMeeeeeeeecOMMAAMMMMAA"),x,y)
|
||||||
};
|
};
|
||||||
|
},
|
||||||
|
accel:function() {
|
||||||
|
var ax=0,ay=0,az=0,n=0;
|
||||||
|
function onAccel(a) {
|
||||||
|
ax += a.x;
|
||||||
|
ay += a.y;
|
||||||
|
az += a.z;
|
||||||
|
n++;
|
||||||
|
}
|
||||||
|
return {
|
||||||
|
name : "Accel",
|
||||||
|
fields : ["Accel X", "Accel Y", "Accel Z"],
|
||||||
|
getValues : () => {
|
||||||
|
if (n<1) n=1;
|
||||||
|
var r = [(ax/n).toFixed(2), (ay/n).toFixed(2), (az/n).toFixed(2)];
|
||||||
|
n = ax = ay = az = 0;
|
||||||
|
return r;
|
||||||
|
},
|
||||||
|
start : () => { Bangle.on('accel', onAccel); },
|
||||||
|
stop : () => { Bangle.removeListener('accel', onAccel); },
|
||||||
|
draw : (x,y) => g.reset().drawImage(atob("DAwBAAMMeeeeeeeecOMMAAMMMMAA"),x,y)
|
||||||
|
};
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
if (Bangle.getPressure){
|
if (Bangle.getPressure){
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@
|
||||||
"id": "recorder",
|
"id": "recorder",
|
||||||
"name": "Recorder",
|
"name": "Recorder",
|
||||||
"shortName": "Recorder",
|
"shortName": "Recorder",
|
||||||
"version": "0.47",
|
"version": "0.48",
|
||||||
"description": "Record GPS position, heart rate and more in the background, then download to your PC.",
|
"description": "Record GPS position, heart rate and more in the background, then download to your PC.",
|
||||||
"icon": "app.png",
|
"icon": "app.png",
|
||||||
"tags": "tool,outdoors,gps,widget,clkinfo",
|
"tags": "tool,outdoors,gps,widget,clkinfo",
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue