mirror of
https://github.com/ggerganov/ggwave.git
synced 2026-02-07 01:11:22 +08:00
ref #77 : add MT protocols to ggwave.js + new API for setting freqStart
This commit is contained in:
@@ -23,6 +23,9 @@ EMSCRIPTEN_BINDINGS(ggwave) {
|
||||
.value("GGWAVE_PROTOCOL_DT_NORMAL", GGWAVE_PROTOCOL_DT_NORMAL)
|
||||
.value("GGWAVE_PROTOCOL_DT_FAST", GGWAVE_PROTOCOL_DT_FAST)
|
||||
.value("GGWAVE_PROTOCOL_DT_FASTEST", GGWAVE_PROTOCOL_DT_FASTEST)
|
||||
.value("GGWAVE_PROTOCOL_MT_NORMAL", GGWAVE_PROTOCOL_MT_NORMAL)
|
||||
.value("GGWAVE_PROTOCOL_MT_FAST", GGWAVE_PROTOCOL_MT_FAST)
|
||||
.value("GGWAVE_PROTOCOL_MT_FASTEST", GGWAVE_PROTOCOL_MT_FASTEST)
|
||||
|
||||
.value("GGWAVE_PROTOCOL_CUSTOM_0", GGWAVE_PROTOCOL_CUSTOM_0)
|
||||
.value("GGWAVE_PROTOCOL_CUSTOM_1", GGWAVE_PROTOCOL_CUSTOM_1)
|
||||
@@ -113,4 +116,16 @@ EMSCRIPTEN_BINDINGS(ggwave) {
|
||||
int state) {
|
||||
ggwave_txToggleProtocol(protocolId, state);
|
||||
}));
|
||||
|
||||
emscripten::function("rxProtocolSetFreqStart", emscripten::optional_override(
|
||||
[](ggwave_ProtocolId protocolId,
|
||||
int freqStart) {
|
||||
ggwave_rxProtocolSetFreqStart(protocolId, freqStart);
|
||||
}));
|
||||
|
||||
emscripten::function("txProtocolSetFreqStart", emscripten::optional_override(
|
||||
[](ggwave_ProtocolId protocolId,
|
||||
int freqStart) {
|
||||
ggwave_txProtocolSetFreqStart(protocolId, freqStart);
|
||||
}));
|
||||
}
|
||||
|
||||
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user