@openmouse/protocol 0.36.0 → 0.38.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -0
- package/dist/ajazz/index.d.ts +95 -4
- package/dist/ajazz/index.d.ts.map +1 -1
- package/dist/ajazz/index.js +204 -4
- package/dist/ajazz/index.js.map +1 -1
- package/dist/drivers/ajazz/hid.d.ts +50 -8
- package/dist/drivers/ajazz/hid.d.ts.map +1 -1
- package/dist/drivers/ajazz/hid.js +174 -29
- package/dist/drivers/ajazz/hid.js.map +1 -1
- package/dist/drivers/endgame/egg-ot-hid.d.ts +108 -0
- package/dist/drivers/endgame/egg-ot-hid.d.ts.map +1 -0
- package/dist/drivers/endgame/egg-ot-hid.js +407 -0
- package/dist/drivers/endgame/egg-ot-hid.js.map +1 -0
- package/dist/drivers/registry.d.ts +2 -1
- package/dist/drivers/registry.d.ts.map +1 -1
- package/dist/drivers/registry.js +5 -1
- package/dist/drivers/registry.js.map +1 -1
- package/dist/endgame-gear/op1.d.ts +14 -0
- package/dist/endgame-gear/op1.d.ts.map +1 -1
- package/dist/endgame-gear/op1.js +34 -0
- package/dist/endgame-gear/op1.js.map +1 -1
- package/dist/endgame-gear/ot.d.ts +318 -0
- package/dist/endgame-gear/ot.d.ts.map +1 -0
- package/dist/endgame-gear/ot.js +527 -0
- package/dist/endgame-gear/ot.js.map +1 -0
- package/dist/endgame-gear/wireless.d.ts +7 -0
- package/dist/endgame-gear/wireless.d.ts.map +1 -1
- package/dist/endgame-gear/wireless.js +3 -0
- package/dist/endgame-gear/wireless.js.map +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/package.json +5 -1
package/README.md
CHANGED
|
@@ -45,6 +45,7 @@ checklist.
|
|
|
45
45
|
| Dareu | `@openmouse/protocol/dareu` |
|
|
46
46
|
| Delux M800 Mini / M600 Pro | `@openmouse/protocol/delux` |
|
|
47
47
|
| Endgame Gear OP1/XM2 8K | `@openmouse/protocol/endgame-gear-op1` |
|
|
48
|
+
| Endgame Gear XM1r/OP1/OP1 RGB | `@openmouse/protocol/endgame-gear-ot` |
|
|
48
49
|
| Endgame Gear wireless | `@openmouse/protocol/endgame-gear-we` |
|
|
49
50
|
| Fantech | `@openmouse/protocol/fantech` |
|
|
50
51
|
| Finalmouse | `@openmouse/protocol/finalmouse` |
|
package/dist/ajazz/index.d.ts
CHANGED
|
@@ -2,8 +2,10 @@
|
|
|
2
2
|
* AJAZZ NJ07 / NJ08 configuration protocol ("V1" device class of the vendor
|
|
3
3
|
* WebHID panel at https://nacodex.yjx2012.com/, Next.js chunk 515).
|
|
4
4
|
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
5
|
+
* Config, battery and version frames are confirmed against a real NJ07 MC
|
|
6
|
+
* (PID 0x2167, firmware 2.0.1, ticket 0156), including a flash write
|
|
7
|
+
* round-trip. The key-map frames below follow the same panel JavaScript and
|
|
8
|
+
* are still unverified on hardware.
|
|
7
9
|
*
|
|
8
10
|
* Transport: output report 0xF0 carrying 63 bytes, answered by an input
|
|
9
11
|
* report whose first data byte echoes the command. The control collection is
|
|
@@ -49,13 +51,15 @@ export declare const AJAZZ_POLLING_RATES: readonly [125, 250, 500, 1000];
|
|
|
49
51
|
export declare const AJAZZ_OFFERED_POLLING_RATES: readonly [125, 500, 1000];
|
|
50
52
|
export declare function ajazzEncodePollingRate(hz: number): number | null;
|
|
51
53
|
export declare function ajazzDecodePollingRate(index: number): number | null;
|
|
52
|
-
/** Auto-sleep choices offered in the UI, in seconds. The panel allows
|
|
53
|
-
export declare const AJAZZ_SLEEP_OPTIONS: readonly [60, 180, 300, 600, 1200, 1800, 3600];
|
|
54
|
+
/** Auto-sleep choices offered in the UI, in seconds. The panel allows 0 to 100 minutes. */
|
|
55
|
+
export declare const AJAZZ_SLEEP_OPTIONS: readonly [0, 60, 180, 300, 600, 1200, 1800, 3600];
|
|
54
56
|
/** The panel's sleep slider runs 0 to 100 minutes and 0 means never sleep. */
|
|
55
57
|
export declare const AJAZZ_SLEEP_MAX_MINUTES = 100;
|
|
56
58
|
export declare function ajazzIsValidSleepSeconds(seconds: number): boolean;
|
|
57
59
|
export declare const AJAZZ_CMD: {
|
|
58
60
|
readonly GET_VERSION: 4;
|
|
61
|
+
readonly GET_KEYS: 8;
|
|
62
|
+
readonly SET_KEYS: 9;
|
|
59
63
|
readonly GET_CONFIG: 14;
|
|
60
64
|
readonly SET_CONFIG: 15;
|
|
61
65
|
readonly GET_BATTERY: 48;
|
|
@@ -111,4 +115,91 @@ export declare function ajazzDecodeConfig(reply: Uint8Array): AjazzConfig | null
|
|
|
111
115
|
* zero exactly as the panel sends them.
|
|
112
116
|
*/
|
|
113
117
|
export declare function ajazzEncodeSetConfig(config: AjazzConfig): Uint8Array;
|
|
118
|
+
/**
|
|
119
|
+
* Button map ("V1" `getMouseKeys()` / `setMouseKeys()` / `resetAllMouseKeys()`).
|
|
120
|
+
*
|
|
121
|
+
* GET_KEYS is body `[0x08, 0x01, 0x0B, 0x2C]`; the reply echoes `0x08` and
|
|
122
|
+
* carries six four-byte slots at reply[7..30]. SET_KEYS is body
|
|
123
|
+
* `[0x09, 0x01, 0x22, 0x30]` with eight slots at body[7..38]: the six
|
|
124
|
+
* remappable buttons followed by two fixed wheel entries (scroll up, scroll
|
|
125
|
+
* down), exactly as the panel's template sends them. `resetAllMouseKeys()`
|
|
126
|
+
* sends the same frame with the six factory defaults up front.
|
|
127
|
+
*
|
|
128
|
+
* Slot types come from the panel's `keys.json` catalog: 32 = mouse button
|
|
129
|
+
* (code1 = HID bitmask, 0 = disabled), 16 = keyboard (code1 = modifier bits,
|
|
130
|
+
* code2 = HID usage), 33 = special (DPI loop [85,0,0], scroll [56,1/255]),
|
|
131
|
+
* 48 = consumer/media (code1 = consumer usage low byte, code2 = page bits),
|
|
132
|
+
* 112 = a macro slot (code1 = macro index). A slot read back as type 0 or
|
|
133
|
+
* 0xff means the panel keeps its default for that button.
|
|
134
|
+
*/
|
|
135
|
+
/** User-remappable buttons in wire order. */
|
|
136
|
+
export declare const AJAZZ_BUTTON_NAMES: readonly ["Left", "Right", "Middle", "Backward", "Forward", "DPI"];
|
|
137
|
+
/** Remappable wire slots; slots 6-7 are the fixed wheel entries. */
|
|
138
|
+
export declare const AJAZZ_KEY_SLOTS = 6;
|
|
139
|
+
export declare const AJAZZ_KEY_WIRE_SLOTS = 8;
|
|
140
|
+
/** Button function types from the vendor key catalog. */
|
|
141
|
+
export declare const AJAZZ_KEY_TYPE: {
|
|
142
|
+
readonly keyboard: 16;
|
|
143
|
+
readonly mouse: 32;
|
|
144
|
+
readonly special: 33;
|
|
145
|
+
readonly media: 48;
|
|
146
|
+
readonly macro: 112;
|
|
147
|
+
};
|
|
148
|
+
/** One button slot: four raw bytes, carried losslessly. */
|
|
149
|
+
export interface AjazzKeyBinding {
|
|
150
|
+
type: number;
|
|
151
|
+
code1: number;
|
|
152
|
+
code2: number;
|
|
153
|
+
code3: number;
|
|
154
|
+
}
|
|
155
|
+
export declare function ajazzIsKnownKeyType(type: number): boolean;
|
|
156
|
+
/** Factory button map from every model's `mouse_info_*.json` DefaultProfile. */
|
|
157
|
+
export declare const AJAZZ_DEFAULT_KEYS: ReadonlyArray<AjazzKeyBinding>;
|
|
158
|
+
/** Fixed wheel entries the panel always appends as wire slots 6-7. */
|
|
159
|
+
export declare const AJAZZ_FIXED_WHEEL_KEYS: ReadonlyArray<AjazzKeyBinding>;
|
|
160
|
+
/** GET_KEYS request body observed in vendor JS: [0x08, 0x01, 0x0B, 0x2C]. */
|
|
161
|
+
export declare function ajazzGetKeysRequest(): Uint8Array;
|
|
162
|
+
/**
|
|
163
|
+
* Decode a GET_KEYS reply: six slots of four bytes at reply[7..30] (the
|
|
164
|
+
* vendor slices 7). Returns null when the reply answers another command.
|
|
165
|
+
*/
|
|
166
|
+
export declare function ajazzDecodeKeys(reply: Uint8Array): AjazzKeyBinding[] | null;
|
|
167
|
+
/**
|
|
168
|
+
* Plausibility gate for decoded key maps. The vendor panel treats a slot read
|
|
169
|
+
* back as type 0 or 0xff as a default-binding marker (it keeps its own
|
|
170
|
+
* default for that button), so markers are accepted per slot. Anything else
|
|
171
|
+
* outside the 16/32/33/48/112 catalog is rejected as a crossed or
|
|
172
|
+
* half-filled report.
|
|
173
|
+
*/
|
|
174
|
+
export declare function ajazzKeysLookPlausible(keys: readonly AjazzKeyBinding[]): boolean;
|
|
175
|
+
/**
|
|
176
|
+
* Substitute the factory defaults for default-binding markers (type 0/0xff),
|
|
177
|
+
* mirroring the vendor panel's merge of a freshly read map over its own
|
|
178
|
+
* defaults. Real bindings pass through untouched.
|
|
179
|
+
*/
|
|
180
|
+
export declare function ajazzApplyKeyDefaults(keys: readonly AjazzKeyBinding[]): AjazzKeyBinding[];
|
|
181
|
+
/**
|
|
182
|
+
* Encode a SET_KEYS request, mirroring vendor `setMouseKeys()`: head
|
|
183
|
+
* [0x09, 0x01, 0x22, 0x30], the six bindings at body[7..30], then the two
|
|
184
|
+
* fixed wheel entries at body[31..38].
|
|
185
|
+
*/
|
|
186
|
+
export declare function ajazzEncodeSetKeys(keys: readonly AjazzKeyBinding[]): Uint8Array;
|
|
187
|
+
/**
|
|
188
|
+
* Remappable actions from the vendor key catalog (display label + bytes).
|
|
189
|
+
* Keyboard usages use the type-16 encoding with a zero modifier byte; combos
|
|
190
|
+
* with modifiers still read back losslessly as opaque bindings. Macro slots
|
|
191
|
+
* (type 112) are intentionally absent: the panel keeps macros in localStorage
|
|
192
|
+
* and uploads them separately, so there is no fixed onboard slot count yet.
|
|
193
|
+
*/
|
|
194
|
+
export declare const AJAZZ_BUTTON_ACTIONS: ReadonlyArray<{
|
|
195
|
+
label: string;
|
|
196
|
+
type: number;
|
|
197
|
+
code1: number;
|
|
198
|
+
code2: number;
|
|
199
|
+
code3: number;
|
|
200
|
+
}>;
|
|
201
|
+
/** Display label for a binding, or null when the catalog cannot name it. */
|
|
202
|
+
export declare function ajazzBindingLabel(binding: AjazzKeyBinding): string | null;
|
|
203
|
+
/** Catalog binding for a display label, or null for unknown labels. */
|
|
204
|
+
export declare function ajazzFindButtonAction(label: string): AjazzKeyBinding | null;
|
|
114
205
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/ajazz/index.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/ajazz/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AAEH,eAAO,MAAM,mBAAmB,QAAS,CAAC;AAC1C,eAAO,MAAM,sBAAsB,QAAS,CAAC;AAC7C,eAAO,MAAM,gBAAgB,QAAS,CAAC;AACvC,eAAO,MAAM,WAAW,KAAO,CAAC;AAChC,eAAO,MAAM,eAAe,MAAO,CAAC;AACpC,eAAO,MAAM,gBAAgB,KAAK,CAAC;AAEnC,MAAM,WAAW,YAAY;IAC3B,KAAK,EAAE,MAAM,CAAC;IACd,2DAA2D;IAC3D,MAAM,EAAE,MAAM,CAAC;CAChB;AAED;;;;;GAKG;AACH,eAAO,MAAM,cAAc,EAAE,WAAW,CAAC,MAAM,EAAE,YAAY,CAO3D,CAAC;AAEH,eAAO,MAAM,aAAa,KAAK,CAAC;AAChC,eAAO,MAAM,cAAc,KAAK,CAAC;AACjC,eAAO,MAAM,gBAAgB,IAAI,CAAC;AAElC,wBAAgB,eAAe,CAAC,GAAG,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,GAAG,OAAO,CAEpE;AAED,oEAAoE;AACpE,eAAO,MAAM,mBAAmB,gCAAiC,CAAC;AAElE,+EAA+E;AAC/E,eAAO,MAAM,2BAA2B,2BAA4B,CAAC;AAErE,wBAAgB,sBAAsB,CAAC,EAAE,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,CAGhE;AAED,wBAAgB,sB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AE,GAAG,UAAU,CAW/E;AAED;;;;;;GAMG;AACH,eAAO,MAAM,oBAAoB,EAAE,aAAa,CAAC;IAC/C,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;CACf,CAwDA,CAAC;AAEF,4EAA4E;AAC5E,wBAAgB,iBAAiB,CAAC,OAAO,EAAE,eAAe,GAAG,MAAM,GAAG,IAAI,CAWzE;AAED,uEAAuE;AACvE,wBAAgB,qBAAqB,CAAC,KAAK,EAAE,MAAM,GAAG,eAAe,GAAG,IAAI,CAG3E"}
|
package/dist/ajazz/index.js
CHANGED
|
@@ -2,8 +2,10 @@
|
|
|
2
2
|
* AJAZZ NJ07 / NJ08 configuration protocol ("V1" device class of the vendor
|
|
3
3
|
* WebHID panel at https://nacodex.yjx2012.com/, Next.js chunk 515).
|
|
4
4
|
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
5
|
+
* Config, battery and version frames are confirmed against a real NJ07 MC
|
|
6
|
+
* (PID 0x2167, firmware 2.0.1, ticket 0156), including a flash write
|
|
7
|
+
* round-trip. The key-map frames below follow the same panel JavaScript and
|
|
8
|
+
* are still unverified on hardware.
|
|
7
9
|
*
|
|
8
10
|
* Transport: output report 0xF0 carrying 63 bytes, answered by an input
|
|
9
11
|
* report whose first data byte echoes the command. The control collection is
|
|
@@ -58,11 +60,13 @@ export function ajazzEncodePollingRate(hz) {
|
|
|
58
60
|
export function ajazzDecodePollingRate(index) {
|
|
59
61
|
return index >= 0 && index < AJAZZ_POLLING_RATES.length ? AJAZZ_POLLING_RATES[index] : null;
|
|
60
62
|
}
|
|
61
|
-
/** Auto-sleep choices offered in the UI, in seconds. The panel allows
|
|
62
|
-
export const AJAZZ_SLEEP_OPTIONS = [60, 180, 300, 600, 1200, 1800, 3600];
|
|
63
|
+
/** Auto-sleep choices offered in the UI, in seconds. The panel allows 0 to 100 minutes. */
|
|
64
|
+
export const AJAZZ_SLEEP_OPTIONS = [0, 60, 180, 300, 600, 1200, 1800, 3600];
|
|
63
65
|
/** The panel's sleep slider runs 0 to 100 minutes and 0 means never sleep. */
|
|
64
66
|
export const AJAZZ_SLEEP_MAX_MINUTES = 100;
|
|
65
67
|
export function ajazzIsValidSleepSeconds(seconds) {
|
|
68
|
+
if (seconds === 0)
|
|
69
|
+
return true; // the panel's "never sleep"
|
|
66
70
|
return (Number.isInteger(seconds) &&
|
|
67
71
|
seconds >= 60 &&
|
|
68
72
|
seconds % 60 === 0 &&
|
|
@@ -70,6 +74,8 @@ export function ajazzIsValidSleepSeconds(seconds) {
|
|
|
70
74
|
}
|
|
71
75
|
const CMD = {
|
|
72
76
|
GET_VERSION: 0x04,
|
|
77
|
+
GET_KEYS: 0x08,
|
|
78
|
+
SET_KEYS: 0x09,
|
|
73
79
|
GET_CONFIG: 0x0e,
|
|
74
80
|
SET_CONFIG: 0x0f,
|
|
75
81
|
GET_BATTERY: 0x30,
|
|
@@ -172,4 +178,198 @@ export function ajazzEncodeSetConfig(config) {
|
|
|
172
178
|
out[53] = config.wakeByte;
|
|
173
179
|
return out;
|
|
174
180
|
}
|
|
181
|
+
/**
|
|
182
|
+
* Button map ("V1" `getMouseKeys()` / `setMouseKeys()` / `resetAllMouseKeys()`).
|
|
183
|
+
*
|
|
184
|
+
* GET_KEYS is body `[0x08, 0x01, 0x0B, 0x2C]`; the reply echoes `0x08` and
|
|
185
|
+
* carries six four-byte slots at reply[7..30]. SET_KEYS is body
|
|
186
|
+
* `[0x09, 0x01, 0x22, 0x30]` with eight slots at body[7..38]: the six
|
|
187
|
+
* remappable buttons followed by two fixed wheel entries (scroll up, scroll
|
|
188
|
+
* down), exactly as the panel's template sends them. `resetAllMouseKeys()`
|
|
189
|
+
* sends the same frame with the six factory defaults up front.
|
|
190
|
+
*
|
|
191
|
+
* Slot types come from the panel's `keys.json` catalog: 32 = mouse button
|
|
192
|
+
* (code1 = HID bitmask, 0 = disabled), 16 = keyboard (code1 = modifier bits,
|
|
193
|
+
* code2 = HID usage), 33 = special (DPI loop [85,0,0], scroll [56,1/255]),
|
|
194
|
+
* 48 = consumer/media (code1 = consumer usage low byte, code2 = page bits),
|
|
195
|
+
* 112 = a macro slot (code1 = macro index). A slot read back as type 0 or
|
|
196
|
+
* 0xff means the panel keeps its default for that button.
|
|
197
|
+
*/
|
|
198
|
+
/** User-remappable buttons in wire order. */
|
|
199
|
+
export const AJAZZ_BUTTON_NAMES = ["Left", "Right", "Middle", "Backward", "Forward", "DPI"];
|
|
200
|
+
/** Remappable wire slots; slots 6-7 are the fixed wheel entries. */
|
|
201
|
+
export const AJAZZ_KEY_SLOTS = 6;
|
|
202
|
+
export const AJAZZ_KEY_WIRE_SLOTS = 8;
|
|
203
|
+
/** Button function types from the vendor key catalog. */
|
|
204
|
+
export const AJAZZ_KEY_TYPE = {
|
|
205
|
+
keyboard: 16,
|
|
206
|
+
mouse: 32,
|
|
207
|
+
special: 33,
|
|
208
|
+
media: 48,
|
|
209
|
+
macro: 112,
|
|
210
|
+
};
|
|
211
|
+
export function ajazzIsKnownKeyType(type) {
|
|
212
|
+
return (type === AJAZZ_KEY_TYPE.keyboard ||
|
|
213
|
+
type === AJAZZ_KEY_TYPE.mouse ||
|
|
214
|
+
type === AJAZZ_KEY_TYPE.special ||
|
|
215
|
+
type === AJAZZ_KEY_TYPE.media ||
|
|
216
|
+
type === AJAZZ_KEY_TYPE.macro);
|
|
217
|
+
}
|
|
218
|
+
/** Factory button map from every model's `mouse_info_*.json` DefaultProfile. */
|
|
219
|
+
export const AJAZZ_DEFAULT_KEYS = [
|
|
220
|
+
{ type: 32, code1: 1, code2: 0, code3: 0 },
|
|
221
|
+
{ type: 32, code1: 2, code2: 0, code3: 0 },
|
|
222
|
+
{ type: 32, code1: 4, code2: 0, code3: 0 },
|
|
223
|
+
{ type: 32, code1: 8, code2: 0, code3: 0 },
|
|
224
|
+
{ type: 32, code1: 16, code2: 0, code3: 0 },
|
|
225
|
+
{ type: 33, code1: 85, code2: 0, code3: 0 },
|
|
226
|
+
];
|
|
227
|
+
/** Fixed wheel entries the panel always appends as wire slots 6-7. */
|
|
228
|
+
export const AJAZZ_FIXED_WHEEL_KEYS = [
|
|
229
|
+
{ type: 33, code1: 56, code2: 1, code3: 0 },
|
|
230
|
+
{ type: 33, code1: 56, code2: 255, code3: 0 },
|
|
231
|
+
];
|
|
232
|
+
/** GET_KEYS request body observed in vendor JS: [0x08, 0x01, 0x0B, 0x2C]. */
|
|
233
|
+
export function ajazzGetKeysRequest() {
|
|
234
|
+
return body(CMD.GET_KEYS, 0x01, 0x0b, 0x2c);
|
|
235
|
+
}
|
|
236
|
+
/**
|
|
237
|
+
* Decode a GET_KEYS reply: six slots of four bytes at reply[7..30] (the
|
|
238
|
+
* vendor slices 7). Returns null when the reply answers another command.
|
|
239
|
+
*/
|
|
240
|
+
export function ajazzDecodeKeys(reply) {
|
|
241
|
+
if (reply[0] !== CMD.GET_KEYS || reply.length < 7 + AJAZZ_KEY_SLOTS * 4)
|
|
242
|
+
return null;
|
|
243
|
+
const bindings = [];
|
|
244
|
+
for (let i = 0; i < AJAZZ_KEY_SLOTS; i++) {
|
|
245
|
+
bindings.push({
|
|
246
|
+
type: reply[7 + i * 4],
|
|
247
|
+
code1: reply[8 + i * 4],
|
|
248
|
+
code2: reply[9 + i * 4],
|
|
249
|
+
code3: reply[10 + i * 4],
|
|
250
|
+
});
|
|
251
|
+
}
|
|
252
|
+
return bindings;
|
|
253
|
+
}
|
|
254
|
+
/**
|
|
255
|
+
* Plausibility gate for decoded key maps. The vendor panel treats a slot read
|
|
256
|
+
* back as type 0 or 0xff as a default-binding marker (it keeps its own
|
|
257
|
+
* default for that button), so markers are accepted per slot. Anything else
|
|
258
|
+
* outside the 16/32/33/48/112 catalog is rejected as a crossed or
|
|
259
|
+
* half-filled report.
|
|
260
|
+
*/
|
|
261
|
+
export function ajazzKeysLookPlausible(keys) {
|
|
262
|
+
return (keys.length === AJAZZ_KEY_SLOTS &&
|
|
263
|
+
keys.every((key) => key.type === 0 || key.type === 0xff || ajazzIsKnownKeyType(key.type)));
|
|
264
|
+
}
|
|
265
|
+
/**
|
|
266
|
+
* Substitute the factory defaults for default-binding markers (type 0/0xff),
|
|
267
|
+
* mirroring the vendor panel's merge of a freshly read map over its own
|
|
268
|
+
* defaults. Real bindings pass through untouched.
|
|
269
|
+
*/
|
|
270
|
+
export function ajazzApplyKeyDefaults(keys) {
|
|
271
|
+
return keys.map((key, index) => {
|
|
272
|
+
if ((key.type === 0 || key.type === 0xff) && index < AJAZZ_DEFAULT_KEYS.length) {
|
|
273
|
+
return { ...AJAZZ_DEFAULT_KEYS[index] };
|
|
274
|
+
}
|
|
275
|
+
return { ...key };
|
|
276
|
+
});
|
|
277
|
+
}
|
|
278
|
+
/**
|
|
279
|
+
* Encode a SET_KEYS request, mirroring vendor `setMouseKeys()`: head
|
|
280
|
+
* [0x09, 0x01, 0x22, 0x30], the six bindings at body[7..30], then the two
|
|
281
|
+
* fixed wheel entries at body[31..38].
|
|
282
|
+
*/
|
|
283
|
+
export function ajazzEncodeSetKeys(keys) {
|
|
284
|
+
const slots = [...keys].slice(0, AJAZZ_KEY_SLOTS);
|
|
285
|
+
while (slots.length < AJAZZ_KEY_SLOTS)
|
|
286
|
+
slots.push({ type: 32, code1: 0, code2: 0, code3: 0 });
|
|
287
|
+
const out = body(CMD.SET_KEYS, 0x01, 0x22, 0x30);
|
|
288
|
+
[...slots, ...AJAZZ_FIXED_WHEEL_KEYS].forEach((key, n) => {
|
|
289
|
+
out[7 + n * 4] = key.type & 0xff;
|
|
290
|
+
out[8 + n * 4] = key.code1 & 0xff;
|
|
291
|
+
out[9 + n * 4] = key.code2 & 0xff;
|
|
292
|
+
out[10 + n * 4] = key.code3 & 0xff;
|
|
293
|
+
});
|
|
294
|
+
return out;
|
|
295
|
+
}
|
|
296
|
+
/**
|
|
297
|
+
* Remappable actions from the vendor key catalog (display label + bytes).
|
|
298
|
+
* Keyboard usages use the type-16 encoding with a zero modifier byte; combos
|
|
299
|
+
* with modifiers still read back losslessly as opaque bindings. Macro slots
|
|
300
|
+
* (type 112) are intentionally absent: the panel keeps macros in localStorage
|
|
301
|
+
* and uploads them separately, so there is no fixed onboard slot count yet.
|
|
302
|
+
*/
|
|
303
|
+
export const AJAZZ_BUTTON_ACTIONS = [
|
|
304
|
+
{ label: "Escape", type: 16, code1: 0, code2: 41, code3: 0 },
|
|
305
|
+
{ label: "Tab", type: 16, code1: 0, code2: 43, code3: 0 },
|
|
306
|
+
{ label: "Caps Lock", type: 16, code1: 0, code2: 57, code3: 0 },
|
|
307
|
+
{ label: "Enter", type: 16, code1: 0, code2: 40, code3: 0 },
|
|
308
|
+
{ label: "Space", type: 16, code1: 0, code2: 44, code3: 0 },
|
|
309
|
+
{ label: "Backspace", type: 16, code1: 0, code2: 42, code3: 0 },
|
|
310
|
+
{ label: "Insert", type: 16, code1: 0, code2: 73, code3: 0 },
|
|
311
|
+
{ label: "Delete", type: 16, code1: 0, code2: 76, code3: 0 },
|
|
312
|
+
{ label: "Home", type: 16, code1: 0, code2: 74, code3: 0 },
|
|
313
|
+
{ label: "End", type: 16, code1: 0, code2: 77, code3: 0 },
|
|
314
|
+
{ label: "Page Up", type: 16, code1: 0, code2: 75, code3: 0 },
|
|
315
|
+
{ label: "Page Down", type: 16, code1: 0, code2: 78, code3: 0 },
|
|
316
|
+
{ label: "Left Arrow", type: 16, code1: 0, code2: 80, code3: 0 },
|
|
317
|
+
{ label: "Right Arrow", type: 16, code1: 0, code2: 79, code3: 0 },
|
|
318
|
+
{ label: "Up Arrow", type: 16, code1: 0, code2: 82, code3: 0 },
|
|
319
|
+
{ label: "Down Arrow", type: 16, code1: 0, code2: 81, code3: 0 },
|
|
320
|
+
{ label: "F1", type: 16, code1: 0, code2: 58, code3: 0 },
|
|
321
|
+
{ label: "F2", type: 16, code1: 0, code2: 59, code3: 0 },
|
|
322
|
+
{ label: "F3", type: 16, code1: 0, code2: 60, code3: 0 },
|
|
323
|
+
{ label: "F4", type: 16, code1: 0, code2: 61, code3: 0 },
|
|
324
|
+
{ label: "F5", type: 16, code1: 0, code2: 62, code3: 0 },
|
|
325
|
+
{ label: "F6", type: 16, code1: 0, code2: 63, code3: 0 },
|
|
326
|
+
{ label: "F7", type: 16, code1: 0, code2: 64, code3: 0 },
|
|
327
|
+
{ label: "F8", type: 16, code1: 0, code2: 65, code3: 0 },
|
|
328
|
+
{ label: "F9", type: 16, code1: 0, code2: 66, code3: 0 },
|
|
329
|
+
{ label: "F10", type: 16, code1: 0, code2: 67, code3: 0 },
|
|
330
|
+
{ label: "F11", type: 16, code1: 0, code2: 68, code3: 0 },
|
|
331
|
+
{ label: "F12", type: 16, code1: 0, code2: 69, code3: 0 },
|
|
332
|
+
{ label: "Left click", type: 32, code1: 1, code2: 0, code3: 0 },
|
|
333
|
+
{ label: "Right click", type: 32, code1: 2, code2: 0, code3: 0 },
|
|
334
|
+
{ label: "Middle click", type: 32, code1: 4, code2: 0, code3: 0 },
|
|
335
|
+
{ label: "Backward", type: 32, code1: 8, code2: 0, code3: 0 },
|
|
336
|
+
{ label: "Forward", type: 32, code1: 16, code2: 0, code3: 0 },
|
|
337
|
+
{ label: "Disabled", type: 32, code1: 0, code2: 0, code3: 0 },
|
|
338
|
+
{ label: "DPI loop", type: 33, code1: 85, code2: 0, code3: 0 },
|
|
339
|
+
{ label: "Scroll up", type: 33, code1: 56, code2: 1, code3: 0 },
|
|
340
|
+
{ label: "Scroll down", type: 33, code1: 56, code2: 255, code3: 0 },
|
|
341
|
+
{ label: "Volume +", type: 48, code1: 233, code2: 0, code3: 0 },
|
|
342
|
+
{ label: "Volume −", type: 48, code1: 234, code2: 0, code3: 0 },
|
|
343
|
+
{ label: "Mute", type: 48, code1: 226, code2: 0, code3: 0 },
|
|
344
|
+
{ label: "Play/Pause", type: 48, code1: 205, code2: 0, code3: 0 },
|
|
345
|
+
{ label: "Stop", type: 48, code1: 183, code2: 0, code3: 0 },
|
|
346
|
+
{ label: "Prev track", type: 48, code1: 182, code2: 0, code3: 0 },
|
|
347
|
+
{ label: "Next track", type: 48, code1: 181, code2: 0, code3: 0 },
|
|
348
|
+
{ label: "Multimedia", type: 48, code1: 131, code2: 1, code3: 0 },
|
|
349
|
+
{ label: "Homepage", type: 48, code1: 35, code2: 2, code3: 0 },
|
|
350
|
+
{ label: "Web refresh", type: 48, code1: 39, code2: 2, code3: 0 },
|
|
351
|
+
{ label: "Web stop", type: 48, code1: 38, code2: 2, code3: 0 },
|
|
352
|
+
{ label: "Web forward", type: 48, code1: 37, code2: 2, code3: 0 },
|
|
353
|
+
{ label: "Web backward", type: 48, code1: 36, code2: 2, code3: 0 },
|
|
354
|
+
{ label: "Web favorites", type: 48, code1: 42, code2: 2, code3: 0 },
|
|
355
|
+
{ label: "Web search", type: 48, code1: 33, code2: 2, code3: 0 },
|
|
356
|
+
{ label: "Calculator", type: 48, code1: 146, code2: 1, code3: 0 },
|
|
357
|
+
{ label: "My Computer", type: 48, code1: 148, code2: 1, code3: 0 },
|
|
358
|
+
{ label: "Mail", type: 48, code1: 138, code2: 1, code3: 0 },
|
|
359
|
+
];
|
|
360
|
+
/** Display label for a binding, or null when the catalog cannot name it. */
|
|
361
|
+
export function ajazzBindingLabel(binding) {
|
|
362
|
+
if (binding.type === AJAZZ_KEY_TYPE.macro && Number.isInteger(binding.code1) && binding.code1 >= 0) {
|
|
363
|
+
return `Macro ${binding.code1 + 1}`;
|
|
364
|
+
}
|
|
365
|
+
return AJAZZ_BUTTON_ACTIONS.find((action) => action.type === binding.type &&
|
|
366
|
+
action.code1 === binding.code1 &&
|
|
367
|
+
action.code2 === binding.code2 &&
|
|
368
|
+
action.code3 === binding.code3)?.label ?? null;
|
|
369
|
+
}
|
|
370
|
+
/** Catalog binding for a display label, or null for unknown labels. */
|
|
371
|
+
export function ajazzFindButtonAction(label) {
|
|
372
|
+
const action = AJAZZ_BUTTON_ACTIONS.find((entry) => entry.label === label);
|
|
373
|
+
return action ? { type: action.type, code1: action.code1, code2: action.code2, code3: action.code3 } : null;
|
|
374
|
+
}
|
|
175
375
|
//# sourceMappingURL=index.js.map
|
package/dist/ajazz/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/ajazz/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AAEH,MAAM,CAAC,MAAM,mBAAmB,GAAG,MAAM,CAAC;AAC1C,MAAM,CAAC,MAAM,sBAAsB,GAAG,MAAM,CAAC;AAC7C,MAAM,CAAC,MAAM,gBAAgB,GAAG,MAAM,CAAC;AACvC,MAAM,CAAC,MAAM,WAAW,GAAG,IAAI,CAAC;AAChC,MAAM,CAAC,MAAM,eAAe,GAAG,IAAI,CAAC;AACpC,MAAM,CAAC,MAAM,gBAAgB,GAAG,EAAE,CAAC;AAQnC;;;;;GAKG;AACH,MAAM,CAAC,MAAM,cAAc,GAAsC,IAAI,GAAG,CAAC;IACvE,CAAC,MAAM,EAAE,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,KAAK,EAAE,CAAC;IAC1C,CAAC,MAAM,EAAE,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,KAAK,EAAE,CAAC;IAC1C,CAAC,MAAM,EAAE,EAAE,KAAK,EAAE,SAAS,EAAE,MAAM,EAAE,KAAK,EAAE,CAAC;IAC7C,CAAC,MAAM,EAAE,EAAE,KAAK,EAAE,SAAS,EAAE,MAAM,EAAE,KAAK,EAAE,CAAC;IAC7C,CAAC,MAAM,EAAE,EAAE,KAAK,EAAE,aAAa,EAAE,MAAM,EAAE,KAAK,EAAE,CAAC;IACjD,CAAC,MAAM,EAAE,EAAE,KAAK,EAAE,aAAa,EAAE,MAAM,EAAE,KAAK,EAAE,CAAC;CAClD,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,aAAa,GAAG,EAAE,C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,KAAK,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC;AAC9G,CAAC"}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { MouseStatus } from "../mouse-types.ts";
|
|
2
|
+
import { type AjazzKeyBinding } from "../../ajazz/index.ts";
|
|
2
3
|
/** Rejected when a command gets no matching input report within the timeout. */
|
|
3
4
|
export declare class AjazzTimeoutError extends Error {
|
|
4
5
|
constructor();
|
|
@@ -15,9 +16,11 @@ export interface AjazzClientOptions {
|
|
|
15
16
|
* status reports unprompted, so replies are matched by command rather than by
|
|
16
17
|
* arrival order. A tiny queue serializes calls like the vendor panel does.
|
|
17
18
|
*
|
|
18
|
-
* Evidence: the vendor panel's JavaScript
|
|
19
|
-
*
|
|
20
|
-
*
|
|
19
|
+
* Evidence: the vendor panel's JavaScript, plus ticket-0156 hardware replies
|
|
20
|
+
* for config, battery and version (NJ07 MC, firmware 2.0.1) and a passing
|
|
21
|
+
* flash write round-trip. The key-map path follows the same panel JS and
|
|
22
|
+
* awaits a hardware confirmation, so every write still reads back and fails
|
|
23
|
+
* loudly when the mouse kept something else.
|
|
21
24
|
*/
|
|
22
25
|
export declare class AjazzHidClient {
|
|
23
26
|
readonly device: HIDDevice;
|
|
@@ -36,22 +39,61 @@ export declare class AjazzHidClient {
|
|
|
36
39
|
close(): Promise<void>;
|
|
37
40
|
/** Send one command and resolve with the input report that echoes it. */
|
|
38
41
|
private exchange;
|
|
39
|
-
/**
|
|
40
|
-
|
|
42
|
+
/**
|
|
43
|
+
* Fire-and-forget write, mirroring the vendor panel: `setMouseConfigData()`
|
|
44
|
+
* and `setMouseKeys()` never wait for an echo, they just queue the report.
|
|
45
|
+
* The read-back below is the check, so a mouse that answers SET slowly (or
|
|
46
|
+
* never) no longer stalls every setter for two full reply timeouts.
|
|
47
|
+
*/
|
|
48
|
+
private sendOnly;
|
|
41
49
|
private readConfig;
|
|
42
50
|
readStatus(): Promise<MouseStatus>;
|
|
43
51
|
/**
|
|
44
52
|
* SET_CONFIG rewrites the whole block, so every setter reads the current
|
|
45
|
-
* block, patches one field, writes it and reads it back. The
|
|
46
|
-
*
|
|
47
|
-
*
|
|
53
|
+
* block, patches one field, writes it and reads it back. The write itself
|
|
54
|
+
* is fire-and-forget like the vendor panel; the read-back is the check.
|
|
55
|
+
* Slow flash commits are retried for ~2 s before failing, so a mouse that
|
|
56
|
+
* applies the write late no longer reports a false "kept the old value".
|
|
48
57
|
*/
|
|
49
58
|
private updateConfig;
|
|
59
|
+
/** Poll the config until `kept` passes, the deadline elapses, or reads go
|
|
60
|
+
* silent three times running (a dead mouse answers nothing, so further
|
|
61
|
+
* attempts only burn reply timeouts). Slow flash commits still get the
|
|
62
|
+
* full window; silent mice fail fast. */
|
|
63
|
+
private readBackConfigMatching;
|
|
50
64
|
setDpiStageValue(stage: number, dpi: number): Promise<number>;
|
|
51
65
|
setDpi(dpi: number): Promise<number>;
|
|
52
66
|
setActiveDpiStage(stage: number): Promise<number>;
|
|
53
67
|
setPollingRate(rate: number): Promise<number>;
|
|
54
68
|
setSleepTimeout(seconds: number): Promise<number>;
|
|
55
69
|
setScrollDirection(direction: NonNullable<MouseStatus["scrollDirection"]>): Promise<NonNullable<MouseStatus["scrollDirection"]>>;
|
|
70
|
+
/**
|
|
71
|
+
* Read the six-button map; null when the mouse answers nothing plausible.
|
|
72
|
+
* Default-binding markers (type 0/0xff) come back as the factory defaults,
|
|
73
|
+
* mirroring the vendor panel's merge.
|
|
74
|
+
*/
|
|
75
|
+
getKeys(): Promise<AjazzKeyBinding[] | null>;
|
|
76
|
+
/**
|
|
77
|
+
* Read the map once without retries, for deadline-bounded write
|
|
78
|
+
* confirmation (retries there would multiply timeouts past the deadline).
|
|
79
|
+
*/
|
|
80
|
+
private getKeysOnce;
|
|
81
|
+
/**
|
|
82
|
+
* Write all six key slots (SET_KEYS). The two fixed wheel entries are
|
|
83
|
+
* always appended by the codec; opaque macro/combo slots are preserved
|
|
84
|
+
* rather than guessed or rebuilt. Confirms by reading the map back, with
|
|
85
|
+
* the same slow-flash tolerance as config writes.
|
|
86
|
+
*/
|
|
87
|
+
setKeys(keys: readonly AjazzKeyBinding[]): Promise<AjazzKeyBinding[]>;
|
|
88
|
+
/**
|
|
89
|
+
* Remap one button by display label (generic `setButtonMapping` interface).
|
|
90
|
+
* SET_KEYS always carries all six key slots, so the current map is
|
|
91
|
+
* re-read and the single slot replaced — confirmed by setKeys' read-back.
|
|
92
|
+
* Slot "Left" is locked: unbinding the primary button with no other
|
|
93
|
+
* recovery path would brick basic use.
|
|
94
|
+
*/
|
|
95
|
+
setButtonMapping(button: string, actionLabel: string): Promise<void>;
|
|
96
|
+
/** Restore the six factory bindings from every model's default profile. */
|
|
97
|
+
resetButtonMap(): Promise<void>;
|
|
56
98
|
}
|
|
57
99
|
//# sourceMappingURL=hid.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"hid.d.ts","sourceRoot":"","sources":["../../../src/drivers/ajazz/hid.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;
|
|
1
|
+
{"version":3,"file":"hid.d.ts","sourceRoot":"","sources":["../../../src/drivers/ajazz/hid.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AACrD,OAAO,EAkCL,KAAK,eAAe,EACrB,MAAM,sBAAsB,CAAC;AAU9B,gFAAgF;AAChF,qBAAa,iBAAkB,SAAQ,KAAK;;CAK3C;AAED,MAAM,WAAW,kBAAkB;IACjC,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,kBAAkB,CAAC,EAAE,MAAM,CAAC;CAC7B;AAUD;;;;;;;;;;;;;GAaG;AACH,qBAAa,cAAc;IACzB,QAAQ,CAAC,MAAM,EAAE,SAAS,CAAC;IAC3B,OAAO,CAAC,KAAK,CAAuC;IACpD,OAAO,CAAC,QAAQ,CAAC,cAAc,CAAS;IACxC,OAAO,CAAC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