Node: Need a sketch that works with Dragino LoRa Shield & Arduino Uno

I have used the 868 version just fine. There are some changes that you need to do that are specific for 915Mhz
Have a look here for tests and changes if you want 915Mhz to work OK
N.B. Only ABP works with the Dragino single channel gateway
http://wiki.dragino.com/index.php?title=Lora_Shield#Example1_--_Use_with_LMIC_library_for_LoRaWAN_compatible

1.Copy this code to your IDE and upload the sketch to your Arduino board:
There,you can also add below code to your sketch to check the current emission frequency:
Serial.println(LMIC.freq);


2.Edit "config.h"
change
   #define CFG_eu868 1
to
  #define CFG_us915 1

3.Edit "lmic.c",about on the line 760,
change
  void LMIC_disableChannel (u1_t channel) {
     if( channel < 72+MAX_XCHANNELS )
        LMIC.channelMap[channel/4] &= ~(1<<(channel&0xF));
  }

to

  void LMIC_disableChannel (u1_t channel) {
      if( channel < 72+MAX_XCHANNELS )
          LMIC.channelMap[channel/16] &= ~(1<<(channel&0xF));
  } 


4.Edit the "main.cpp" to "Set center frequency" on your Raspberry Pi.
change
   uint32_t freq = 868100000; //in Mhz! (868.1)
to
  uint32_t freq = 915000000; //in Mhz! (915.0)
2 Likes