最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

Sending data by LoRa connected to Arduino. How to receive and decode it using usrp by flowgraph in gnuradio - Stack Overflow

programmeradmin2浏览0评论

I'm sending data from LoRa connected to Arduino. I'm attaching my code here.

#include <SPI.h>
#include <LoRa.h>

void setup() {
Serial.begin(9600);
while (!Serial);

// Initialize LoRa with frequency set to 868 MHz
if (!LoRa.begin(868E6)) {
Serial.println("LoRa initialization failed. Check your wiring.");
while (1);
}

// Set LoRa parameters to match GNU Radio flowgraph
LoRa.setSignalBandwidth(250E3); // Bandwidth: 250 kHz
LoRa.setSpreadingFactor(7);     // Spreading Factor: SF7
LoRa.setCodingRate4(5);         // Coding Rate: 4/5
LoRa.enableCrc();               // Enable CRC (matches `has_crc = True`)

Serial.println("LoRa initialized with 250 kHz bandwidth, SF7, CR 4/5, and CRC enabled.");
}

void loop() {
String message = "THIS IS LORA PROJECT"; // Message to send
Serial.println("Sending message: " + message);

LoRa.beginPacket();  // Begin packet transmission
LoRa.print(message); // Add message to the packet
LoRa.endPacket();    // Complete and send the packet

delay(10000); // 
}

Now how to check whether usrp is receiving the transmitted data or not. On the transmitting side there is no problem.

But on the receiving side I can't see whether it is receiving it or not and I need to decode the received signal. So for this I need the flowgraph to check the data and decode it.

Can you please tell the flowgraph to execute all this process? It'll be very helpful for me.

与本文相关的文章

发布评论

评论列表(0)

  1. 暂无评论