From 30029c5c8d1c78558f1933de33c146b1d7012cc2 Mon Sep 17 00:00:00 2001 From: tuxphone <67556506+tuxphone@users.noreply.github.com> Date: Mon, 21 Sep 2020 21:56:31 +0200 Subject: [PATCH] Display Channel Name @ Start --- main.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/main.cpp b/main.cpp index 176850c..1fa0dec 100644 --- a/main.cpp +++ b/main.cpp @@ -38,7 +38,7 @@ void setup() { RadioEvents.RxDone = RxDone; Radio.Init( &RadioEvents ); Radio.Sleep(); - ChanSet.name[12] = MESHTASTIC_NAME[12]; + memcpy(ChanSet.name, MESHTASTIC_NAME, 12); ChanSet.channel_num = hash( MESHTASTIC_NAME ) % NUM_CHANNELS; // see MeshRadio.h ChanSet.tx_power = TX_OUTPUT_POWER; /* FYI: @@ -200,6 +200,7 @@ void ConfigureRadio( ChannelSettings ChanSet ) uint32_t freq = (CH0 + CH_SPACING * ChanSet.channel_num)*1E6; #ifndef SILENT Serial.printf("\nSetting frequency to %i Hz (meshtastic channel %i) .. \n",freq,ChanSet.channel_num ); + Serial.printf("Channel name is %s .. \n", ChanSet.name ); Serial.printf("Setting bandwidth to index %i ..\n",ChanSet.bandwidth); Serial.printf("Setting CodeRate to index %i .. \n", ChanSet.coding_rate); Serial.printf("Setting SpreadingFactor to %i ..\n",ChanSet.spread_factor);