Update main.cpp

This commit is contained in:
tuxphone 2020-09-27 18:02:36 +02:00 committed by GitHub
parent a27c6e8fe9
commit 5548789c19
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -33,7 +33,7 @@ void setup() {
Radio.Init( &RadioEvents ); Radio.Init( &RadioEvents );
Radio.Sleep(); Radio.Sleep();
memcpy(ChanSet.name, MESHTASTIC_NAME, 12); memcpy(ChanSet.name, MESHTASTIC_NAME, 12);
ChanSet.channel_num = hash( MESHTASTIC_NAME ) % myRegion[REGION].numChannels; // see MeshRadio.h ChanSet.channel_num = hash( MESHTASTIC_NAME ) % myRegion[REGION].numChannels; // see config.h
ChanSet.tx_power = (myRegion[REGION].powerLimit == 0) ? TX_MAX_POWER : myRegion[REGION].powerLimit; ChanSet.tx_power = (myRegion[REGION].powerLimit == 0) ? TX_MAX_POWER : myRegion[REGION].powerLimit;
if (ChanSet.tx_power > TX_MAX_POWER) ChanSet.tx_power = TX_MAX_POWER; if (ChanSet.tx_power > TX_MAX_POWER) ChanSet.tx_power = TX_MAX_POWER;
ChanSet.psk = MESHTASTIC_PSK; ChanSet.psk = MESHTASTIC_PSK;