lopy received data into text conversion
-
how to convert lopy lora received data into text.
-
@jcaron Rx_iq set to False. if i set it True, lopy does not receive any data.
how can i set sampling rate?
-
@seb import ubinascii
from network import LoRa
from machine import Pin
import socket
import machine
import timelora = LoRa(mode=LoRa.LORA, frequency=868000000, tx_power=14, bandwidth=LoRa.BW_250KHZ, sf=8, preamble=8, coding_rate=LoRa.CODING_4_8, power_mode=LoRa.ALWAYS_ON, tx_iq=False, rx_iq=False, adr=True, public=True, tx_retries=1, device_class=LoRa.CLASS_A)
s = socket.socket(socket.AF_LORA, socket.SOCK_RAW)
s.setblocking(False)
while True:
data = s.recv(64)
if(data):
print("Received data: "+"\n1",data)
print ("2",data.decode('utf-8'))
print("3",ubinascii.hexlify(data))
-
You may want to check if changing rx_iq helps.
-
Can you share your code so I can get a better understanding of what is going on
-
This post is deleted!
-
@seb Raw LoRa
@seb when i send using UDP socket, i dont receive anything.
but when i send using file souce with 'Hello mitcoe' at hundreds of lines, it receives some things like this
Received data:
b'\xed\xe7\xe1\xfe\x00MB'
-
@nilam said in lopy received data into text conversion:
matt gr lora
Are you using LoRaWAN or raw LoRa?
-
@seb Thank you for reply.
I am receiving 'Hello mitcoe' message from USRP B200 in gnuradio by using matt gr lora transmitter with udp socket source.
-
We are going to need more details about the format of the incoming data before we can help you out