Skip to content

hyphae/APIS

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

๐Ÿ”‹ APIS - Autonomous Power Interchange System

Share energy like sharing WiFi - Connect your batteries and let communities power themselves

image 8


๐ŸŽฏ What is APIS?

APIS is an innovative open-source platform that enables Physical Peer-to-Peer (PP2P) energy sharing between distributed batteries in microgrids. By leveraging Variable Renewable Energy (VRE) sources, APIS builds resilient microgrids that enhance community self-sufficiency and reduce dependency on traditional centralized power generation.

๐ŸŒŸ Why This Matters

Imagine if your home battery could automatically share power with your neighbors when they need it, and get power back when you need it. That's exactly what APIS does!

  • ๐Ÿ’ฐ Save Money: Share excess solar power instead of selling it back to the grid at low prices
  • ๐Ÿ”‹ Stay Powered: Never run out of energy when your neighbors have extra
  • ๐ŸŒฑ Go Green: Maximize renewable energy use in your community
  • ๐Ÿ  Be Independent: Reduce reliance on big power companies
  • ๐Ÿ›ก๏ธ Build Resilience: Keep communities powered during grid outages

Click here for more details about the research behind APIS.


๐Ÿ”ง How It Works

image 5

Physical Peer to Peer (PP2P) Energy Sharing

APIS achieves precise energy sharing between batteries using constant current control. This technology:

  • โœ… Offsets energy shortages by delivering the necessary amount from surplus batteries
  • โœ… Enables fixed-amount power transfers between specific users (batteries)
  • โœ… Supports P2P energy trading based on energy amount and price conditions
  • โœ… Works where voltage control fails - providing true peer-to-peer transactions

PP2P Technology Diagram

Autonomous Distributed Control

The same software is installed on every battery system, creating a truly decentralized network where:

  • ๐Ÿค– Smart Decision Making: Each system makes autonomous trading decisions
  • โš™๏ธ Flexible Conditions: Set different trading rules for each battery system
  • ๐Ÿ• Dynamic Updates: Change conditions for each time window
  • ๐Ÿ“Š Custom Parameters: Configure energy amount, pricing, and timing preferences

Autonomous Control Diagram


๐Ÿš€ Quick Start (5 Minutes)

Want to try it out? Here's how:

# 1. Get the code
git clone https://github.com/hyphae/APIS.git
cd APIS

# 2. Build everything  
make build

# 3. Start the system
make run

That's it! Now open your web browser and go to:

Service URL What You'll See
๐Ÿ“Š Main Controller http://0.0.0.0:4382/ Primary dashboard and controls
๐Ÿ”ง Hardware Emulator http://0.0.0.0:4390/ Simulate batteries and DC/DC converters
๐Ÿงช Testing Interface http://0.0.0.0:10000/ System testing and validation tools
๐Ÿข Service Center http://127.0.0.1:8000/static/ui_example/staff/visual.html Admin interface (login: admin/admin)

Starting Your First Energy Exchange

APIS Main Controller

  1. Access the Main Controller at http://0.0.0.0:4382/
  2. Clear your browser cache (recommended for best performance)
  3. Set Global Mode to "Run" to start energy exchange simulation

Energy Exchange Simulation

  1. Watch the magic happen - energy will start flowing between simulated batteries automatically!

To stop the system:

make stop

๐Ÿ› ๏ธ System Components

image 9

APIS consists of several interconnected software modules that work together seamlessly:

๐Ÿ”‹ Core Components (Essential for Basic Operation)

Component Purpose What It Does
๐Ÿง  apis-main Energy Exchange Engine Makes smart trading decisions and handles bi-directional energy flow with autonomous control (Documentation)
๐Ÿ“Š apis-main_controller Visual Dashboard Monitor system status and energy exchanges in real-time through an easy web interface (Documentation)
๐ŸŒ apis-web Web Service Layer Provides data and API services, connects everything to the internet securely (Documentation)
๐Ÿ”ง apis-emulator Hardware Simulator Test the system without real batteries - simulates DC/DC converters and battery behavior (Documentation)

๐Ÿข Extended Services (For Advanced Users & Communities)

Component Purpose What It Does
๐Ÿข apis-service_center Community Management Admin tools for managing large networks, user services, and cluster information Added Dec 24, 2020 (Documentation)
๐Ÿ“ก apis-ccc Communication Hub Coordinates between different APIS networks and uploads energy sharing information Added Dec 24, 2020 (Documentation)
๐Ÿ“‹ apis-log Smart Analytics Receives data via multicast and stores comprehensive system analytics in database Added Dec 24, 2020 (Documentation)
๐Ÿงช apis-tester Quality Assurance Automated testing and evaluation framework for system validation Added Dec 24, 2020 (Documentation)

โšก Real Hardware Integration (For Production Deployments)

Component Purpose What It Does
โš™๏ธ apis-dcdc_batt_comm Hardware Driver Controls actual DC/DC converters and batteries (replaces emulator for real deployments) (Documentation)
๐Ÿš€ apis-build_version_up_system Deployment Tool Automates multi-node software installation and configuration for production systems (Documentation)
๐Ÿ“– apis-hw-info Hardware Guide Reference documentation for compatible hardware and technical specifications (Documentation)

๐Ÿ’ป Installation Guide

image 2

๐Ÿ–ฅ๏ธ System Requirements

Tested Operating Systems:

  • Ubuntu: 18.04, 20.04 โœ…
  • CentOS: 7, 8 โœ…
  • macOS: Catalina, Big Sur โœ…

โš ๏ธ Important: Virtual environments are not currently supported.

๐Ÿ“‹ Prerequisites

Before you start, make sure you have:

# Ubuntu/Debian systems:
sudo apt update
sudo apt install git make maven groovy python3-venv python3-pip

Also Required:

  • Java Development Kit (JDK): Latest version
  • Python: 3.6.9 or later
  • SQLite: 3.8.3 or later (required for CentOS 7)

๐Ÿš€ Installation Steps

1. Clone the Repository

git clone https://github.com/hyphae/APIS.git
cd APIS

2. Build All Components

make build

This downloads and compiles all necessary software - takes 5-10 minutes

3. Start the System

make run

4. Verify Installation

  • Open http://0.0.0.0:4382/ in your browser
  • You should see the APIS control panel
  • All components should show as "Running" status

๐Ÿ”ง Troubleshooting

If you encounter issues:

  • "Command not found" errors: Install all prerequisites first
  • "make build" or "make run" fails: Open a new terminal and try again
  • Port conflicts: Stop other web servers or restart your computer
  • Permission issues: Check file permissions or try with appropriate privileges

๐Ÿ“– How to Use APIS

๐ŸŽฎ Basic Operations

Start the System:

make run

Monitor System Health:

  • Check component status through the Main Controller interface
  • Monitor energy flow patterns and transaction logs
  • Review system performance metrics in the Service Center

Stop the System:

make stop

โš™๏ธ Configuration

Energy Trading Setup:

  1. Access the web interfaces to modify transaction parameters
  2. Adjust energy trading conditions per time window
  3. Configure battery system preferences and constraints
  4. Set pricing rules and availability schedules

System Monitoring:

  • Real-time energy flow visualization
  • Transaction history and analytics
  • Performance metrics and system health
  • Community-wide energy balance reports

๐ŸŒ Key Benefits

image 4

For Homeowners ๐Ÿ 

  • ๐Ÿ’ฐ Lower Bills: Reduce electricity costs significantly
  • ๐Ÿ”‹ Backup Power: Access community energy when your battery runs low
  • ๐Ÿค– Fully Automatic: Set preferences once, let APIS handle everything
  • ๐Ÿ“ฑ Easy Monitoring: Simple web interface accessible from any device

For Communities ๐Ÿ˜๏ธ

  • ๐ŸŒฑ Environmental Impact: Maximize clean energy use and reduce carbon footprint
  • ๐Ÿ›ก๏ธ Disaster Resilience: Keep power flowing during grid outages and emergencies
  • ๐Ÿ’ผ Economic Benefits: Keep energy money in the community
  • ๐Ÿ  Energy Independence: Reduce reliance on big power companies

For Developers ๐Ÿ‘จโ€๐Ÿ’ป

  • ๐Ÿ”“ Open Source: Free to use and modify under Apache License 2.0
  • ๐Ÿ“š Well Documented: Comprehensive guides and API references
  • ๐Ÿค Active Community: Get help and contribute back
  • โœ… Proven Technology: Already working in real installations worldwide

๐Ÿค Contributing

We welcome contributions from the community! Here's how you can help:

๐ŸŒŸ Ways to Contribute

Even if you're not a programmer:

  • ๐Ÿ“ Improve documentation (fix typos, add examples)
  • ๐Ÿงช Test new features and report bugs
  • ๐Ÿ—ฃ๏ธ Help answer questions in forums
  • ๐Ÿ“ข Share your APIS success stories

If you code:

  • ๐Ÿ› Fix bugs and improve stability
  • โšก Add new features and capabilities
  • ๐Ÿ”ง Create better tools and interfaces
  • ๐Ÿ“Š Improve performance and efficiency

If you're a hardware person:

  • ๐Ÿ”Œ Create drivers for new battery systems
  • โš™๏ธ Design better integration methods
  • ๐Ÿ“ Contribute hardware compatibility guides
  • ๐Ÿ› ๏ธ Help with installation and setup

๐Ÿš€ Getting Started

  1. Fork the Repository: Create your own fork of the APIS project
  2. Create Feature Branch: git checkout -b feature/your-feature-name
  3. Make Changes: Implement your improvements or fixes
  4. Test Thoroughly: Ensure all tests pass and functionality works
  5. Submit Pull Request: Describe your changes and their benefits

๐Ÿ“‹ Contribution Guidelines

  • Follow existing code style and conventions
  • Include comprehensive tests for new features
  • Update documentation for any API changes
  • Provide clear commit messages and PR descriptions

๐Ÿ†˜ Getting Help & Support

๐Ÿ” Self-Service Options

  • ๐Ÿ“– Documentation: Most questions answered in our comprehensive guides
  • ๐Ÿ” GitHub Issues: Search existing problems and solutions
  • ๐Ÿ’ฌ Community Forums: Ask and answer questions with other users

๐Ÿ“ž Direct Support

  • ๐Ÿ› Bug Reports: Create a GitHub issue for bug reports
  • ๐Ÿ’ก Feature Requests: Suggest improvements through GitHub issues
  • ๐Ÿ”’ Security Issues: Contact maintainers directly for sensitive matters

๐Ÿ“„ License & Legal

APIS is released under the Apache License Version 2.0

What this means for you:

  • โœ… Use it for free, forever
  • โœ… Modify it however you want
  • โœ… Use it in commercial products
  • โœ… No fees or royalties
  • โœ… Patent protection included

What you need to do:

  • ๐Ÿ“‹ Include the license notice if you redistribute
  • ๐Ÿ“‹ Note any changes you make
  • ๐Ÿ“‹ That's pretty much it!

See the LICENSE file for all legal details.
See the NOTICE for additional notices.


๐ŸŽฏ What's Next for APIS

๐Ÿ”œ Coming Soon

  • ๐Ÿ“ฑ Mobile App: Control APIS from your smartphone
  • โ˜๏ธ Cloud Integration: Connect with major cloud platforms
  • ๐Ÿค– AI Optimization: Smarter energy trading decisions
  • ๐Ÿ”Œ More Hardware: Support for additional battery brands

๐Ÿš€ Long-Term Vision

  • ๐ŸŒ Global Network: Connect APIS communities worldwide
  • ๐ŸŒฑ Carbon Credits: Automatic environmental impact tracking
  • ๐Ÿ’น Dynamic Pricing: Real-time energy market integration
  • ๐Ÿ‘ฅ Peer Review: Community-driven system improvements

๐Ÿ Ready to Get Started?

image 7

Choose your path:

๐Ÿ  For Homeowners

Try the Quick Start guide above and start saving on your energy bills today!

๐Ÿ‘จโ€๐Ÿ’ป For Developers

Explore the system components and documentation to start building energy applications.

๐Ÿ˜๏ธ For Communities

Set up APIS for your neighborhood and bring energy independence to your community.

๐ŸŽ“ For Researchers

Contribute to the future of distributed energy systems through APIS development and research.


Made with โค๏ธ by the APIS Community - Powering the future, one battery at a time.

About

No description, website, or topics provided.

Resources

License

Code of conduct

Contributing

Stars

Watchers

Forks

Packages

No packages published

Contributors 9