netconfcentral logo

ietf-lora@2016-06-01



  module ietf-lora {

    yang-version 1;

    namespace
      "urn:ietf:params:xml:ns:yang:ietf-lora";

    prefix lora;

    organization "Acklio";

    contact "Ana Minaburo ana@minaburo.com";

    description
      "This module contains a collection of YANG definitions for
   configuring the LORA () network interface.

   Copyright (c) 2015 IETF Trust and the persons identified as
   authors of the code. All right reserved.

   Redistribution and use in source binary forms, with or
   without modification, is permitted pursuant to, and subject
   to the license terms contained in, the Simplified BSD License
   Relating to IETF Documents
   (http://trustee.ietf.org/license-info)

   This YANG module version is part of draft-minaburo-6lpwa-cosol-00;
   see the draft itself for full legal notices.";

    revision "2016-06-01" {
      description "Initial Description";
      reference
        "LoRa MAC Class A Specification R3.1 by Semtech";

    }


    container lora {
      description "LORA channel";
      leaf channel-bandwidth {
        type enumeration {
          enum "125" {
            value 0;
            description "125 KHz";
          }
          enum "150" {
            value 1;
            description "150 KHz";
          }
          enum "500" {
            value 2;
            description "500 KHz";
          }
        }
        description
          "Physical Channel Bandwidth";
      }

      leaf coding-rate {
        type enumeration {
          enum "4_5" {
            value 1;
            description "";
          }
          enum "4_6" {
            value 2;
            description "";
          }
          enum "4_7" {
            value 3;
            description "";
          }
          enum "4_b" {
            value 4;
            description "";
          }
        }
        description
          "LORA error correction scheme";
      }

      leaf spreading-factor {
        type uint8 {
          range "6 .. 12";
        }
        description
          "Modulation to enable spread signals";
      }

      container physical-layer {
        description "LORA phisical layer";
        leaf preamble-length {
          type int32;
          default '7';
          description
            "Header packet definition";
        }

        leaf channel-frequency-range {
          type enumeration {
            enum "europe" {
              value 1;
              description "";
            }
            enum "usa" {
              value 2;
              description "";
            }
            enum "japan" {
              value 3;
              description "";
            }
            enum "china" {
              value 4;
              description "";
            }
          }
          mandatory true;
          description
            "Band Choice depends on Country";
        }

        leaf channel {
          type uint8 {
            range "0..10";
          }
          description "Physical Channels";
        }

        leaf symbol-timeout {
          type uint32;
          description
            "Waiting the free band";
        }
      }  // container physical-layer

      container mac-layer {
        description " LORA MAC layer format";
        leaf payload-encryption {
          type boolean;
          default "false";
          description
            "Known if the encryption is used";
        }

        leaf delay {
          type int32;
          description "Delay value";
        }

        leaf fixed-length-payload {
          type boolean;
          default "false";
          description
            "If Modulation is not variable";
        }
      }  // container mac-layer
    }  // container lora
  }  // module ietf-lora