<commit_before>/*
   LoRaLib Settings Example

   This example shows how to change all the properties
   of LoRa transmission. LoRaLib currently supports
   the following settings:
    - pins (SPI slave select, digital IO 0, digital IO 1)
    - carrier frequency
    - bandwidth
    - spreading factor
    - coding rate
    - sync word
    - output power during transmission
    - over current protection limit
    - LoRa preamble length
    - amplifier gain

   For more detailed information, see the LoRaLib Wiki
   https://github.com/jgromes/LoRaLib/wiki

   For full API reference, see the GitHub Pages
   https://jgromes.github.io/LoRaLib/
*/

// include the library
#include <LoRaLib.h>

// create instance of LoRa class using SX1278 module
// this pinout corresponds to RadioShield
// https://github.com/jgromes/RadioShield
// NSS pin:   10 (4 on ESP32/ESP8266 boards)
// DIO0 pin:  2
// DIO1 pin:  3
SX1278 loraSX1278 = new LoRa;

// create another instance of LoRa class using
// SX1272 module and user-specified pinout
// NSS pin:   6
// DIO0 pin:  4
// DIO1 pin:  5
SX1272 loraSX1272 = new LoRa(6, 4, 5);

// create third instance of LoRa class using
// SX1276 module and user-specified pinout
// we ran out of Uno digital pins, so here we use
// analog ones
// NSS pin:   14 (A0)
// DIO0 pin:  15 (A1)
// DIO1 pin:  16 (A2)
SX1276 loraSX1276 = new LoRa(14, 15, 16);

// to use non-default SPI interface or software SPI
// implementation, pass the SPI interface to the LoRa
// constructor
//
// DigitalIO library for software SPI
// https://github.com/greiman/DigitalIO
//#include "DigitalIO.h"
//SoftSPI<MISO_PIN, MOSI_PIN, SCK_PIN> softSpi;
//SX1278 softLora = new LoRa(2, 3, 10, softSpi);

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

  // initialize the LoRa module with default settings
  Serial.print(F("Initializing SX1278 ... "));
  // carrier frequency:           434.0 MHz
  // bandwidth:                   125.0 kHz
  // spreading factor:            9
  // coding rate:                 7
  // sync word:                   0x12
  // output power:                17 dBm
  // current limit:               100 mA
  // preamble length:             8 symbols
  // amplifier gain:              0 (automatic gain control)
  int state = loraSX1278.begin();
  if (state == ERR_NONE) {
    Serial.println(F("success!"));<commit_msg>Updated link to software SPI library<commit_after>/*
   LoRaLib Settings Example

   This example shows how to change all the properties
   of LoRa transmission. LoRaLib currently supports
   the following settings:
    - pins (SPI slave select, digital IO 0, digital IO 1)
    - carrier frequency
    - bandwidth
    - spreading factor
    - coding rate
    - sync word
    - output power during transmission
    - over current protection limit
    - LoRa preamble length
    - amplifier gain

   For more detailed information, see the LoRaLib Wiki
   https://github.com/jgromes/LoRaLib/wiki

   For full API reference, see the GitHub Pages
   https://jgromes.github.io/LoRaLib/
*/

// include the library
#include <LoRaLib.h>

// create instance of LoRa class using SX1278 module
// this pinout corresponds to RadioShield
// https://github.com/jgromes/RadioShield
// NSS pin:   10 (4 on ESP32/ESP8266 boards)
// DIO0 pin:  2
// DIO1 pin:  3
SX1278 loraSX1278 = new LoRa;

// create another instance of LoRa class using
// SX1272 module and user-specified pinout
// NSS pin:   6
// DIO0 pin:  4
// DIO1 pin:  5
SX1272 loraSX1272 = new LoRa(6, 4, 5);

// create third instance of LoRa class using
// SX1276 module and user-specified pinout
// we ran out of Uno digital pins, so here we use
// analog ones
// NSS pin:   14 (A0)
// DIO0 pin:  15 (A1)
// DIO1 pin:  16 (A2)
SX1276 loraSX1276 = new LoRa(14, 15, 16);

// to use non-default SPI interface or software SPI
// implementation, pass the SPI interface to the LoRa
// constructor - this interface must be compatible
// with Arduino SPIClass!
//
// Software SPI library
// https://github.com/MajenkoLibraries/SoftSPI
//#include "SoftSPI.h"
//SoftSPI mySPI(4, 5, 6) ;
//SX1278 softLora = new LoRa(2, 3, 10, mySPI);

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

  // initialize the LoRa module with default settings
  Serial.print(F("Initializing SX1278 ... "));
  // carrier frequency:           434.0 MHz
  // bandwidth:                   125.0 kHz
  // spreading factor:            9
  // coding rate:                 7
  // sync word:                   0x12
  // output power:                17 dBm
  // current limit:               100 mA
  // preamble length:             8 symbols
  // amplifier gain:              0 (automatic gain control)
  int state = loraSX1278.begin();
  if (state == ERR_NONE) {
    Serial.println(F("success!"));
{'fraction_non_alphanumeric': 0.0998941798941799, 'fraction_numerical': 0.04973544973544974, 'mean_word_length': 2.366096866096866, 'pattern_counts': {'":': 0, '<': 6, '<?xml version=': 0, '>': 6, 'https://': 8, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4601140', 'n_tokens_mistral': 1681, 'n_tokens_neox': 1477, 'n_words': 544}