@potatosalad775/eqcaps-device-bridge 0.4.1 → 0.4.3
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 +32 -4
- package/dist/device.d.ts +14 -6
- package/dist/device.d.ts.map +1 -1
- package/dist/device.js +40 -18
- package/dist/device.js.map +1 -1
- package/dist/handler.d.ts +25 -1
- package/dist/handler.d.ts.map +1 -1
- package/dist/handler.js.map +1 -1
- package/dist/handlers/index.d.ts +3 -1
- package/dist/handlers/index.d.ts.map +1 -1
- package/dist/handlers/index.js +4 -0
- package/dist/handlers/index.js.map +1 -1
- package/dist/handlers/ktmicro-usb-hid.d.ts +16 -2
- package/dist/handlers/ktmicro-usb-hid.d.ts.map +1 -1
- package/dist/handlers/ktmicro-usb-hid.js +41 -14
- package/dist/handlers/ktmicro-usb-hid.js.map +1 -1
- package/dist/handlers/qudelix-usb-hid.d.ts +20 -13
- package/dist/handlers/qudelix-usb-hid.d.ts.map +1 -1
- package/dist/handlers/qudelix-usb-hid.js +219 -87
- package/dist/handlers/qudelix-usb-hid.js.map +1 -1
- package/dist/handlers/qudelix-v2-usb-hid.d.ts +31 -0
- package/dist/handlers/qudelix-v2-usb-hid.d.ts.map +1 -0
- package/dist/handlers/qudelix-v2-usb-hid.js +266 -0
- package/dist/handlers/qudelix-v2-usb-hid.js.map +1 -0
- package/dist/handlers/qudelix.d.ts +185 -0
- package/dist/handlers/qudelix.d.ts.map +1 -0
- package/dist/handlers/qudelix.js +585 -0
- package/dist/handlers/qudelix.js.map +1 -0
- package/dist/handlers/topping-usb-hid.d.ts +51 -0
- package/dist/handlers/topping-usb-hid.d.ts.map +1 -0
- package/dist/handlers/topping-usb-hid.js +658 -0
- package/dist/handlers/topping-usb-hid.js.map +1 -0
- package/dist/index.d.ts +2 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js.map +1 -1
- package/dist/protocols.d.ts +9 -0
- package/dist/protocols.d.ts.map +1 -1
- package/dist/protocols.js +85 -34
- package/dist/protocols.js.map +1 -1
- package/package.json +2 -2
|
@@ -0,0 +1,266 @@
|
|
|
1
|
+
// Qudelix 5K Plus over USB HID, as Qudelix's app for Chrome (version 4.0.3.1) drives it: the
|
|
2
|
+
// second protocol, messages of elements sent in acknowledged fragments. The framing, the session
|
|
3
|
+
// and the stored-preset layout are in `qudelix.ts`. Fields are packed least significant bit first,
|
|
4
|
+
// so the multi-byte ones are little-endian.
|
|
5
|
+
//
|
|
6
|
+
// EQ elements of a group, at 0x90 (the user EQ), 0xA0 (the speaker EQ) or 0xB0 (the all-band EQ of
|
|
7
|
+
// single-EQ mode), plus:
|
|
8
|
+
// +0 configuration [version:4, on:1, 11 spare bits, headroom s8, preset index u8]
|
|
9
|
+
// +2 preset attributes: the first 12 bytes of the stored preset, the type bit (1 parametric) first
|
|
10
|
+
// +3 the stored preset
|
|
11
|
+
// +4 preset name [group, custom n, length, 0, UTF-8…]
|
|
12
|
+
// +5 one band [mask:4, type:4, band u8, freq u16, gain s16 ×10, q u16 ×1024]
|
|
13
|
+
// 0x80 is the EQ mode [version:4, mode:4 (0 layered, 1 single-EQ)]; 3 the firmware version
|
|
14
|
+
// [major, minor, revision, …]. A change is a set (0x9004) of one element; the action (0x9006)
|
|
15
|
+
// element 0x30 [group, custom n, 0, 0] saves the working EQ to a custom preset. A request (0x9002)
|
|
16
|
+
// [id, 0]… is answered (0x9003) by those elements. The opening answer and the notifications
|
|
17
|
+
// (0x9005) carry the configurations; a request asks for one only where the session has none.
|
|
18
|
+
//
|
|
19
|
+
// The app turns an EQ on by setting its whole configuration, makes it parametric by setting the
|
|
20
|
+
// attributes, and changes its pre-gain by setting the whole stored preset. So a push takes the
|
|
21
|
+
// configuration, requests the preset, and sends: the configuration with the switch on; the
|
|
22
|
+
// attributes with the type parametric (not on the speaker EQ, which is parametric only); for a
|
|
23
|
+
// pre-gain, the preset with it on every channel; one band element per band; for a slot, the name
|
|
24
|
+
// (empty: the default "Custom #n") and the save. The codec takes the configuration and the preset
|
|
25
|
+
// as options, so the frames it gives are the frames a push sends.
|
|
26
|
+
import { field, I16, readU16be, U16, U8 } from "../bytes.js";
|
|
27
|
+
import { BridgeError } from "../errors.js";
|
|
28
|
+
import { decimals, sendFrame } from "../io.js";
|
|
29
|
+
import { ACK, ACTION, channelMasks, CUSTOM, customOf, EDITED, elementBytes, elementsOf, filterOf, FIVE_K_PLUS, groupOf, hidOut, modelFor, packet, PARAMETRIC, presetSize, pullResult, QUDELIX_MODELS, QUDELIX_TYPES, QUDELIX_WIRE, qudelixSession, readPreset, Reassembly, REQ, sentPacket, SET, struct, withFields, writeBits, dropSession } from "./qudelix.js";
|
|
30
|
+
const MODEL = QUDELIX_MODELS[FIVE_K_PLUS];
|
|
31
|
+
/** What the codec assumes without a device: the 5K Plus's report 8 of 127 bytes. */
|
|
32
|
+
const OFFLINE_LINK_V2 = { vendorId: 0x0a12, reportId: 8, reportSize: 127 };
|
|
33
|
+
/** Each group's first element, by group id. */
|
|
34
|
+
const BASE = [0x90, 0xa0, 0xb0];
|
|
35
|
+
const CONFIG = 0;
|
|
36
|
+
const ATTRIBUTES = 2;
|
|
37
|
+
const PRESET = 3;
|
|
38
|
+
const NAME = 4;
|
|
39
|
+
const BAND = 5;
|
|
40
|
+
const EQ_MODE = 0x80;
|
|
41
|
+
const FIRMWARE = 3;
|
|
42
|
+
const SAVE = 0x30;
|
|
43
|
+
const SINGLE = 1;
|
|
44
|
+
const MODE = struct(['version', 4], ['mode', 4], ['', 24]);
|
|
45
|
+
const BAND_ELEMENT = struct(['mask', 4], ['filter', 4], ['band', 8], ['freq', 16], ['gain', 16, 'signed'], ['q', 16]);
|
|
46
|
+
const SMALLEST_PACKET = 40;
|
|
47
|
+
const TIMEOUT = 2000;
|
|
48
|
+
const ACK_TIMEOUT = 1000;
|
|
49
|
+
const ACK_OK = 0;
|
|
50
|
+
/** A message as packets [command, header, slice]: `packetSize - 1` bytes of it in each. */
|
|
51
|
+
export function fragmentsOf(command, message, packetSize) {
|
|
52
|
+
const out = [];
|
|
53
|
+
let at = 0;
|
|
54
|
+
for (let id = 0; id === 0 || at < message.length; id++) {
|
|
55
|
+
const slice = message.slice(at, at + packetSize - 1);
|
|
56
|
+
at += slice.length;
|
|
57
|
+
out.push(packet(command, [(id & 0x1f) | (at >= message.length ? 0x80 : 0), ...slice]));
|
|
58
|
+
}
|
|
59
|
+
return out;
|
|
60
|
+
}
|
|
61
|
+
function target(o) {
|
|
62
|
+
const single = o.device?.single ?? false;
|
|
63
|
+
const group = groupOf(MODEL, o.group ?? 'usr', single);
|
|
64
|
+
const device = o.device ?? {
|
|
65
|
+
link: OFFLINE_LINK_V2,
|
|
66
|
+
packetSize: SMALLEST_PACKET,
|
|
67
|
+
single,
|
|
68
|
+
config: new Uint8Array(4),
|
|
69
|
+
preset: new Uint8Array(presetSize(MODEL, group, group.channels[0]))
|
|
70
|
+
};
|
|
71
|
+
return { device, group, base: BASE[group.id] };
|
|
72
|
+
}
|
|
73
|
+
export const qudelixV2UsbHidCodec = {
|
|
74
|
+
types: QUDELIX_TYPES.types,
|
|
75
|
+
wire: () => QUDELIX_WIRE,
|
|
76
|
+
encode({ filters, preamp, slot }, o) {
|
|
77
|
+
const { device, group, base } = target(o);
|
|
78
|
+
if (filters.length > group.bands) {
|
|
79
|
+
throw new BridgeError('invalid-request', `Qudelix: the ${group.name} has ${group.bands} bands, not ${filters.length}`);
|
|
80
|
+
}
|
|
81
|
+
const channels = group.channels[0];
|
|
82
|
+
const messages = [];
|
|
83
|
+
const set = (id, data) => messages.push([SET, elementBytes(id, data)]);
|
|
84
|
+
set(base + CONFIG, withFields(device.config, MODEL.groupConfig, { enable: 1 }));
|
|
85
|
+
// The app's copy of the preset has the parametric type once it sets it.
|
|
86
|
+
const preset = withFields(device.preset, MODEL.preset.head, { type: PARAMETRIC });
|
|
87
|
+
if (group.graphic)
|
|
88
|
+
set(base + ATTRIBUTES, preset.subarray(0, MODEL.preset.head.bits / 8));
|
|
89
|
+
if (preamp !== undefined) {
|
|
90
|
+
const value = field(preamp, 10, I16, 'preamp');
|
|
91
|
+
for (let ch = 0; ch < channels; ch++) {
|
|
92
|
+
writeBits(preset, MODEL.preset.head.bits + 16 * ch, 16, value);
|
|
93
|
+
}
|
|
94
|
+
set(base + PRESET, preset);
|
|
95
|
+
}
|
|
96
|
+
// Bands past the request keep what the device holds (D33).
|
|
97
|
+
filters.forEach((f, band) => {
|
|
98
|
+
const values = {
|
|
99
|
+
filter: QUDELIX_TYPES.encode(f.type),
|
|
100
|
+
band,
|
|
101
|
+
freq: field(f.freq, 1, U16, 'freq'),
|
|
102
|
+
gain: field(f.gain, 10, I16, 'gain'),
|
|
103
|
+
q: field(f.q, 1024, U16, 'q')
|
|
104
|
+
};
|
|
105
|
+
for (const mask of channelMasks(group, channels)) {
|
|
106
|
+
const bytes = new Uint8Array(BAND_ELEMENT.bits / 8);
|
|
107
|
+
BAND_ELEMENT.write(bytes, { ...values, mask });
|
|
108
|
+
set(base + BAND, bytes);
|
|
109
|
+
}
|
|
110
|
+
});
|
|
111
|
+
if (slot !== undefined) {
|
|
112
|
+
const n = customOf(group, slot);
|
|
113
|
+
set(base + NAME, [group.id, n, 0, 0]);
|
|
114
|
+
messages.push([ACTION, elementBytes(SAVE, [group.id, n, 0, 0])]);
|
|
115
|
+
}
|
|
116
|
+
return messages.flatMap(([command, message]) => fragmentsOf(command, message, device.packetSize).map((p) => hidOut(device.link, p)));
|
|
117
|
+
},
|
|
118
|
+
decode(frames, o) {
|
|
119
|
+
const { device, group, base } = target(o);
|
|
120
|
+
const state = { filters: [] };
|
|
121
|
+
const reassembly = new Reassembly();
|
|
122
|
+
for (const frame of frames) {
|
|
123
|
+
const p = sentPacket(device.link, frame);
|
|
124
|
+
const command = readU16be(p, 0);
|
|
125
|
+
const message = reassembly.push(command, p.subarray(2));
|
|
126
|
+
for (const e of (message && elementsOf(message)) ?? []) {
|
|
127
|
+
if (command === ACTION && e.id === SAVE)
|
|
128
|
+
state.slot = CUSTOM + e.data[1];
|
|
129
|
+
if (command !== SET)
|
|
130
|
+
continue;
|
|
131
|
+
if (e.id === base + BAND) {
|
|
132
|
+
const b = BAND_ELEMENT.read(e.data);
|
|
133
|
+
state.filters[b.band] = filterOf(b);
|
|
134
|
+
}
|
|
135
|
+
else if (e.id === base + PRESET) {
|
|
136
|
+
state.preamp = decimals(readPreset(MODEL, group, e.data)[0].preGain / 10, 1);
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
return state;
|
|
141
|
+
}
|
|
142
|
+
};
|
|
143
|
+
/** The EQ an operation names (`spk`), or the user EQ. */
|
|
144
|
+
const groupName = (ctx) => (ctx.eq === 'spk' ? 'spk' : 'usr');
|
|
145
|
+
/**
|
|
146
|
+
* Sends fragments, each but the last of a message answered by its ack within 1 s. A missing or
|
|
147
|
+
* bad ack, or a failed send, ends the session, as the app reconnects then.
|
|
148
|
+
*/
|
|
149
|
+
async function sendFragments(s, frames) {
|
|
150
|
+
try {
|
|
151
|
+
for (const frame of frames) {
|
|
152
|
+
const header = sentPacket(s.link, frame)[2];
|
|
153
|
+
const id = header & 0x1f;
|
|
154
|
+
if (header & 0x80) {
|
|
155
|
+
await sendFrame(s.transport, frame);
|
|
156
|
+
continue;
|
|
157
|
+
}
|
|
158
|
+
const ack = s.expect((m) => m.command === ACK && m.payload.length === 2, ACK_TIMEOUT, `fragment ${id}`);
|
|
159
|
+
ack.catch(() => { });
|
|
160
|
+
await sendFrame(s.transport, frame);
|
|
161
|
+
const [acked, result] = (await ack).payload;
|
|
162
|
+
if (acked !== id || result !== ACK_OK) {
|
|
163
|
+
throw new BridgeError('rejected', `Qudelix 5K Plus: fragment ${id} got an ack of fragment ${acked} with result ${result}`);
|
|
164
|
+
}
|
|
165
|
+
}
|
|
166
|
+
}
|
|
167
|
+
catch (error) {
|
|
168
|
+
dropSession(s);
|
|
169
|
+
throw error;
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
const send = (s, command, message) => sendFragments(s, fragmentsOf(command, message, s.device.packetSize).map((p) => hidOut(s.link, p)));
|
|
173
|
+
/** Requests elements afresh: [id, 0] each, answered by the elements. */
|
|
174
|
+
async function request(s, ids) {
|
|
175
|
+
for (const id of ids)
|
|
176
|
+
s.elements.delete(id);
|
|
177
|
+
const answered = s.expect(() => ids.every((id) => s.elements.has(id)), TIMEOUT, `the request for elements ${ids.map((id) => `0x${id.toString(16)}`).join(', ')}`);
|
|
178
|
+
answered.catch(() => { });
|
|
179
|
+
await send(s, REQ, ids.flatMap((id) => [id, 0]));
|
|
180
|
+
await answered;
|
|
181
|
+
}
|
|
182
|
+
/** Elements as the session holds them, requested where it has none. */
|
|
183
|
+
async function elements(s, ids) {
|
|
184
|
+
const missing = ids.filter((id) => !s.elements.has(id));
|
|
185
|
+
if (missing.length)
|
|
186
|
+
await request(s, missing);
|
|
187
|
+
return ids.map((id) => s.elements.get(id));
|
|
188
|
+
}
|
|
189
|
+
/** The 5K Plus's session, the EQ the options name in its mode, and that EQ's configuration. */
|
|
190
|
+
async function drive(ctx) {
|
|
191
|
+
const s = await qudelixSession(ctx);
|
|
192
|
+
modelFor(s, 2);
|
|
193
|
+
const [mode] = await elements(s, [EQ_MODE]);
|
|
194
|
+
const single = MODE.read(mode).mode === SINGLE;
|
|
195
|
+
const group = groupOf(MODEL, groupName(ctx), single);
|
|
196
|
+
const base = BASE[group.id];
|
|
197
|
+
const [config] = await elements(s, [base + CONFIG]);
|
|
198
|
+
return { s, group, single, base, config: config };
|
|
199
|
+
}
|
|
200
|
+
/** The group's stored preset, requested afresh. */
|
|
201
|
+
async function storedPreset(s, group, base) {
|
|
202
|
+
await request(s, [base + PRESET]);
|
|
203
|
+
const bytes = s.elements.get(base + PRESET);
|
|
204
|
+
return { bytes, preset: readPreset(MODEL, group, bytes) };
|
|
205
|
+
}
|
|
206
|
+
export const qudelixV2UsbHid = {
|
|
207
|
+
id: 'qudelix-v2-usb-hid',
|
|
208
|
+
transport: 'hid',
|
|
209
|
+
eqs: ['spk'],
|
|
210
|
+
codec: qudelixV2UsbHidCodec,
|
|
211
|
+
capabilities: () => ({
|
|
212
|
+
canRead: true,
|
|
213
|
+
canWrite: true,
|
|
214
|
+
readsPreamp: true,
|
|
215
|
+
readsSlot: false,
|
|
216
|
+
writesPreamp: true,
|
|
217
|
+
writesSlot: true,
|
|
218
|
+
needsBandCount: false,
|
|
219
|
+
readsCurrentSlot: true,
|
|
220
|
+
canEnable: true
|
|
221
|
+
}),
|
|
222
|
+
async pull(ctx) {
|
|
223
|
+
const { s, group, base, config } = await drive(ctx);
|
|
224
|
+
const { preset } = await storedPreset(s, group, base);
|
|
225
|
+
return pullResult(ctx.log, MODEL, group, preset, MODEL.groupConfig.read(config).preset);
|
|
226
|
+
},
|
|
227
|
+
async push(ctx, request) {
|
|
228
|
+
const { s, group, single, base, config } = await drive(ctx);
|
|
229
|
+
const { bytes } = await storedPreset(s, group, base);
|
|
230
|
+
const frames = qudelixV2UsbHidCodec.encode(request, {
|
|
231
|
+
group: groupName(ctx),
|
|
232
|
+
device: { link: s.link, packetSize: s.device.packetSize, single, config, preset: bytes }
|
|
233
|
+
});
|
|
234
|
+
await sendFragments(s, frames);
|
|
235
|
+
// The app's copy after a push: on, and on the saved preset or an edited EQ.
|
|
236
|
+
s.elements.set(base + CONFIG, withFields(config, MODEL.groupConfig, { enable: 1, preset: request.slot ?? EDITED }));
|
|
237
|
+
return { reconnect: false };
|
|
238
|
+
},
|
|
239
|
+
async setEnabled(ctx, enabled, slot) {
|
|
240
|
+
const { s, base, config } = await drive(ctx);
|
|
241
|
+
const next = withFields(config, MODEL.groupConfig, {
|
|
242
|
+
enable: enabled ? 1 : 0,
|
|
243
|
+
...(enabled && slot !== undefined ? { preset: field(slot, 1, U8, 'slot') } : {})
|
|
244
|
+
});
|
|
245
|
+
await send(s, SET, elementBytes(base + CONFIG, next));
|
|
246
|
+
s.elements.set(base + CONFIG, next);
|
|
247
|
+
},
|
|
248
|
+
async eqEnabled(ctx) {
|
|
249
|
+
const { config } = await drive(ctx);
|
|
250
|
+
return MODEL.groupConfig.read(config).enable === 1;
|
|
251
|
+
},
|
|
252
|
+
async currentSlot(ctx) {
|
|
253
|
+
const { preset } = MODEL.groupConfig.read((await drive(ctx)).config);
|
|
254
|
+
return preset === EDITED ? null : preset;
|
|
255
|
+
},
|
|
256
|
+
async firmware(ctx) {
|
|
257
|
+
const s = await qudelixSession(ctx);
|
|
258
|
+
modelFor(s, 2);
|
|
259
|
+
const [version] = await elements(s, [FIRMWARE]);
|
|
260
|
+
return Array.from(version.subarray(0, 3)).join('.');
|
|
261
|
+
},
|
|
262
|
+
async bandCount(ctx) {
|
|
263
|
+
return (await drive(ctx)).group.bands;
|
|
264
|
+
}
|
|
265
|
+
};
|
|
266
|
+
//# sourceMappingURL=qudelix-v2-usb-hid.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"qudelix-v2-usb-hid.js","sourceRoot":"","sources":["../../src/handlers/qudelix-v2-usb-hid.ts"],"names":[],"mappings":"AAAA,6FAA6F;AAC7F,iGAAiG;AACjG,mGAAmG;AACnG,4CAA4C;AAC5C,EAAE;AACF,mGAAmG;AACnG,yBAAyB;AACzB,oFAAoF;AACpF,qGAAqG;AACrG,yBAAyB;AACzB,wDAAwD;AACxD,+EAA+E;AAC/E,2FAA2F;AAC3F,8FAA8F;AAC9F,mGAAmG;AACnG,4FAA4F;AAC5F,6FAA6F;AAC7F,EAAE;AACF,gGAAgG;AAChG,+FAA+F;AAC/F,2FAA2F;AAC3F,+FAA+F;AAC/F,iGAAiG;AACjG,kGAAkG;AAClG,kEAAkE;AAElE,OAAO,EAAE,KAAK,EAAE,GAAG,EAAE,SAAS,EAAE,GAAG,EAAE,EAAE,EAAE,MAAM,aAAa,CAAC;AAC7D,OAAO,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAE3C,OAAO,EAAE,QAAQ,EAAE,SAAS,EAAE,MAAM,UAAU,CAAC;AAE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AAC"}
|
|
@@ -0,0 +1,185 @@
|
|
|
1
|
+
import type { Filter } from '@potatosalad775/eqcaps-core';
|
|
2
|
+
import type { HandlerContext, HidFrame, PullResult, WireGrid } from '../handler.ts';
|
|
3
|
+
import type { HidTransport } from '../transport.ts';
|
|
4
|
+
/** Where a device's packets go: its vendor id (which names the framing) and output report. */
|
|
5
|
+
export interface QudelixLink {
|
|
6
|
+
vendorId: number;
|
|
7
|
+
reportId: number;
|
|
8
|
+
/** The output report's size, report id excluded. */
|
|
9
|
+
reportSize: number;
|
|
10
|
+
}
|
|
11
|
+
/** What a codec assumes without a device: a 0x0a12 device's report 8, 63 bytes on a 5K. */
|
|
12
|
+
export declare const OFFLINE_LINK: QudelixLink;
|
|
13
|
+
/** The transport's link. The audio interface, which has no vendor collection, is refused. */
|
|
14
|
+
export declare function linkOf(t: HidTransport): QudelixLink;
|
|
15
|
+
/** `packet` as an output report of `link`, zero-padded to its size. */
|
|
16
|
+
export declare function hidOut(link: QudelixLink, packet: readonly number[]): HidFrame;
|
|
17
|
+
/** The packet an output report of `link` carries. */
|
|
18
|
+
export declare const sentPacket: (link: QudelixLink, frame: HidFrame) => Uint8Array;
|
|
19
|
+
/** A packet: the command, big-endian, and its data. */
|
|
20
|
+
export declare const packet: (command: number, data?: readonly number[]) => number[];
|
|
21
|
+
/** A packed field: its name ('' for padding), width in bits, and whether it is two's complement. */
|
|
22
|
+
type Field<K extends string> = readonly [name: K, bits: number, signed?: 'signed'];
|
|
23
|
+
export declare function readBits(bytes: ArrayLike<number>, at: number, width: number, signed?: boolean): number;
|
|
24
|
+
export declare function writeBits(bytes: Uint8Array, at: number, width: number, value: number): void;
|
|
25
|
+
/** Fields packed one after another, least significant bit first; `at` is a bit offset. */
|
|
26
|
+
export interface Struct<K extends string = string> {
|
|
27
|
+
readonly bits: number;
|
|
28
|
+
has(name: string): boolean;
|
|
29
|
+
read(bytes: ArrayLike<number>, at?: number): Record<K, number>;
|
|
30
|
+
/** Writes the fields named in `values`, leaving the others as they are. */
|
|
31
|
+
write(bytes: Uint8Array, values: Partial<Record<K, number>>, at?: number): void;
|
|
32
|
+
}
|
|
33
|
+
export declare function struct<const K extends string>(...fields: readonly Field<K>[]): Struct<Exclude<K, ''>>;
|
|
34
|
+
/** A copy of `bytes` with some fields of `layout` changed. */
|
|
35
|
+
export declare function withFields<K extends string>(bytes: Uint8Array, layout: Struct<K>, values: Partial<Record<K, number>>): Uint8Array;
|
|
36
|
+
/** The EQ a profile drives: the user EQ or the speaker (headphone) EQ. */
|
|
37
|
+
export type QudelixGroupName = 'usr' | 'spk';
|
|
38
|
+
export interface QudelixGroup {
|
|
39
|
+
/** The group byte: 0 the user EQ, 1 the speaker EQ, 2 the all-band EQ of single-EQ mode. */
|
|
40
|
+
id: 0 | 1 | 2;
|
|
41
|
+
name: string;
|
|
42
|
+
bands: number;
|
|
43
|
+
/** The channel counts the bridge drives. Where there are several, the stored preset says. */
|
|
44
|
+
channels: readonly number[];
|
|
45
|
+
/**
|
|
46
|
+
* Left and right are written together, one frame with both bits, as the app sends them when its
|
|
47
|
+
* channel selector is on both; else each channel gets its own frame.
|
|
48
|
+
*/
|
|
49
|
+
stereo: boolean;
|
|
50
|
+
/** It may be a graphic EQ (the app's type selector), so a push makes it parametric. */
|
|
51
|
+
graphic: boolean;
|
|
52
|
+
/** Custom presets, from index 22. */
|
|
53
|
+
customs: number;
|
|
54
|
+
/** u16 frequencies stored ahead of the band records; 0 where each record holds its own. */
|
|
55
|
+
freqs: number;
|
|
56
|
+
}
|
|
57
|
+
/** A stored preset: the fields ahead of the pre-gains, the s16 pre-gains, one record per band. */
|
|
58
|
+
export interface PresetLayout {
|
|
59
|
+
/** The T71's says its channel and band counts (`channels`, `bands`). */
|
|
60
|
+
head: Struct;
|
|
61
|
+
preGains: number;
|
|
62
|
+
/** Per channel, then band; holds `freq` where the group stores no frequencies apart. */
|
|
63
|
+
band: Struct;
|
|
64
|
+
}
|
|
65
|
+
export interface QudelixModel {
|
|
66
|
+
name: string;
|
|
67
|
+
protocol: 1 | 2;
|
|
68
|
+
usr: QudelixGroup;
|
|
69
|
+
spk: QudelixGroup;
|
|
70
|
+
/** The one EQ of single-EQ mode, on a model that has the mode. */
|
|
71
|
+
all?: QudelixGroup;
|
|
72
|
+
preset: PresetLayout;
|
|
73
|
+
/** A group's configuration: its switch, headroom and current preset. */
|
|
74
|
+
groupConfig: Struct<'enable' | 'preset'>;
|
|
75
|
+
}
|
|
76
|
+
export declare const FIVE_K = 1;
|
|
77
|
+
export declare const FIVE_K_PLUS = 2;
|
|
78
|
+
export declare const T71 = 256;
|
|
79
|
+
/** By device id. */
|
|
80
|
+
export declare const QUDELIX_MODELS: Readonly<Record<number, QudelixModel>>;
|
|
81
|
+
/**
|
|
82
|
+
* The EQ `name` drives in the device's mode: the user EQ is the all-band EQ in single-EQ mode,
|
|
83
|
+
* which has no speaker EQ.
|
|
84
|
+
*/
|
|
85
|
+
export declare function groupOf(model: QudelixModel, name: QudelixGroupName, single: boolean): QudelixGroup;
|
|
86
|
+
/** The channel masks a write goes out on: each channel alone, or left and right together. */
|
|
87
|
+
export declare function channelMasks(group: QudelixGroup, channels: number): number[];
|
|
88
|
+
export declare const CUSTOM = 22;
|
|
89
|
+
export declare const EDITED = 255;
|
|
90
|
+
export declare const PARAMETRIC = 1;
|
|
91
|
+
/** Which custom preset, from 0, the preset index `slot` is; a built-in or one past the group's is refused. */
|
|
92
|
+
export declare function customOf(group: QudelixGroup, slot: number): number;
|
|
93
|
+
/** Filter codes. 0 is a band switched off (bypass), which reads as no filter. */
|
|
94
|
+
export declare const QUDELIX_TYPES: import("../io.ts").TypeCodes;
|
|
95
|
+
/** The band write's fields: freq u16 Hz, gain s16 ×10, q u16 ×1024; pre-gain s16 ×10. */
|
|
96
|
+
export declare const QUDELIX_WIRE: WireGrid;
|
|
97
|
+
export interface RawBand {
|
|
98
|
+
filter: number;
|
|
99
|
+
freq: number;
|
|
100
|
+
/** ×10 */
|
|
101
|
+
gain: number;
|
|
102
|
+
/** ×1024 */
|
|
103
|
+
q: number;
|
|
104
|
+
}
|
|
105
|
+
export declare function filterOf(b: RawBand): Filter | null;
|
|
106
|
+
/** A stored preset, per channel: the pre-gain (×10) and the bands. */
|
|
107
|
+
export type StoredPreset = {
|
|
108
|
+
preGain: number;
|
|
109
|
+
bands: RawBand[];
|
|
110
|
+
}[];
|
|
111
|
+
export declare function presetSize(model: QudelixModel, group: QudelixGroup, channels: number): number;
|
|
112
|
+
/** Decodes a stored preset of `group`. A channel count the bridge doesn't drive is `unsupported`. */
|
|
113
|
+
export declare function readPreset(model: QudelixModel, group: QudelixGroup, bytes: Uint8Array): StoredPreset;
|
|
114
|
+
/**
|
|
115
|
+
* What a pull returns: the first channel (the left one of a speaker EQ). Another channel that
|
|
116
|
+
* differs from it is reported through `log`, since a profile has one set of filters.
|
|
117
|
+
*/
|
|
118
|
+
export declare function pullResult(log: (message: string) => void, model: QudelixModel, group: QudelixGroup, preset: StoredPreset, index: number): PullResult;
|
|
119
|
+
export declare const INIT_RSP = 36864;
|
|
120
|
+
export declare const ACK = 36865;
|
|
121
|
+
export declare const REQ = 36866;
|
|
122
|
+
export declare const RSP = 36867;
|
|
123
|
+
export declare const SET = 36868;
|
|
124
|
+
export declare const NOTI = 36869;
|
|
125
|
+
export declare const ACTION = 36870;
|
|
126
|
+
export interface Element {
|
|
127
|
+
id: number;
|
|
128
|
+
data: Uint8Array;
|
|
129
|
+
}
|
|
130
|
+
/** The elements of a message; null when one runs past its end. */
|
|
131
|
+
export declare function elementsOf(payload: Uint8Array): Element[] | null;
|
|
132
|
+
/** One element's bytes, its data zero-padded to whole words. */
|
|
133
|
+
export declare function elementBytes(id: number, data: ArrayLike<number>): number[];
|
|
134
|
+
/**
|
|
135
|
+
* Second-protocol packets back into messages, as the app reassembles them: one message at a time,
|
|
136
|
+
* and a fragment out of order, repeated or of another command drops it.
|
|
137
|
+
*/
|
|
138
|
+
export declare class Reassembly {
|
|
139
|
+
#private;
|
|
140
|
+
/** One packet's [header, slice…]; the message once its fragments are all in. */
|
|
141
|
+
push(command: number, body: Uint8Array): Uint8Array | undefined;
|
|
142
|
+
}
|
|
143
|
+
export interface QudelixMessage {
|
|
144
|
+
command: number;
|
|
145
|
+
payload: Uint8Array;
|
|
146
|
+
}
|
|
147
|
+
export interface QudelixDevice {
|
|
148
|
+
id: number;
|
|
149
|
+
model: QudelixModel | undefined;
|
|
150
|
+
/** [major, minor, revision], from the first protocol's opening answer. */
|
|
151
|
+
firmware: [number, number, number] | null;
|
|
152
|
+
/** The second protocol's packet size, 40 to 120. */
|
|
153
|
+
packetSize: number;
|
|
154
|
+
}
|
|
155
|
+
/** A transport's open session: one input listener, which reassembles and dispatches messages. */
|
|
156
|
+
export declare class QudelixSession {
|
|
157
|
+
#private;
|
|
158
|
+
readonly transport: HidTransport;
|
|
159
|
+
readonly link: QudelixLink;
|
|
160
|
+
device: QudelixDevice;
|
|
161
|
+
/** The second protocol's elements, latest first: the opening answer, answers, notifications. */
|
|
162
|
+
readonly elements: Map<number, Uint8Array<ArrayBufferLike>>;
|
|
163
|
+
constructor(transport: HidTransport, link: QudelixLink);
|
|
164
|
+
/** Waits until 20 ms pass without input, as the app does before it opens a device. */
|
|
165
|
+
drain(sleep: (ms: number) => Promise<void>): Promise<void>;
|
|
166
|
+
/** The device the opening answer describes. */
|
|
167
|
+
opened(m: QudelixMessage): void;
|
|
168
|
+
/** The first message `match` accepts within `timeoutMs`. Call it before sending the request. */
|
|
169
|
+
expect(match: (m: QudelixMessage) => boolean, timeoutMs: number, what: string): Promise<QudelixMessage>;
|
|
170
|
+
/** Sends `packet` and waits for the answer `match` accepts. */
|
|
171
|
+
ask(data: readonly number[], match: (m: QudelixMessage) => boolean, timeoutMs: number, what: string): Promise<QudelixMessage>;
|
|
172
|
+
send(data: readonly number[]): Promise<void>;
|
|
173
|
+
close(): void;
|
|
174
|
+
}
|
|
175
|
+
/**
|
|
176
|
+
* The transport's session, opened on first use. One that fails to open is forgotten, so the next
|
|
177
|
+
* operation opens it again.
|
|
178
|
+
*/
|
|
179
|
+
export declare function qudelixSession(ctx: HandlerContext<HidTransport, unknown>): Promise<QudelixSession>;
|
|
180
|
+
/** Closes and forgets a session, as the app reconnects after a failed transfer. */
|
|
181
|
+
export declare function dropSession(session: QudelixSession): void;
|
|
182
|
+
/** Refuses a device the handler doesn't drive, naming the handler that does. */
|
|
183
|
+
export declare function modelFor(session: QudelixSession, protocol: 1 | 2): QudelixModel;
|
|
184
|
+
export {};
|
|
185
|
+
//# sourceMappingURL=qudelix.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"qudelix.d.ts","sourceRoot":"","sources":["../../src/handlers/qudelix.ts"],"names":[],"mappings":"AA8BA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,6BAA6B,CAAC;AAG1D,OAAO,KAAK,EAAE,cAAc,EAAE,QAAQ,EAAE,UAAU,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AAGpF,OAAO,KAAK,EAAqB,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAqCvE,8FAA8F;AAC9F,MAAM,WAAW,WAAW;IAC3B,QAAQ,EAAE,MAAM,CAAC;IACjB,QAAQ,EAAE,MAAM,CAAC;IACjB,oDAAoD;IACpD,UAAU,EAAE,MAAM,CAAC;CACnB;AAED,2FAA2F;AAC3F,eAAO,MAAM,YAAY,EAAE,WAA+D,CAAC;AAa3F,6FAA6F;AAC7F,wBAAgB,MAAM,CAAC,CAAC,EAAE,YAAY,GAAG,WAAW,CAoBnD;AAED,uEAAuE;AACvE,wBAAgB,MAAM,CAAC,IAAI,EAAE,WAAW,EAAE,MAAM,EAAE,SAAS,MAAM,EAAE,GAAG,QAAQ,CAW7E;AAED,qDAAqD;AACrD,eAAO,MAAM,UAAU,GAAI,MAAM,WAAW,EAAE,OAAO,QAAQ,KAAG,UACnB,CAAC;AAE9C,uDAAuD;AACvD,eAAO,MAAM,MAAM,GAAI,SAAS,MAAM,EA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