pull/1/head
Tom Early 8 years ago
parent 9a25508d90
commit bd7e59d1b2

@ -26,10 +26,28 @@ gateway = {
}
module = {
a = {
# type = ""
a = { # An MMDVMHost module is shown
# make sure this module letter agrees with the [D-Star] Module letter in MMDVM.ini
# in MMDVM.ini its uppercase, here use lower case.
# We show a here, but the convention on this software is:
# 23 cm modules will use "a"
# 70 cm modules will use "b"
# 2 M module will use "c"
type = "mmdvm"
# ip = "127.0.0.1"
# port = 19998 # default for mod a
# port = 19998 # default for mod a, you usually don't need to specify this
# frequency = 0 # if you specify here, this frequency will show up on the QuadNet USER GATEWAYS webpage
# offset = 0
# range = 0 # the range of this repeater, in meters 1609.344 meters is 1.0 miles
# agl = 0 # the height above ground level for this repeater's antenna
# latitude = 0 # you can leave this unspecified for a mobile rig
# longitude = 0 # like the latitude
# desc1 = "" # maximum of 20 characters, most special symbols are not allowed
# desc2 = "" # just like desc1
# url = "github.com/n7tae/g2_ircddb" # 80 characters max
# In review, for an MMDVM module, you only need to specify the type = "mmdvm" and
# make sure the module letter agrees with what's in "MMDVM.ini.
# Also see the mmdvm section below, although it usually doesn't need specifying.
}
b = {
@ -42,7 +60,7 @@ module = {
# Otherwise do not set callsign and we will use ircddb.username
# callsign = ""
# the frequency of your DVAP in MHz.
# the frequency of your DVRPTR in MHz.
# frequency = 145.5
# the TX/RX offset in MHz, use 0.0 for simplex
@ -221,6 +239,13 @@ module = {
}
}
# you only need this mmdvm section if you set non-standard D-Star ports on your MMDVMHost software
mmdvm = {
# these need to be the same as they are in your MMDVM.ini file (in the [D-Star Network] section
# If you change them there, then change them here!
# gateway_port = 20010
# local_port = 20011
}
log = {
# debuging and extra logging switches

@ -3322,8 +3322,7 @@ static void runit()
(readBuffer[17] == 0x08) ||
(readBuffer[17] == 0x20) ||
(readBuffer[17] == 0x28))) {
if (only_link_unlink &&
(link_unlink_user.find(call) == link_unlink_user.end())) {
if (only_link_unlink && (link_unlink_user.find(call) == link_unlink_user.end())) {
traceit("link request denied, unauthorized rf user [%s]\n", call);
} else {
memset(temp_repeater, ' ', CALL_SIZE);
@ -3340,10 +3339,7 @@ static void runit()
space_p = strchr(linked_remote_system, ' ');
if (space_p)
*space_p = '\0';
sprintf(notify_msg, "%c_already_linked.dat_LINKED_%s_%c",
to_remote_g2[i].from_mod,
linked_remote_system,
to_remote_g2[i].to_mod);
sprintf(notify_msg, "%c_already_linked.dat_LINKED_%s_%c", to_remote_g2[i].from_mod, linked_remote_system, to_remote_g2[i].to_mod);
audio_notify(notify_msg);
}
}

@ -449,16 +449,16 @@ bool CMMDVMModem::ReadConfig(const char *cfgFile)
} else
return true;
GetValue(cfg, std::string(mmdvm_path+".g2_in_port").c_str(), i, 10000, 65535, 19000);
GetValue(cfg, "gateway.internal.port", i, 10000, 65535, 19000);
G2_IN_PORT = (unsigned short)i;
GetValue(cfg, std::string(mmdvm_path+".g2_out_port").c_str(), i, 10000, 65535, 19998+repeater_module);
GetValue(cfg, std::string(mmdvm_path+".port").c_str(), i, 10000, 65535, 19998+repeater_module);
G2_OUT_PORT = (unsigned short)i;
GetValue(cfg, std::string(mmdvm_path+".mmdvm_in_port").c_str(), i, 10000, 65535, 20011);
GetValue(cfg, "mmdvm.local_port", i, 10000, 65535, 20011);
MMDVM_IN_PORT = (unsigned short)i;
GetValue(cfg, std::string(mmdvm_path+".mmdvm_out_port").c_str(), i, 10000, 65535, 20010);
GetValue(cfg, "mmdvm.gateway_port", i, 10000, 65535, 20010);
MMDVM_OUT_PORT = (unsigned short)i;
if (GetValue(cfg, "gateway.ip", value, 7, IP_SIZE, "127.0.0.1")) {
@ -477,7 +477,7 @@ bool CMMDVMModem::ReadConfig(const char *cfgFile)
return false;
}
void CMMDVMModem::SignalCatch(int signum)
void CMMDVMModem::SignalCatch(const int signum)
{
if ((signum == SIGTERM) || (signum == SIGINT) || (signum == SIGHUP))
keep_running = false;

@ -43,7 +43,7 @@ public:
private:
// functions
bool Initialize(const char *cfgfile);
static void SignalCatch(int signum);
static void SignalCatch(const int signum);
bool ProcessGateway(const int len, const unsigned char *raw);
bool ProcessMMDVM(const int len, const unsigned char *raw);
int OpenSocket(const std::string &address, unsigned short port);

Loading…
Cancel
Save

Powered by TurnKey Linux.