mirror of
https://github.com/RFnexus/modem73.git
synced 2026-04-27 14:30:33 +00:00
Create phy folder, add 1/4 coding
This commit is contained in:
parent
f82e2fe8e8
commit
86294a02a5
5 changed files with 828 additions and 6 deletions
6
modem.hh
6
modem.hh
|
|
@ -7,7 +7,7 @@
|
|||
#include <atomic>
|
||||
|
||||
|
||||
#include "common.hh"
|
||||
#include "phy/common.hh"
|
||||
#include "schmidl_cox.hh"
|
||||
#include "bip_buffer.hh"
|
||||
#include "theil_sen.hh"
|
||||
|
|
@ -81,7 +81,7 @@ struct ModemConfig {
|
|||
return acc;
|
||||
}
|
||||
|
||||
static int encode_mode(const char* modulation, const char* code_rate, bool short_frame) {
|
||||
static int encode_mode(const char* modulation, const char* code_rate, bool short_frame) {
|
||||
int mode = 0;
|
||||
|
||||
if (!strcmp(modulation, "BPSK"))
|
||||
|
|
@ -111,6 +111,8 @@ struct ModemConfig {
|
|||
mode |= 2 << 1;
|
||||
else if (!strcmp(code_rate, "5/6"))
|
||||
mode |= 3 << 1;
|
||||
else if (!strcmp(code_rate, "1/4"))
|
||||
mode |= 4 << 1;
|
||||
else
|
||||
return -1;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue