commit 760ad02672c03bfc9b13ba4c9f35a7a7363608c8
parent 430454d051afb19f2605e054b51291d0d95be7dc
Author: Luxferre <lux@ferre>
Date: Thu, 22 Dec 2022 17:25:30 +0200
Added GA-B001 and DW-B5600 models support
Diffstat:
3 files changed, 7 insertions(+), 5 deletions(-)
diff --git a/README.md b/README.md
@@ -18,9 +18,11 @@ RCVD is the missing KaiOS application and, first and foremost, a [JS library](rc
## Supported models
- GW-B5600
+- DW-B5600
- GMW-B5000
- OCW-T200
-- GM-B2100
+- GM-B2100, GA-B2100
+- GA-B001
The list is incomplete and your watch may be supported too. Please [let me know](https://matrix.to/#/@luxferre:anonymousland.org) if this is the case!
diff --git a/manifest.webapp b/manifest.webapp
@@ -1,5 +1,5 @@
{
- "version": "0.0.2",
+ "version": "0.0.3",
"name": "RCVD",
"description": "Casio BLE-enabled watches time synchronization app",
"type": "certified",
diff --git a/rcvd.js b/rcvd.js
@@ -1,5 +1,5 @@
// RCVD.js: a small library for syncing time on BLE-enabled Casio watches
-// Tested on: GW-B5600BC, GMW-B5000D, OCW-T200S, GM-B2100BD
+// Tested on: GW-B5600BC, GMW-B5000D, OCW-T200S, GM-B2100BD, GA-B001G, DW-B5600G
// Compatible with both KaiOS 2.5.x and in-progress Web Bluetooth API spec
// Created by Luxferre in 2022, released into public domain
@@ -86,7 +86,7 @@ RCVD = (function(nav) {
var slist = [...plgen(30),...plgen(31)]
if(watchModel.indexOf('OCW') > 5)
slist = [[30,0],[30,1]]
- else if(watchModel.indexOf('B2100') > 5)
+ else if(watchModel.indexOf('B2100') > 5 || watchModel.indexOf('B001') > 5 || watchModel.indexOf('DW-B5600') > 5 )
slist = [[30,0],[30,1],[31,0],[31,1]]
var plist = [[29,0], [29,2], [29,4]].concat(slist); //populate the props list
(function cycle() {
@@ -125,7 +125,7 @@ RCVD = (function(nav) {
sync: dObj => new Promise((res, rej) => {
cyclePresyncProperties().then(_ => {
//set to the next second to make up for latency
- var d = dObj || new Date(Date.now() + 1000), year = d.getFullYear()
+ var d = dObj || new Date(Date.now() + 500), year = d.getFullYear()
execWriteCmd(Uint8Array.from([
9,
year&255, year>>>8,