forked from Blendman974/faceclaw
Sound effects demo, and music controller
This commit is contained in:
1 parent
5f82981b92
commit
56d0f8c351
13 files changed
+717
-145
No files matched your search
@@ -421,13 +421,11 @@ export class FaceclawCommunicatorBridge {
|
||||
return this.enqueueJavaCall(() => Boolean(this.communicator.sendShutdown(exitMode)));
|
||||
}
|
||||
|
||||
async playBuzzerNote(note: number, oct: number, beat: number): Promise<void> {
|
||||
/** Play a CFW mode-5 kind-4 tone sequence (complete wire payload). */
|
||||
async playBuzzerSequence(payload: Uint8Array): Promise<void> {
|
||||
const snapshot = new Uint8Array(payload);
|
||||
await this.enqueueJavaCall(() => {
|
||||
this.communicator.playBuzzerNote(
|
||||
Math.round(note),
|
||||
Math.round(oct),
|
||||
Math.round(beat),
|
||||
);
|
||||
this.communicator.playBuzzerSequence(snapshot.buffer);
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user