mcci-catena / arduino-lmic

LoraWAN-MAC-in-C library, adapted to run under the Arduino environment
https://forum.mcci.io/c/device-software/arduino-lmic/
MIT License
638 stars 208 forks source link

NODE_LORAWAN #850

Closed mirpaolo closed 2 years ago

mirpaolo commented 2 years ago

Hi everyone, i am recently experimenting with lorawan using this library and i am trying to build a node that reads the state of a pin (ARDUINO UNO) and sends it to the TTN console. If I send a "closed" string everything works correctly image but if I try to read a pin from the arduino it doesn't work, the board (ARDUINO UNO) is blocked, every trasmission is interrupted and to get it working again I have to disconnect the pin and press reset. I can't read a pin and send the pin status. have you had similar problems? I specify that when loading on ARDUINO the code I have a warning: image but then it seems to go on regularly.

This is the monitor log: image or this:

image and at the line 53 of the file i have this: image

but i don't understand where is the problem

mirpaolo commented 2 years ago

It was a conflict problme with pins 12 and 13. These pins cannot be used because they are used to communicate with the miso mosi RF module etc.