GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com β€” GitHub - dantiel/PteronautOS: Open-source firmware for servo-driven ornithopters

BranchesTags
Open more actions menu

Latest commit

 

History

3,071 Commits
3,071 Commits

Folders and files

NameName
Last commit message
Last commit date
.github
.github
 
 
docs
docs
 
 
egg
egg
 
 
scripts
scripts
 
 
sketches
sketches
 
 
src
src
 
 
tools
tools
 
 
worker
worker
 
 
.gitattributes
.gitattributes
 
 
.gitignore
.gitignore
 
 
.tm_properties
.tm_properties
 
 
DEVELOPING.md
DEVELOPING.md
 
 
FLASH-SCRIPT.md
FLASH-SCRIPT.md
 
 
FUTURE_DEVELOPMENTS.md
FUTURE_DEVELOPMENTS.md
 
 
HARDWARE.md
HARDWARE.md
 
 
LICENSE
LICENSE
 
 
README.md
README.md
 
 
add_all_flight_i18n.py
add_all_flight_i18n.py
 
 
add_flight_profiles_i18n.py
add_flight_profiles_i18n.py
 
 
add_import_done_i18n.py
add_import_done_i18n.py
 
 
add_ornithopter_i18n.py
add_ornithopter_i18n.py
 
 
hermetic.manifest.md
hermetic.manifest.md
 
 
index.haml
index.haml
 
 
patch_flight_profiles_lithaml.py
patch_flight_profiles_lithaml.py
 
 
pteronaut-os-footer.png
pteronaut-os-footer.png
 
 
pteronaut-welcome.png
pteronaut-welcome.png
 
 

Repository files navigation

PteronautOS

Welcome, Pteronaut.

Open-source firmware for servo-driven ornithopters β€” built on ExpressLRS.

🌐 Documentation & Website β€” EN Β· PT

PteronautOS replaces the traditional fixed-wing flight controller with an adaptive flapping oscillator built directly into the receiver. No intermediate FC required. The radio link directly drives the wings.

Features

  • Adaptive Flapping Oscillator β€” configurable waveform, amplitude, and frequency per channel
  • Automatic Gliding β€” wings lock at neutral below throttle threshold (with hysteresis)
  • Zephyrus Gyro Stabilization β€” MPU6050-based crest rudder correction for roll + yaw stability
  • Failsafe β€” wings return to neutral on link loss, re-arm on reconnect
  • Direct PWM Output β€” drives two wing servos + rudder + auxiliary channels
  • Minimal Footprint β€” non-essential ELRS modules stripped (Telemetry, Baro, VTX, Thermal, Serial1)

Build

The one-command path builds the WebUI, compiles the firmware, and flashes it:

./scripts/flash.sh --lang en     # English only
./scripts/flash.sh --lang de,en  # German + English
./scripts/flash.sh --lang all    # all 11 languages
./scripts/flash.sh               # interactive: pick all / some / skip

The flash script bakes the selected WebUI languages into the firmware, then runs pio. To build manually (without flashing):

cd src/html && nvm use 20 && I18N_LOCALES=en npm run build:pteronautos
cd ../.. && pio run -d src -e PteronautOS_ESP8285_2400_RX

Requires Node.js 20+. The I18N_LOCALES flag (and --lang on the flash script) selects which languages are baked into the WebUI β€” a comma-separated list (e.g. en,de) or a single code; omit it to include all 11 languages.

Developer guides

These live on the docs website too β€” under Tutorials β†’ For developers (kept apart from the user tutorials so flying stays easy):

Guide Scope Website
DEVELOPING.md Developer tutorial β€” toolchain setup, repo layout, build order, target envs, config, and build rules tutorials/developing
FLASH-SCRIPT.md scripts/flash.sh tutorial β€” flags, mixers, saved presets, --no-build, and flashing tutorials/flash-script

Current Footprint (ESP8285)

Resource Used Free
RAM 50,856 / 81,920 (62.1%) 31,064 bytes
Flash 553,272 / 991,216 (55.8%) 437,944 bytes

Hardware

Guide Scope
HARDWARE.md Complete wiring guide β€” PWMP7 v1.1 pin mappings, GY-521 IΒ²C wiring, voltage tables, servo compatibility, flash workflow
ELRS PWM7 Reference Generic ELRS PWM7 board specs and pin reference
PteronautOS.md Main project documentation β€” architecture, modules, build system, full pin mappings

Architecture

Radio Packet β†’ ChannelData[16] β†’ servosUpdate() (β‰ˆkHz tick)
                                      β”‚
                    β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
                    β–Ό                 β–Ό                  β–Ό
            zephyrusUpdate()  ornithopterUpdate()  servoCalcAllChannels()
           (gyro→AHRS→PID)    (flapping oscillator)  (standard PWM map)
                    β”‚                 β”‚
                    β–Ό                 β–Ό
           gyroRudderCorrection   servoLeftUs/servoRightUs
                    β”‚                 β”‚
                    β””β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                         β–Ό
                   servoRudderUs (pilot mix + gyro correction)
                         β”‚
                         β–Ό
                   PWM Output (GPIOs)

MUSHIN bridge β€” when MUSHIN_ENABLED=1 and a YOSHIMITSU muscle is linked, the spirit streams wave parameters instead of finished Β΅s; the RP2040 reconstructs phase + waveform locally. See docs/MUSHIN.md.

Ornithopter Module (src/lib/Ornithopter/)

File Lines Purpose
Ornithopter.h 57 Core oscillator β€” state, timing, flapping/gliding logic
Ornithopter.cpp 152 Engine implementation β€” waveform generation, channel mixing
OrnithopterConfig.h 54 Compile-time defaults β€” channel mapping, servo limits, scaling
OrnithopterWaveform.h 56 Waveform library β€” sin, saw, square, custom shapes
OrnithopterFilter.h 35 Integration bridge β€” #ifdef ORNITHOPTER_MODE guards

Zephyrus Gyro Module (src/lib/Zephyrus/)

File Lines Purpose
ZephyrusConfig.h 54 Compile-time constants β€” IΒ²C, MPU6050, AHRS, PID, mixer gains
Zephyrus.h 85 Class declaration β€” MPU6050 driver, Mahony AHRS, dual PID
Zephyrus.cpp 526 Full implementation β€” sensor read, calibration, AHRS, PID, correction
ZephyrusFilter.h 35 Bridge shim β€” copies rudderCorrection β†’ ornithopter.gyroRudderCorrection

See Zephyrus README for full architecture, API, tuning guide, and troubleshooting.

Integration Points in devServoOutput.cpp

Line Mechanism Effect
10 #include "Ornithopter/OrnithopterFilter.h" + "Zephyrus/ZephyrusFilter.h" Zero overhead without build flags
158 ornithopterOnLinkDown() + zephyrusOnLinkDown() in servosEnterFailsafe() Wings to neutral, zero gyro on link loss
230 zephyrusUpdate() before ornithopterUpdate() in servosUpdate() Gyro correction set before mixer runs
357 ornithopterOnLinkUp() + zephyrusOnLinkUp() in event() Arms ornithopter, resets PID on connection

Stripped Modules in rx_main.cpp

All guarded with #ifndef ORNITHOPTER_MODE:

  • AnalogVbat, Baro, VTxSPI, MSPVTx, Thermal
  • Serial1, SerialUpdate
  • Serial protocols (SBUS, CRSF serial via OPT_CRSF_RCVR_NO_SERIAL)

Kept: RF link, binding, PWM output, LED, WiFi config, Button, RX LUA.

Configuration

Edit src/lib/Ornithopter/OrnithopterConfig.h to map your CRSF channels and tune flapping parameters:

  • Wing servo PWM indices: ORNITHOPTER_SERVO_LEFT / ORNITHOPTER_SERVO_RIGHT
  • 10 CRSF channel assignments: throttle, arm, cadence, ferocity, etc.
  • Servo Β΅s limits, flapping/gliding thresholds, amplitude scaling
  • Steering differential, elevator/aileron scale, cadence rating

For gyro tuning, edit src/lib/Zephyrus/ZephyrusConfig.h β€” see the Zephyrus README.

Community

Questions, ideas, and build showcases live in GitHub Discussions. For bugs, open an issue.

  • πŸ’¬ General β€” open conversation
  • πŸ’‘ Ideas β€” feature requests
  • πŸ™ Q&A β€” community help
  • πŸ¦… Show and tell β€” builds & flights

Credits

Built on ExpressLRS. Ornithopter module ported from GralhaAzul v1.29.0. Zephyrus Gyro Module written from scratch for PteronautOS β€” MPU6050 register-level driver, Mahony AHRS, and dual PID with anti-windup.

PteronautOS

About

Open-source firmware for servo-driven ornithopters

dantiel.github.io/PteronautOS/

Topics

arduinobirdscrsfelrsesp32esp8266firmwareflight-controllerloraornithopterpterosaurrcremote-controlservo

Resources

Readme
GPL-3.0 license
Activity

Stars

6 stars

Watchers

0 watching

Forks

0 forks
Report repository

Releases

Packages

Contributors

Languages

You are visitor 01402792 β€” GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800Γ—600. No cookies required.