LowPowerLab Forum

Hardware support => Moteino => Topic started by: ryanlath on January 10, 2019, 01:41:18 PM

Title: Using Moteino 8Mhz / LMIC / LoraWan / The Things Network [solved]
Post by: ryanlath on January 10, 2019, 01:41:18 PM
Hello,

I've got a Moteino 8Mhz with RFM95 radio and I've wired up the RFM95's D0 & D01 pins to Moteino pins.  I'm using the LMIC library and instructions from https://github.com/lukastheiler/ttn_moteino (https://github.com/lukastheiler/ttn_moteino).  I'm able to send one message to TTN, and then nothing.  It seems the TX never completes/gets a response, so it hangs  (OP_TXRXPEND)... but I can't figure out why.

I've tried different LMIC libraries, pin mappings, a different Moteino 8, a local LoraServer, but I'm at a loss as to next debugging steps, so my questions are
  1) has anyone had success using a Moteino 8 to connect to TTN?  If so, please enlighten! 
  2) Is there some hardware reason why this is NOT possible? 

Thanks,
Ryan
Title: Re: Moteino 8Mhz / LMIC / LoraWan / The Things Network
Post by: Felix on January 10, 2019, 06:04:00 PM
Did you try this with a Moteino (regular, 16mhz)? Does that make a difference? If not then then we can look past the fact that it's just half the frequency.
You could actually make the Moteino 8mhz run at 16mhz (provide 3.3V, not less) since the 16mhz resonator is onboard, just not enabled by fuses.
But you'll need an AVR programmer and also you need to burn the 16mhz bootloader.
I haven't tried a Moteino 8 with LoRa/LMIC/TTN so I can't help with that, but maybe others who did this have some insight.
Title: Re: Moteino 8Mhz / LMIC / LoraWan / The Things Network
Post by: ryanlath on January 10, 2019, 11:42:56 PM
I haven't tried a regular Moteino, yet.  This person https://www.thethingsnetwork.org/labs/story/lorawan-gsp-tracker (https://www.thethingsnetwork.org/labs/story/lorawan-gsp-tracker) seems to have regular Mini Pro 3.3v working, though.   
Title: Re: Moteino 8Mhz / LMIC / LoraWan / The Things Network
Post by: ryanlath on January 14, 2019, 04:57:24 PM
I wired up a 3.3V/8Mhz mini pro and radio manually.  It worked, so it took me 2 seconds to find my user error.  To save anyone else some time.  10 and 2 are moteino's pre-wired pins.  DIO1 & DIO2 will be dependent on your wiring.

const lmic_pinmap lmic_pins = {
  .nss = 10,
  .rxtx = LMIC_UNUSED_PIN,
  .rst = LMIC_UNUSED_PIN,
  .dio = {2, DIO1, DIO2},
}
Title: Re: Moteino 8Mhz / LMIC / LoraWan / The Things Network
Post by: Felix on January 15, 2019, 09:07:06 AM
Great, thanks, so it's solved?
Title: Re: Moteino 8Mhz / LMIC / LoraWan / The Things Network
Post by: ryanlath on January 23, 2019, 01:20:12 AM
Yes, solved.