Commit Graph

118 Commits (2834c72e2e7146ec27f6600cf1584a6eae4b6d70)

Author SHA1 Message Date
storm64 9105c94e1b [sleeplog] Replace onChange with trigger object 2022-11-16 22:46:49 +01:00
storm64 56e69cc32c [sleeplog] Initialise .onChange as object 2022-11-10 17:16:44 +01:00
storm64 58330df11c [sleeplog] Change .onChange from array to object 2022-11-10 17:04:54 +01:00
storm64 81aece08ee [sleeplog] Correct README.md 2022-11-10 01:27:37 +01:00
storm64 99663e4583 [sleeplog] onChange: + previous values and readme 2022-11-10 00:33:51 +01:00
storm64 74787f7b5e [sleeplog] Add option for onChange functions
Execute functions in `sleeplog.onChange[fn({timestamp, status, consecutive})]` on a status change
2022-09-12 23:15:39 +02:00
storm64 919ec8c34b [sleeplog] Update metadata.json
Edit screenshots
2022-08-29 23:15:41 +02:00
storm64 4824c4bcd4 [sleeplog] Update README.md + screenshots 2022-08-29 23:11:49 +02:00
storm64 0d59e20cd9 [sleeplog] Update README.md 2022-08-29 22:30:39 +02:00
storm64 c2eaa00aa0 [sleeplog] Update README.md 2022-08-29 22:25:19 +02:00
storm64 5f24e2b3e8
sleeplog: Update metadata.json
Match version with ChangeLog
2022-08-18 00:33:30 +02:00
storm64 68abc30707
sleeplog: Update ChangeLog
Reorganizing entries to match build dependencies
2022-08-18 00:31:58 +02:00
storm64 8c7e4ffeb2
sleeplog: Update ChangeLog
Reformatting entries to prevent build error.
2022-08-18 00:11:47 +02:00
storm64 bb683e2c1c
sleeplog: Update metadata.json 2022-08-17 23:24:34 +02:00
storm64 29e7f02059
sleeplog: Update ChangeLog 2022-08-17 23:23:27 +02:00
storm64 e9503bb08f
sleeplog: Update boot.js
Check for cached modules before removing to prevent module not found error.
2022-08-17 23:21:35 +02:00
storm64 aef6f638cb [sleeplog] Change caching for global getStats 2022-05-26 11:27:36 +02:00
storm64 76629a9d78 [sleeplog] Add "View log" in debug + send via BT
Add "View log" function for debugging log
Send data for gadgetbridge via BT
2022-05-26 10:41:56 +02:00
storm64 1a89f963ea [sleeplog] Redesign interfacce.html 2022-05-24 23:13:03 +02:00
storm64 71fc6f2859 [sleeplog] Update interface.html 2022-05-24 16:08:14 +02:00
storm64 ad10714556 [sleeplog] Update interface.html 2022-05-24 16:01:23 +02:00
storm64 6cbce8a0c5 [sleeplog] Update interface.html 2022-05-24 13:57:14 +02:00
storm64 732bc11c7f [sleeplog] Update interface.html 2022-05-24 13:41:02 +02:00
storm64 8445241a23 [sleeplog] Update interface.html 2022-05-24 13:31:42 +02:00
storm64 e1f4364ab0 [sleeplog] Update interface.html 2022-05-24 13:18:48 +02:00
storm64 5a7360b64f [sleeplog] Update interface.html 2022-05-24 13:16:03 +02:00
storm64 9ca37915b3 [sleeplog] Update interface.html 2022-05-24 13:01:54 +02:00
storm64 b9ed7e75a7 [sleeplog] Update interface.html
Replace unnecessary match with substr.
2022-05-24 12:58:56 +02:00
storm64 86fb6bc7b0 [sleeplog] Update interface.html 2022-05-24 12:52:08 +02:00
storm64 aef0000e65 [sleeplog] Update interface.html 2022-05-24 12:37:43 +02:00
storm64 dd4cb316dc [sleeplog] Redesigned interface.html 2022-05-24 12:28:17 +02:00
storm64 f5a9f47054 [sleeplog] Fixed usage of RegEx in interface.html 2022-05-24 10:52:30 +02:00
storm64 7d09a1229f [sleeplog] Fixed typos in interface.html (3) 2022-05-24 10:44:09 +02:00
storm64 7d4a61810e [sleeplog] Fixed typos in interface.html (2) 2022-05-24 10:38:19 +02:00
storm64 974194898e [sleeplog] Fix typos in interface.html 2022-05-24 10:34:46 +02:00
storm64 f1790695ea [sleeplog] Add interface.html 2022-05-24 10:14:10 +02:00
storm64 79938dcab4 [sleeplog] Update README.md
Correct timestamp information
2022-05-23 16:20:23 +02:00
storm64 fd5ed2b00a
[sleeplog] Update README.md 2022-05-20 20:25:19 +02:00
storm64 a3efd32981
[sleeplog] Update README.md 2022-05-20 20:20:13 +02:00
storm64 5e7d8c14b4
[sleeplog] Update README.md 2022-05-20 20:17:48 +02:00
storm64 cdff3173ba [sleeplog] Replace old icons 2022-05-20 20:14:05 +02:00
storm64 d13c8fb241 [sleeplog] Update README.md 2022-05-20 20:09:42 +02:00
storm64 6331f936f6 [sleeplog] Update README.md 2022-05-20 20:05:05 +02:00
storm64 c832017df4 [sleeplog] Update README.md 2022-05-20 20:02:46 +02:00
storm64 5c45f491d0 [sleeplog] Add todo entry + rename options 2022-05-20 18:28:05 +02:00
storm64 ae8ce7f1fd [sleeplog] Change default app timeout behavior 2022-05-20 18:22:11 +02:00
storm64 34ae1cdcf1 [sleeplog] Correct README.md 2022-05-20 17:42:10 +02:00
storm64 9c2df31379 [sleeplog] Remove emulator tag
Emulation impractical because of missing libraries and data.
2022-05-20 17:29:33 +02:00
storm64 a40a0e3477 [sleeplog] Update to do list 2022-05-20 17:21:23 +02:00
storm64 3ec051be9d [sleeplog] Complete rework, BETA v01 2022-05-20 17:17:30 +02:00
storm64 8102fd4e72 [sleeplog] Reduced log size further, see #1835
Reduced log size further to 750 entries
2022-05-17 17:51:10 +02:00
storm64 92ac8ee3f0 sleeplog: Fix LOW_MEMORY,MEMORY error #1835
Check and if neccessary reduce logsize to 1500 entries in writeLog() to prevent low mem error.
2022-05-17 09:18:39 +02:00
storm64 b32cc829f5 sleeplog: Update screenshots 2022-02-16 13:21:00 +01:00
storm64 ef4c2d0e12 sleeplog: Switch disabled.png and powersaving.png 2022-02-16 13:04:09 +01:00
storm64 9885caff71 Update README.md
Change description to icons
2022-02-16 13:00:39 +01:00
storm64 1ffcc42a93 Update ChangeLog
Remove commit description
2022-02-16 12:54:40 +01:00
storm64 a110a30ad5 sleeplog: Fix logfile disabling, add status icons
Update app.js
 - adjust label position to improve readability on light themes
 - add icons to display service states
Update ChangeLog
 - compact old and add new changes
Update lib.js
 - fix logfile correction in `setEnabled(...)` to make disable logging possible
 - simplify logfile checks
Update README.md
 - add icons of the service states
Update settings.js
 - fix error on reading a non string logfile value
Add icons: disabled.png, nolog.png and powersaving.png
2022-02-16 12:52:00 +01:00
storm64 01450290c4 Update README.md
Update README.md
 - change missed beautified menu entries according to changes in settings.js
2022-02-15 21:17:07 +01:00
storm64 8c4f2f18c9 sleeplog: Correct fix #1445, display loading info while calculating sleep data
Update app.js
 - move complex data analysis into separate function
 - add displaying a loading info
 - faster feedback by calling the analysis through a timeout
Update boot.js
 - correct fix #1445 as mentioned by splitting the `stop()` function to only remove the kill listener on a manual stop
 - optimize `start()` and `stop()` functions
Update README.md
 - change beautified menu entries according to changes in settings.js
Update settings.js
 - replace `circulate()` function with internal `wrap: true`
 - move delay for menu redraw as suggested in espruino/Espruino#2149
 - beautify menu entries for new touchscreen E.showMenu system (> fw 2v.13.32)
2022-02-15 19:47:15 +01:00
storm64 ab42b6555f sleeplog: Fix to be able to switch logging as intended
Update lib.js
 - fix error in `setEnabled(...)` when logfile=false
Update settings.js
 - use correct value for settings.logfile
2022-02-14 09:10:26 +01:00
storm64 f9be0db3c8 sleeplog: remove logging always, minimized workaround in settings menu
Update boot.js
 - remove logging always for testing
Update settings.js
 - minimized workaround in settings menu to [espruino/Espruino issue 2149](https://github.com/espruino/Espruino/issues/2149)
2022-02-14 08:18:16 +01:00
storm64 c8c1b7b914 sleeplog: Prevent removing other kill listeners #1445
Update boot.js
 - prevent removing other kill listeners #1445
Update README.md
 - change "only available" information for Settings
 - add new ideas to "To do list"
2022-02-13 22:39:57 +01:00
storm64 0ec1d57add sleeplog: Complete power saving mode + move all read/write log actions into lib.js
* Complete new power saving mode after tests
* Move all read/write log operations into lib/module
Update app.js
 - update `readLog(...)` call
Update boot.js
 - update maxmove default value
 - delete `log(..)`, merging into `writeLog(...)` from lib.js
 - replace all read/write actions to the logfile with `readLog(...)`/`writeLog(...)` from lib.js
 - add restoring the status after a restart (<5 min ago) to last known state
 - add deletion of unused settings on power saving mode
 - update log timestamp on power saving mode to always be 10min before now
Update ChangeLog
Update lib.js
 - update `readLog(...)`, prevent errors on reading, minimize workload if unfiltered
 - add `writeLog(...)` to append or replace log depending on input with plausibility checks on input
 - merging `log(...)` from boot.js into `writeLog(...)`
 - replace all read/write actions to the logfile with `readLog(...)`/`writeLog(...)`
Update metadata.json
 - update version number
 - add power saving mode to description
Update README.md
 - add power saving mode description
 - move sleeping/not worn decision description into its own section
 - add description for timestamp values to Logging section
 - update Global Object and Module Functions section
Update settings.js
 - update maxmove setting and default value
2022-02-13 20:54:26 +01:00
storm64 b8721fbdcf sleeplog: New power saving mode using build in movement detection
* New power saving mode using build in movement detection
Update app.js
 - add displaying powersaving status
Update boot.js
 - add power save mode
 - minimize fix #1425 to issue #1423
 - minimize wake/sleep decision
 - add checking for correct this reference
 - add checking for global object existence
 - remove unneeded global. prefix
Update lib.js
 - add powersaving setting to setEnabled()
 - fix missing logfile issue #1423 on all functions
 - remove check for changes in setEnabled(...) to always restart the service
Update settings.js
 - add settings powersaving and maxmove
 - add displaying settings depending on power saving mode
 - restart service when changing enabled, logfile and powersaving
2022-02-12 01:43:58 +01:00
Marco H 47d7aced65
Update metadata.json 2022-02-11 13:45:10 +01:00
Marco H ee104a2e8a
Update ChangeLog 2022-02-11 13:45:01 +01:00
Marco H 50b94d6870
Update boot.js
Fixes Uncaught Error: Expecting a string, got undefined
see https://github.com/espruino/BangleApps/issues/1423
2022-02-11 13:16:59 +01:00
storm64 02aeaff86b sleeplog: Add Sleep Log App
This app logs and displays the four following states:
_unknown, not worn, awake, sleeping_
It derived from the SleepPhaseAlarm and uses the accelerometer to estimate sleep and wake states with the principle of Estimation of Stationary Sleep-segments ([ESS](https://ubicomp.eti.uni-siegen.de/home/datasets/ichi14/index.html.en)) and the internal temperature to decide _sleeping_ or _not worn_ when the watch is resting.
2022-02-11 09:29:02 +01:00