Skip to content

Instantly share code, notes, and snippets.

View sabas1080's full-sized avatar
🐈
Working

Sabas sabas1080

🐈
Working
View GitHub Profile
<!-- Begin MailChimp Signup Form -->
<link href="//cdn-images.mailchimp.com/embedcode/horizontal-slim-10_7.css" rel="stylesheet" type="text/css">
<style type="text/css">
#mc_embed_signup{background:#fff; clear:left; font:14px Helvetica,Arial,sans-serif; width:100%;}
/* Add your own MailChimp form style overrides in your site stylesheet or in this style block.
We recommend moving this block and the preceding CSS link to the HEAD of your HTML file. */
</style>
<div id="mc_embed_signup">
<form action="https://theinventorhouse.us7.list-manage.com/subscribe/post?u=65b0ff13537d14f980739b5d4&amp;id=df48846e97" method="post" id="mc-embedded-subscribe-form" name="mc-embedded-subscribe-form" class="validate" target="_blank" novalidate>
<div id="mc_embed_signup_scroll">
@sabas1080
sabas1080 / Sub bands LoRaWAN
Created July 26, 2018 19:37
Sub Band LoRaWAN ans channel plus
FSB 1 (aka block A) = 0, 1, 2, 3, 4, 5, 6, 7 (125 kHz channels) plus 64 (500 kHz channel)
FSB 2 (aka block B) = 8, 9, 10, 11, 12, 13, 14, 15 plus 65
FSB 3 (aka block C) = 16, 17, 18, 19, 20, 21, 22, 23 plus 66
FSB 4 (aka block D) = 24, 25, 26, 27, 28, 29, 30, 31 plus 67
FSB 5 (aka block E) = 32, 33, 34, 35, 36, 37, 38, 39 plus 68
FSB 6 (aka block F) = 40, 41, 42, 43, 44, 45, 46, 47 plus 69
FSB 7 (aka block G) = 48, 49, 50, 51, 52, 53, 54, 55 plus 70
FSB 8 (aka block H) = 56, 57, 58, 59, 60, 61, 62, 63 plus 71
@sabas1080
sabas1080 / ESP32_HID.ino
Last active January 28, 2024 10:34
Example of HID Keyboard BLE with ESP32
/*
Copyright (c) 2014-2020 Electronic Cats SAPI de CV. All right reserved.
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
/*******************************************************************************
* Copyright (c) 2015 Thomas Telkamp and Matthijs Kooijman
*
* Permission is hereby granted, free of charge, to anyone
* obtaining a copy of this document and accompanying files,
* to do whatever they want with them without any restriction,
* including, but not limited to, copying, modification and redistribution.
* NO WARRANTY OF ANY KIND IS PROVIDED.
*
* This example sends a valid LoRaWAN packet with payload "Hello,
@sabas1080
sabas1080 / example__sender_Lora_RAK811.ino
Created April 20, 2018 02:19
Example for RAK811 with Lora Sender and library LoRa
/*
Example for RAK811 with Lora Sender and library LoRa https://github.com/sandeepmistry/arduino-LoRa
*/
#include <SPI.h>
#include <LoRa.h>
int counter = 0;
void setup() {
@sabas1080
sabas1080 / lora.py
Created April 15, 2018 03:54 — forked from daveake/lora.py
from microbit import spi, sleep, pin16
import array
import gc
class LoRa(object):
"""
Radio - LoRa. Single channel.
"""
def __init__(self, Frequency=434.450, Mode=1):
include "SparkFunMPL3115A2.h" //Pressure sensor - Search "SparkFun MPL3115" and install from Library Manager
#include "SparkFunHTU21D.h" //Humidity sensor - Search "SparkFun HTU21D" and install from Library Manager
#include <lmic.h>
#include <hal/hal.h>
#include <SPI.h>
#include<CayenneLPP.h>
CayenneLPP lpp(51);
MPL3115A2 myPressure; //Create an instance of the pressure sensor
@sabas1080
sabas1080 / test_groundstation.ino
Created March 5, 2018 19:38
Ejemplo de datos enviados por estacion terrena catsat
void setup() {
// put your setup code here, to run once:
Serial.setup(9600);
}
void loop() {
// put your main code here, to run repeatedly:
//A1,temp1,hum,press,temp2,mx,my,mz,ax,ay,az,gx,gy,gz,lat,long
Serial.println(A1,23,70,800,21,34,45,23,12,43,90,89,67,54,22.3446,-102.8967);
delay(3000); //3 segundos
#include "AES-128_V10.h"
unsigned char NwkSkey[16] = {
0x00, 0xE2, 0xC1, 0x11, 0xCF, 0x0B, 0xFB, 0x8D,
0x1D, 0x08, 0x98, 0xF0, 0xCA, 0xA8, 0x77, 0x00
};
unsigned char AppSkey[16] = {
0x00, 0x9B, 0x51, 0x67, 0x09, 0x92, 0xC2, 0x40,
0xAC, 0x1C, 0xF4, 0xE2, 0x38, 0x9C, 0x8D, 0x00
int lecturas[6]={0,0,0,0,0,0};
void setup() {
// put your setup code here, to run once:
}
void loop() {
// put your main code here, to run repeatedly:
for(i=0;i=6;i++){
lectura[i]=analogRead(A0);