This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include "Arduino.h" | |
#include <SPI.h> | |
#include <OneWire.h> | |
#include <DallasTemperature.h> | |
#include "stm32f1xx.h" | |
#define ANALOG_IN_PIN PB0 // ADC Channel 0 | |
#define NUM_SAMPLES 2500 | |
#define ANALOG_IN_CHANNEL 8 // PB0 -> ADC1_IN8 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import sys | |
import numpy as np | |
import serial | |
import serial.tools.list_ports | |
import struct | |
from PyQt5.QtWidgets import QHBoxLayout, QGridLayout # Add this to your imports | |
from PyQt5.QtWidgets import QApplication, QMainWindow, QVBoxLayout, QWidget, QComboBox, QPushButton, QLabel, QLineEdit | |
from PyQt5.QtCore import QThread, pyqtSignal |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
// python code for sync command | |
// sends sync broadcast to the network to trigger all devices to synchronize | |
import socket | |
import time | |
UDP_IP = "255.255.255.255" # Broadcast IP address | |
UDP_PORT = 8888 # UDP port |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <ESP8266WiFi.h> | |
#include <PubSubClient.h> | |
const char* mqtt_server = "111.111.111.111"; // change to MQTT BROKER SERVER | |
// MQTT broker settings | |
const int mqtt_port = 1883; | |
const char* mqtt_topic = "/iot/devices/100/power"; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import SwiftUI | |
import Network | |
struct ContentView: View { | |
@State private var ipAddress = "192.168.1.184" | |
@State private var port = "8888" | |
@State private var speed: Double = 200 | |
@State private var steps: Double = 100 | |
@State private var selectedStepMode = 32 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// more info: github.com/neumi/ethersweep | |
import hypermedia.net.*; | |
UDP udp; | |
String ipLeft = "192.168.0.102"; | |
String ipRight = "192.168.0.101"; | |
String ipGripper = "192.168.0.100"; | |
int port = 8888; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <EEPROM.h> | |
int eeprom_size = 512; // depends on microcontroller | |
int max_ssid_size = 32; | |
int max_psk_size = 63; | |
void setup() | |
{ | |
EEPROM.begin(eeprom_size); | |
Serial.begin(115200); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import requests | |
headers = { | |
'Accept': 'application/json', | |
'Authorization': 'key ttn-account-v2.not-a-real-key-blabla-booboo', | |
} | |
params = ( | |
('last', '2d'), | |
) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// MIT License | |
// https://github.com/gonzalocasas/arduino-uno-dragino-lorawan/blob/master/LICENSE | |
// Based on examples from https://github.com/matthijskooijman/arduino-lmic | |
// Copyright (c) 2015 Thomas Telkamp and Matthijs Kooijman | |
// Adaptions Neumi | |
#include <lmic.h> | |
#include <hal/hal.h> | |
static const u1_t NWKSKEY[16] = { 0xF7, 0xA5, 0x02, 0x48, 0x9B, 0xD1, 0xF2, 0x92, 0x97, 0x62, 0x69, 0x4C, 0xDB, 0x2A, 0xE9, 0x7A }; |