Skip to main content

US Power Grids smart home integration, free and open source

US Power Grids integration for Gladys Assistant

US power grids: NYISO live by zone, and every US grid via the EIA: demand, fuel mix, CO₂.

Live figures of the New York power grid in Gladys, from the public files of NYISO, the operator of the grid of New York State: the real-time price of each price zone, the load, the generation by fuel, the low-carbon share and an estimated CO₂ intensity.

Developed without a New York electricity account, the data being public: feedback welcome. Not affiliated with NYISO.

And every US grid too, through the open data of the EIA (U.S. Energy Information Administration): demand, demand forecast, fuel mix, low-carbon share and estimated CO₂ of ERCOT, PJM, MISO, SPP, CAISO, ISO New England, the Southeast, the Northwest, Florida… hourly, with a free key. Developed without an account at these operators: feedback welcome. Not affiliated with the EIA.

What you get​

  • A New York power grid device: load of the State, estimated CO₂ intensity, low-carbon and renewable shares, the share of each NYISO fuel category, and a one-sentence summary.
  • One device per price zone you follow: its real-time price ($/MWh) and its load.
  • Four scene triggers (price above, price below, negative price, low-carbon share above) and a dashboard widget.
  • With a free EIA key, one device per EIA grid you follow (about seventy balancing authorities and EIA regions): demand, forecast of the hour in progress and peak forecast of the next 24 hours, low-carbon and renewable shares, estimated CO₂, the share of gas, coal, nuclear, wind, solar, hydro and other sources, and the time of the figures.

Prices are wholesale prices of the NYISO real-time market, not your electricity rate: your supplier adds delivery, taxes and its margin. They still show when power is cheap or tight.

Requirements​

  • Gladys 5.3.0 or later.

  • Internet access from Gladys (the files are read on mis.nyiso.com). No account, no key.

  • For the EIA grids only: a free API key, asked on eia.gov/opendata with an e-mail address (no paid account). Without a key, NYISO alone.

Installation​

In Gladys, Integrations → Install from GitHub, then give the address of the repository: https://github.com/guim31/gladys-us-grid.

Configuration​

  1. Price zones to follow: pick your zone(s) among the eleven NYISO load zones (West, Genesee, Central, North, Mohawk Valley, Capital, Hudson Valley, Millwood, Dunwoodie, New York City, Long Island). Utility bills name the zone too; NYISO publishes a map on its site.

  2. Thresholds (optional), for the triggers: high price and low price in $/MWh, low-carbon share in %. Left empty, the trigger stays off.

  3. Language of the names: the language of the feature names (frozen when a device is added), of the summary and of the test message.

  4. Save, then add the devices from the Discovery tab.

  5. EIA (optional): paste the EIA API key, pick the grids to follow through the EIA (the EIA regions first, such as Texas or Southeast, then the operators by name, such as ERCOT, PJM, MISO), save, and add their devices from the Discovery tab.

Devices​

New York power grid​

FeatureUnitNote
New York loadkWthe whole State (Gladys has no MW unit)
CO₂ intensity (estimated)g CO₂/kWhfrom the fuel mix, see below
Low-carbon share%nuclear, hydro, wind, other renewables
Renewable share%hydro, wind, other renewables
Share of each fuel category%dual fuel, natural gas, nuclear, other fossil fuels, other renewables, wind, hydro
Summarytext"16.5 GW used, 54 % low-carbon, …"

The shares are those of the generation inside New York: imports from neighboring grids are not in the NYISO fuel mix.

Price zone​

NYISO <zone> (<letter>): the real-time price of the zone (LBMP, $/MWh, five-minute interval) and the load of the zone (kW).

EIA grid​

<grid> (EIA), one per grid followed:

FeatureUnitNote
DemandkWthe latest hour published
Demand forecast, this hourkWthe EIA day-ahead forecast of the hour in progress
Peak forecast, next 24 hkWthe highest hour of the forecast
CO₂ intensity (estimated)g CO₂/kWhfrom the fuel mix, see below
Low-carbon share%nuclear, hydro, wind, solar, geothermal
Renewable share%hydro, wind, solar, geothermal
Share of each source%natural gas, coal, nuclear, wind, solar, hydro, other
Data time (EIA)text"Demand 11/12, 07:00 · mix 11/12, 01:00" (Gladys time)

Scenes​

The triggers watch the zones you follow. Each fires once per crossing, and re-arms when the value has gone back past the threshold by a margin ($5/MWh for the prices, $1 for a negative price, 2 points for the share): the market crosses a threshold back and forth every five minutes. What is crossed is kept across a restart.

NYISO price above the threshold​

A followed zone rises above the high price threshold. Filter: zones. Variables: zone (NYISO PTID), zone_name, price, threshold.

NYISO price below the threshold​

A followed zone falls below the low price threshold. Same filter and variables.

NYISO negative price​

The price of a followed zone turns negative (too much generation, often wind and hydro at night). Variables: zone, zone_name, price.

New York grid: low-carbon share high​

The low-carbon share rises above its threshold: a good time to run appliances. Variables: low_carbon_share, renewable_share, carbon_intensity, threshold.

For an EIA grid, use the device's own features in a scene ("Low-carbon share above 60 %", then start the washing machine): its figures change once an hour, so a threshold on a feature does not fire again and again.

Dashboard​

New York power grid widget​

The price of a zone (setting, New York City by default, no device needed), the low-carbon share, the estimated CO₂, the load, a 24-hour chart (the zone's price once its device is added, else the CO₂ of the grid device) and the fuel mix as bars. The chart and the mix each have a setting to hide them.

Actions​

Test the connection to NYISO and the EIA reads the prices, the fuel mix and the load now, and answers with the price of your first zone.

Data and limits​

  • Source: NYISO public files, every five minutes: real-time zonal prices, real-time fuel mix, actual load. NYISO times are New York times (EST or EDT); Gladys shows them in its own time zone.
  • The integration reads them every five minutes, only when something uses them (a device, a threshold, the widget): a few megabytes a day, compressed. NYISO states no quota for these public files.
  • A figure older than 30 minutes (price) or one hour (mix, load) is never published: no value rather than a stale one, never a zero.
  • CO₂ intensity is an estimate: each fuel category times its lifecycle emission factor (IPCC 2014 medians, as Electricity Maps uses): 490 g/kWh for gas and dual fuel, 650 for other fossil fuels (oil), 230 for other renewables (mostly biomass), 24 hydro, 12 nuclear, 11 wind. Imports are not counted.
  • EIA grids: Form EIA-930 (Hourly Electric Grid Monitor), API v2 of the EIA. Hourly figures, published one to two hours late for the demand, four to eight hours late for the fuel mix (more for some small authorities): the "Data time" feature says which hour you see. Read once an hour in two grouped requests (demand and mix) for every grid followed, well within the free key's limits. A demand older than 6 hours or a mix older than 24 hours is not published. No price: the EIA publishes no hourly price. Same emission factors as above, plus 820 g/kWh for coal, 45 solar, 38 geothermal, 650 oil, and 700 for "other" (unknown mix); battery and pumped storage are left out (they move energy, they do not produce it).
  • California in real time: the CAISO integration (gladys-caiso). The EIA covers it hourly too.

Troubleshooting​

  • "The NYISO price file cannot be read" on the Configuration screen: NYISO did not answer; the integration retries every five minutes.

  • Nothing in the devices: check that they are added, and use Test the connection to NYISO.

  • Detailed logs: LOG_LEVEL=debug on the integration.

  • "The EIA refuses the API key": check the key pasted in the configuration (the e-mail of the EIA gives it).

  • "The EIA cannot be read": the EIA did not answer, or the key's limit is reached; the integration tries again every hour.

  • An EIA feature without value: that grid does not publish it (a forecast, solar…), or its figures are too old.

Credits​

Data: NYISO (New York Independent System Operator), public market and operations data. Emission factors: IPCC AR5 (2014), via Electricity Maps. Code under the Apache 2.0 license. Not affiliated with NYISO.

EIA grids: U.S. Energy Information Administration, Form EIA-930, public domain. Not affiliated with the EIA.

Configuration settings​

These are the settings US Power Grids asks for in its configuration screen in Gladys.

SettingTypeRequiredDescription
Open data from NYISOsectionNoPublic files of the New York grid operator, no account needed. Prices are wholesale, not your electricity rate. California: see the CAISO integration. Not affiliated with NYISO.
Price zones to followmulti_selectNoOne device per zone: real-time price and load. The price triggers watch these zones.
High price threshold ($/MWh)numberNoFor the "Price above" trigger. Empty: off.
Low price threshold ($/MWh)numberNoFor the "Price below" trigger. Empty: off.
Low-carbon share threshold (%)numberNoFor the "Low-carbon share above" trigger. Empty: off.
Every US grid, through the EIA (optional)sectionNoThe U.S. Energy Information Administration publishes every grid hourly: demand, forecast, fuel mix. Data arrive 1 to 8 hours late, no price. Needs a free key, sent by e-mail. Not affiliated with the EIA.
EIA API keysecretNoEmpty: NYISO only.
Grids to follow through the EIAmulti_selectNoOne device per grid: demand, forecast, fuel mix, low-carbon share, CO₂. EIA regions first, then the grid operators.
Language of the namesselectNoNames of the features (frozen when a device is added), the summary and the trigger messages.

How to install US Power Grids in Gladys​

  1. In Gladys, open Integrations: US Power Grids appears in the catalog, next to the native integrations, with a community badge.
  2. Click Install. Gladys pulls the Docker image (ghcr.io/guim31/gladys-us-grid:1.1.0), starts it in a sandbox isolated from the core, and generates the integration's interface (devices, discovery and configuration).
  3. Open the Configuration screen of the integration, fill in the settings, and save.
  4. You can also install it directly from its repository URL: https://github.com/guim31/gladys-us-grid.

US Power Grids requires Gladys >=5.3.0. The catalog inside Gladys refreshes every hour, so a new version becomes available at most one hour after its release.

Not running Gladys yet? It is free and open source: follow the installation guide to get started.

About external integrations​

US Power Grids is an external integration: a community integration packaged as a Docker container and published on GitHub, that Gladys installs in one click and runs in a sandbox isolated from its core. It is published and maintained by guim31, not by the Gladys core team.

Subscribe to the Gladys Assistant newsletter

A few emails per month about new releases and project news. Sent by Pierre-Gilles Leymarie, founder of the project. Unsubscribe anytime 🙂