bolagnaise/tesla-amber-syncIntelligent Tesla Powerwall energy management for Australia. Automatically sync with Amber Electric or Flow Power (AEMO wholesale) dynamic pricing, create custom TOU schedules for any provider, and capitalize on AEMO wholesale price spikes to maximize your battery's earning potential.
 and where Tesla Batteries are not natively supported. Automatically monitors AEMO NEM wholesale electricity prices for your region (NSW1, QLD1, VIC1, SA1, TAS1). When prices exceed your configured threshold (e.g., $300/MWh), the system:
Perfect for maximizing revenue during extreme price events! Works seamlessly regardless of your normal Powerwall mode.
Monitoring Frequency: Checks AEMO prices every 1 minute for responsive spike detection.
Prevents paying to export solar during negative pricing periods common with Amber Electric. The system monitors feed-in prices every minute and:
During Negative Prices (≤0c/kWh):
During Positive Prices (>0c/kWh):
Configuration:
This feature is particularly useful with Amber's wholesale pricing to avoid paying to export your solar during oversupply periods.
Prevents your Powerwall from charging from the grid during Amber price spikes. When wholesale prices spike, Tesla may see an arbitrage opportunity and charge from grid - this feature stops that behavior.
The Problem: During price spikes, the Powerwall receives 30-minute averaged forecast prices (~$0.85/kWh) rather than the real-time spike prices ($10-$20/kWh). It doesn't "see" the spike and may decide to charge from grid for later arbitrage.
How It Works:
When Amber reports spikeStatus: 'potential' or 'spike' for a period, buy prices are overridden:
override_buy = max(all_sell_prices) + $1.00
This ensures charging from grid is always unprofitable during spikes - eliminating any arbitrage opportunity.
Example:
During a spike event: Actual import price: $16.48/kWh Actual export price: $14.69/kWh Max export in forecast: $21.29/kWh Without spike protection: Tesla sees forecast: ~$0.85/kWh buy Powerwall thinks: "Charge now, sell later!" Result: Grid charging during $16/kWh spike With spike protection: Override buy: $21.29 + $1.00 = $22.29/kWh Powerwall calculates: $22.29 buy - $21.29 sell = $1.00 LOSS Result: No grid charging
Key Features:
spikeStatus field, not arbitrary thresholdsNote for 30-minute billing customers: If you're on 30-minute billing (not 5-minute), spike prices get averaged out in your bill. This feature is most critical for 5-minute billed customers who pay the full spike price.
Configuration:
Artificially increases export prices sent to Tesla to trigger Powerwall exports at lower price points. This is useful when Amber export prices are in the 20-25c range where Tesla's algorithm may not trigger exports due to its internal hysteresis.
How It Works: The feature adds a configurable offset to export prices and/or sets a minimum floor price, but only during a specified time window (default 5pm-9pm evening peak).
Configuration Options:
| Setting | Description | Default |
|---|---|---|
| Enable Export Price Boost | Toggle the feature on/off | Off |
| Price Offset (c/kWh) | Fixed amount added to all export prices | 0 |
| Minimum Price (c/kWh) | Floor for export prices | 0 |
| Activation Threshold (c/kWh) | Boost only applies if actual price is at or above this value (0 = always apply) | 0 |
| Boost Start Time | When to start applying boost | 17:00 |
| Boost End Time | When to stop applying boost | 21:00 |
Example Calculation:
With offset=5c, min=20c, and threshold=10c: Amber export price: 18c/kWh → 18 >= 10 (threshold), so boost applies → 18 + 5 = 23c (above min, Tesla sees 23c) Amber export price: 12c/kWh → 12 >= 10 (threshold), so boost applies → 12 + 5 = 17c (below min, Tesla sees 20c floor) Amber export price: 5c/kWh → 5 < 10 (below threshold), boost skipped → Tesla sees 5c (unchanged) Amber export price: -3c/kWh → -3 < 10 (below threshold), boost skipped → Tesla sees -3c (unchanged)
Use Cases:
Note: The boosted price is only what Tesla sees for decision-making - you still get paid the actual Amber export rate. This feature tricks the Powerwall into exporting when it otherwise wouldn't.
Configuration:
An experimental feature that forces the Powerwall to immediately recalculate its behavior after receiving new tariff prices.
The Problem: After Tesla Sync uploads a new tariff, the Powerwall may take several minutes to recognize the price changes and adjust its charging/discharging behavior accordingly.
How It Works: After a successful tariff sync, this feature briefly switches the Powerwall to self-consumption mode, waits 5 seconds, then switches back to Time-Based Control (autonomous mode). This mode toggle forces the Powerwall to immediately recalculate its optimal behavior based on the new prices.
Smart Timing: The toggle only triggers when settled/actual prices are synced (at :35/:60 seconds), not on the initial forecast sync (at :00 seconds). This ensures:
Trade-offs:
Configuration:
Full support for Flow Power and other wholesale electricity retailers that pass through AEMO NEM spot prices.
How It Works: AEMO wholesale prices only include the energy cost - they don't include network (DNSP) charges, environmental fees, or GST. Tesla Sync automatically calculates your total retail price using the aemo_to_tariff library.
Configuration:
Select Flow Power as your electricity provider
Choose your NEM Region (QLD1, NSW1, VIC1, SA1)
Select AEMO NEM Wholesale as the price source
Configure your Network Tariff:
Option A: Automatic (Recommended)
Option B: Manual Rates
Finding Your Tariff Code: Look on your electricity bill for the network tariff code. Common examples:
| Distributor | Example Tariffs |
|---|---|
| Energex (QLD) | NTC6900, NTC8400, NTC8500 |
| Ausgrid (NSW) | EA025, EA050, EA116 |
| SA Power Networks | RTOU, RELE |
Flow Power Happy Hour: Export rates during Happy Hour (5:30pm - 7:30pm daily):
Total Price Calculation (Automatic): The aemo_to_tariff library handles all calculations:
Total = AEMO Wholesale + Network Charges + Market Fees + Environmental Levies + GST
Note: When using manual rates, enter all values in cents/kWh. If your tariff shows $0.***/kWh, enter 19.367.
Not using Amber Electric? No problem! Create custom time-of-use schedules for any Australian electricity provider:
Backup and restore your tariff configurations:
Tesla Sync uses sophisticated algorithms to convert Amber Electric's dynamic pricing into Tesla-compatible TOU (Time-of-Use) tariffs:
Amber Electric labels their forecasts using END time convention (e.g., "18:00 forecast" = 17:30-18:00 period), while Tesla uses START time labels (e.g., PERIOD_17_30 = 17:30-18:00). Tesla Sync automatically aligns these conventions so prices match exactly what you see in the Amber app.
Tesla requires a static 24-hour tariff structure, but Tesla Sync makes it "roll" forward:
Example at 2:15 PM:
PERIOD_00_00 → Tomorrow's 00:00 forecast (+9h 45m lookahead) PERIOD_14_00 → Today's 14:30 forecast (+15m lookahead - current) PERIOD_23_30 → Tomorrow's 00:00 forecast (+9h 45m lookahead)
Works anywhere in Australia without configuration:
The system automatically extracts timezone information from Amber's API data, ensuring correct "past vs future" period detection for all locations.
Prices are rounded to 4 decimal places with trailing zeros automatically removed:
0.2014191 → 0.2014 (4 decimals)0.*** → 0.199 (3 decimals, trailing zeros dropped)Every 5 minutes - Perfectly aligned with Amber Electric's forecast update schedule for maximum freshness.
Tesla Sync is available in two deployment options:
Both options require Tesla API access - see Tesla API Options below for setup.
Tesla Sync supports two methods for accessing your Tesla Powerwall. Choose one - you don't need both.
The easiest setup option. Teslemetry is a third-party proxy service for Tesla API.
| Pros | |
|---|---|
| ✅ Simple API key authentication | No OAuth complexity |
| ✅ Works with localhost | No public domain needed |
| ✅ 2-minute setup | Just copy/paste API key |
| ✅ Reliable service | Well-maintained proxy |
Setup:
Direct OAuth access to Tesla's Fleet API. Completely free but requires more setup.
| Pros | Cons |
|---|---|
| ✅ Completely free | ⚠️ Requires OAuth app registration |
| ✅ Direct API access | ⚠️ More setup steps |
| ✅ Built-in Cloudflare Tunnel | |
| ✅ Automatic token refresh |
Setup for Home Assistant:
Setup for Docker:
The easiest way to use Tesla Sync if you're already running Home Assistant.
Install via HACS
[***]IntegrationAdd Integration
Configure
Verify Setup
sensor.current_electricity_pricesensor.solar_powersensor.grid_powersensor.battery_powersensor.home_loadsensor.battery_levelswitch.auto_sync_tou_scheduleThe integration automatically syncs your TOU schedule every 5 minutes (aligned with Amber Electric's forecast updates) when the auto-sync switch is enabled.
How it works:
switch.auto_sync_tou_schedule switch (enabled by default during setup)No automation required! Just leave the switch on and the integration handles everything automatically, just like the Docker version.
You can disable automatic syncing by turning off the switch, and re-enable it anytime.
yaml# Manually sync TOU schedule service: tesla_sync.sync_tou_schedule # Refresh data from Amber and Teslemetry service: tesla_sync.sync_now
These are optional automations for advanced users. Auto-sync is automatic and doesn't require any automations.
Force immediate sync on price spike:
yamlautomation: - alias: "Force TOU Sync on Price Spike" trigger: - platform: state entity_id: sensor.current_electricity_price condition: - condition: numeric_state entity_id: sensor.current_electricity_price above: 0.30 action: - service: tesla_sync.sync_tou_schedule
Disable auto-sync during off-peak hours:
yamlautomation: - alias: "Disable Auto-Sync at Night" trigger: - platform: time at: "23:00:00" action: - service: switch.turn_off target: entity_id: switch.tesla_sync_auto_sync
探索更多轩辕镜像的使用方法,找到最适合您系统的配置方式
通过 Docker 登录认证访问私有仓库
在 Linux 系统配置镜像服务
在 Docker Desktop 配置镜像
Docker Compose 项目配置
Kubernetes 集群配置 Containerd
K3s 轻量级 Kubernetes 镜像加速
在宝塔面板一键配置镜像
Synology 群晖 NAS 配置
飞牛 fnOS 系统配置镜像
极空间 NAS 系统配置服务
爱快 iKuai 路由系统配置
绿联 NAS 系统配置镜像
QNAP 威联通 NAS 配置
Podman 容器引擎配置
HPC 科学计算容器配置
ghcr、Quay、nvcr 等镜像仓库
无需登录使用专属域名
需要其他帮助?请查看我们的 常见问题Docker 镜像访问常见问题解答 或 提交工单
免费版仅支持 Docker Hub 访问,不承诺可用性和速度;专业版支持更多镜像源,保证可用性和稳定速度,提供优先客服响应。
专业版支持 docker.io、gcr.io、ghcr.io、registry.k8s.io、nvcr.io、quay.io、mcr.microsoft.com、docker.elastic.co 等;免费版仅支持 docker.io。
当返回 402 Payment Required 错误时,表示流量已耗尽,需要充值流量包以恢复服务。
通常由 Docker 版本过低导致,需要升级到 20.x 或更高版本以支持 V2 协议。
先检查 Docker 版本,版本过低则升级;版本正常则验证镜像信息是否正确。
使用 docker tag 命令为镜像打上新标签,去掉域名前缀,使镜像名称更简洁。
来自真实用户的反馈,见证轩辕镜像的优质服务