Lightweight drone helper code and experiments
Project description
Northwind Drone Navigation Library
Version 1.2.2
A lightweight set of helper modules and experiments for drone-style navigation, obstacle handling, and stability logic. This is not a full autopilot system — it is more of a code sketch for testing ideas and learning.
Features
1. Navigation (Location and route math)
set_target_coordinate(lat, lon)- Save a GPS destination coordinateplan_flight_path(start, end)- Build a waypoint route from start to endrefresh_position()- Simulate a GPS/IMU position update
2. Obstacle Handling (Critical)
scan_for_obstacle(sensor_data)- Check sensor inputs for nearby obstaclesexecute_avoidance(direction)- Perform a basic obstacle avoidance maneuverreroute_path()- Rebuild the route after avoiding an obstacle
3. Stability / Correction (Real Drone Behavior)
correct_gps_drift(gps_error)- Correct a GPS drift estimateadjust_altitude(wind_data)- Adjust altitude based on wind conditionsengage_hover_hold()- Hold position using stabilization control
4. Mission Control
start_mission()- Begin a mission sequencepause_mission()- Pause the current missionreturn_home()- Return to home position safely
5. Decision Helpers
choose_action(state)- Choose the next action based on current statepredict_next_move()- Predict the next move using simple logic
6. Data Logging (For Learning)
log_flight_data()- Log flight telemetry and sensor dataexport_data()- Export logged data to JSON filessend_to_cloud()- Upload data to cloud storage for analysis
Installation
Install the latest release from PyPI:
pip install --upgrade northwind
Install the current repository version from GitHub:
pip install --upgrade git+https://github.com/qwert1231231/northwind.git
Or clone and install locally:
git clone https://github.com/qwert1231231/northwind.git
cd northwind
pip install -e .
Quick Start
import northwind
# Set destination coordinates
northwind.set_target_coordinate(37.7749, -122.4194) # San Francisco
# Start autonomous mission
northwind.start_mission()
# Hardware motor control
northwind.configure_motor_profile('esp32')
northwind.set_motor_speed_percent(75) # percent of full PWM range
northwind.ramp_motor_speed(90, step=10, delay=0.1)
status = northwind.read_motor_status()
print(status)
# Decision helpers
action = northwind.choose_action('normal')
next_move = northwind.predict_next_move()
# Log flight data
northwind.log_flight_data()
northwind.export_data()
Motor Speed Control
Northwind 1.1.2 introduces PWM-based motor speed control for embedded hardware platforms. Supported device profiles:
esp32— ESP32 PWM driver profilearduino— Arduino PWM driver profiledrone— Generic drone ESC PWM profile
Use configure_motor_profile(...) to choose the device type, then control speed with set_motor_speed_percent(...) or set_motor_pwm(...).
Requirements
- Python 3.8+
- GPS/IMU sensors (for real drone integration)
- Cloud storage account (optional, for data upload)
Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
License
MIT License - see LICENSE file for details.
Repository
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file northwind-1.2.2.tar.gz.
File metadata
- Download URL: northwind-1.2.2.tar.gz
- Upload date:
- Size: 19.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4076d176d6642bf2642a2e2a3dd1965c527839671c82459bec67fd22bb1a9260
|
|
| MD5 |
bd4605078dacb988f0ddfdffafb466f2
|
|
| BLAKE2b-256 |
fa33c9c6a452c6fbf92dba6cb547683a477d8a84fbb9fde28963d0bb03aadac7
|
File details
Details for the file northwind-1.2.2-py3-none-any.whl.
File metadata
- Download URL: northwind-1.2.2-py3-none-any.whl
- Upload date:
- Size: 25.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f0d84cb2ea97edfda8d8e1842c0c5b4631a31b13c697aec7eba9b56512c018e3
|
|
| MD5 |
1587448b99e6a8582051d4d5cba46fe2
|
|
| BLAKE2b-256 |
59606c1f6e61fb045c583503e5e0d6b052b1bd72a53fef0f11bdb567b3cbdf29
|