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 asyncio | |
import time | |
from math import sin, cos, atan2, tan, radians, degrees | |
import random | |
from windlock_beta.flight_control.flight_controller import ControlInput | |
GRAVITY_ACC = 9.80665 # m/s^2 | |
def mph_to_ms(speed_mph): |
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 <Bounce2.h> | |
#include <EEPROM.h> | |
// input states | |
enum inputState{off, low, medium, high, reset}; | |
// input actions | |
enum inputAction {shortPress, longPress}; |
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 json, os, time | |
from datetime import datetime, timedelta | |
from alphamesh import device_management, mesh_configuration | |
from alphamesh.message_publisher import MessagePublisher, OutboundMessage | |
def handle_message(message, queue, mconfig): | |
try: | |
json_msg = json.loads(message) | |
except Exception as e: |