Using MKR WAN 1300 for P2P communication .. failed..

Hello guys.
First of all, please understand that i'm poor at english. because i don't live in english-speaking countries.

I want to peer to peer communication through two MKR WAN 1300.
but i have failed.

how i did :

  • install MKRWAN, LoRa(sandeepmistry) libraury.
  • FW Update. using MKRWANFWUpdate standalone example in MKRWAN libraury.
  • only USB connection with laptop. No circuit. (i don't know if other people do the same.)
  • use LoRaReceive, LoRaSender example in LoRa libraury.

some people succeeded through this process. but i couldn't

it just said "Starting LoRa failed!" ( Failed LoRa.begin() )

when i uploaded a sketch, i heard the USB disconnect sound. but uploading was completed without any failure. And soon i heard USB 'connect' sound again.
i run serial monitor, i could see that upload was successful.
:: maybe caused by this?

how can i solve this problem??
please help me

thanks

because i don't live in english-speaking countries.

Me too. :slight_smile:

install MKRWAN, LoRa(sandeepmistry) libraury.

If you read the sticky post at the top of the topic you knew we need a link to that library so we're looking at the same code.

use LoRaReceive, LoRaSender example in LoRa libraury.

Post the exact code you're using!

Oh I’m sorry my mistake…

This is the LoRaReceive sketch. LoRaSender is almost same with this.

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

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

  Serial.println("LoRa Receiver");

  if (!LoRa.begin(915E6)) {                                 // I can't pass this sentence..
    Serial.println("Starting LoRa failed!");
    while (1);
  }
}

void loop() {
  // try to parse packet
  int packetSize = LoRa.parsePacket();
  if (packetSize) {
    // received a packet
    Serial.print("Received packet '");

    // read packet
    while (LoRa.available()) {
      Serial.print((char)LoRa.read());
    }

    // print RSSI of packet
    Serial.print("' with RSSI ");
    Serial.println(LoRa.packetRssi());
  }
}

You forgot the code tags!

As far as I know the LoRa module used in the MKR1300 doesn't work with the arduino-LoRa library you seem to be using (you forgot that link too).

Have you tried the MKRWAN library Arduino is providing for the MKR1300 (available in the IDE library manager)?

I tried MKRWAN library too.

MKRWAN examples use The Things Network. but I want to peer to peer.

So I searched for that. and I found it works with LoRa library.

Someone said Peer to Peer Communication was successful by using LoRa library & MKRWAN 1300.

so I tried what they did. and failed.

So I searched for that. and I found it works with LoRa library.

The LoRa library has extra sections to allow using it with MKRWAN1300. But I don't know if you're able to communicate with any LoRa counterpart using it. BTW, what device is your communication partner?