Echo RSSI upon packet

Hello. I have two ESP32 V2 Heltec LoRa boards.

I am able to send strings to a receiver and do things.

I would like the receiver to echo RSSI back to the transmitter (which will momentarily become a receiver). I have tried a lot of things but can seem to get it to work. I understand it is half duplex, but I would like to switch the state of both from one to the other, transmit/receive, and then back to be able to monitor RSSI on the remote end.

Thanks.

This is of course possible. You can combine the sending and receiving codes together. You can refer to the example of lora_pingpong.

1 Like

Okay so I have two programs, receiver and sender. Receiver echo commands to sender. For some reason the echo is only displayed every other time it is sent. Here’s an example of the sender’s serial terminal -

12:56:24.152 -> Sending packet 1
12:56:27.675 -> Sending packet 2
12:56:28.092 -> Recevied 2 with RSSI 4
12:56:30.226 -> Sending packet 3
12:56:32.684 -> Sending packet 4
12:56:33.100 -> Recevied 4 with RSSI 4
12:56:34.954 -> Sending packet 5
12:56:37.087 -> Sending packet 6
12:56:37.503 -> Recevied 6 with RSSI 4

So you can see the first packet sent returns nothing. Then the second does, and the third nothing again, fourth does return an 5th doesn’t.

sender - https://pastebin.com/jXuBJUE6
receiver - https://pastebin.com/ar2MYuZK

I moved the receive function in the transmitter to the main loop and that solved the issue. Still not sure why what I posted wouldn’t work, but it’s fixed.