Coordinated with Fredrik

Coordinated with Fredrik

Download on the App Store

Coordinated with Fredrik episodes

  • The Hard to Get

    The story everyone tells about energy is about generation. Solar panels, wind turbines, the clean energy race. And that story is true. Wind and solar just overtook fossil fuels in Europe for the first time — 30 percent versus 29 percent. That’s a real milestone.

    But the story I want to tell is about what comes after the generation war is won. Because that war is over. The hardware is cheap. The physics works. We have more clean electricity than we know what to do with.

    The question now — the only question that matters — is whether we can coordinate it.

    The data is stunning

    Ember’s European Electricity Review for 2026 tells a remarkable story. Solar alone hit 369 terawatt-hours in 2025, growing over 20 percent year on year for the fourth straight year. It’s now 13 percent of EU electricity, higher than coal, higher than hydro. Meanwhile, Bloomberg NEF reported stationary storage LFP packs hitting $70 per kilowatt-hour — down 45 percent in a single year and 93 percent cheaper than 2010.

    Generation is abundant. Storage hardware is cheap. The “hard to do” is done.

    But here’s what the same Ember report also shows: gas generation in the EU rose 8 percent in 2025. Despite having more wind and solar than ever. Gas rose because hydro dropped 12 percent due to weather. That pushed the EU power sector’s gas import bill to €32 billion. Sixteen percent higher than the year before.

    Let that sink in. Europe has more clean energy than at any point in history. And it’s still spending €32 billion importing gas to keep the lights on.

    Germany curtailed 9.6 terawatt-hours of wind and solar in 2025 — nearly 4 percent of total output, clean energy generated and then thrown away. Solar curtailment alone rose 97 percent year on year. Spain hit 11 percent curtailment by mid-2025. Sweden recorded 649 negative-price hours in twelve months.

    This is the paradox of abundance. The cheaper energy gets, the more valuable the coordination layer becomes.

    Jevons was right (again)

    William Stanley Jevons observed in 1865 that Watt’s more efficient steam engine didn’t reduce coal consumption — it increased it. Efficiency made coal cheaper, which made it more useful, which drove more demand.

    The same thing is happening with energy. Since 1990, energy efficiency has increased 36 percent globally. Total consumption has increased 63 percent. LEDs are more efficient, so we installed more lights. AI chips are more efficient per computation, so we built more data centers. In Ireland, data centers went from 5 to 21 percent of national electricity consumption.

    For renewables, the dynamic has a twist. Solar and wind produce energy when the physics allows it, not when the grid needs it. Abundance without coordination doesn’t just mean waste. It means you still need the gas plants on standby. You still pay the €32 billion import bill.

    Ember calculated that if batteries had captured roughly one-third of Germany’s curtailed energy, it would have saved €800 million — €613 million in avoided redispatch costs, €219 million in avoided gas generation. The required battery investment? Just €145 million per year over the technology’s lifetime.

    And then the Iberian blackout drove the point home. April 28, 2025: 31 gigawatts disconnected, 47 to 56 million people in the dark, over €1.6 billion in losses. Spain had just 25 to 60 megawatts of installed battery storage against a 500 megawatt target.

    Batteries in buildings

    The EU installed 27.1 gigawatt-hours of new battery storage in 2025 — a 45 percent increase. But look at the breakdown: utility-scale was 55 percent, residential was 36 percent, and commercial & industrial was just 8 percent.

    Eight percent. Despite being the fastest-growing segment with a projected 71 percent CAGR to €4.1 billion by 2028.

    The residential market has clear winners — 1Komma5 in Germany with over 300,000 systems, Sonnen with their virtual power plant. Utility-scale is scaling fast. But the middle? The 50 kW to 2 MW behind-the-meter commercial segment? It’s wide open.

    In the entire Nordic region, there is no single company that combines zero-cost deployment, hardware-agnostic system design, automated multi-market optimization, and end-to-end site coordination for commercial batteries.

    Not Pixii (sells hardware, doesn’t finance it). Not CheckWatt (aggregates, doesn’t deploy). Not ABB (battery-as-a-service, but only UK). Not 1Komma5 (residential, no concrete commercial product).

    This is the biggest gap in European energy infrastructure.

    Financial architecture always comes second — and matters more

    There’s a pattern that repeats in every major infrastructure buildout. The technology creates the asset. Then a financial innovation creates the market that enables scaling.

    Oil. Drake drilled the first well in 1859. For 124 years, oil traded through opaque bilateral contracts. Then in 1983, NYMEX launched crude oil futures. Today they trade over a million contracts daily. But the critical point: futures enabled hedging, hedging enabled reserve-based lending, and lending enabled thousands of independent drillers to develop distributed assets. Without futures, there is no shale revolution.

    Railroads. The US built 190,000 miles of track requiring $10 billion in capital when all US manufacturing assets totaled $6.5 billion. The financial innovation was the first mortgage bond — long-term, convertible, secured by company property. Railroad bonds didn’t just finance railroads. They created the American corporate bond market.

    Telecom. Between 1996 and 2001, $500 billion went into fiber optic cable. When the bubble burst, only 5 percent of the fiber was lit. But the infrastructure survived. Google, Facebook, AWS, and Netflix scaled on overcapacity fiber that bankrupt investors had paid for.

    Bitcoin. Eight years of pure technology: $16 billion market cap. Then CME futures, Coinbase Custody, the first futures ETF, and spot ETFs. Result: $2.5 trillion. Technology alone — $16 billion. Technology plus financial instruments — 156x.

    SolarCity. Their insight wasn’t about panels. By 2010, panels were commodity. The insight was that the bottleneck was financial and operational. Zero dollars down, twenty-year leases. In November 2013, the first solar asset-backed security: $54.4 million, rated BBB+, 4.8 percent. That single deal birthed a $15 billion solar ABS market.

    But SolarCity also shows exactly how the model breaks. Customer acquisition costs spiraled to $6,000 per customer through door-to-door sales. $3.58 billion in debt against $730 million in revenue. Tesla acquired them in what was essentially a rescue.

    The lesson: the technology was table stakes, the financing was transformative, but the customer economics killed it.

    Battery storage for commercial buildings is at exactly this inflection point. The technology is proven. The economics are compelling. No standalone battery ABS has ever been issued. The “SolarCity moment” for batteries belongs to whoever creates the first standardized instrument backed by diversified battery revenue streams.

    Why Sweden, why now

    Something most people don’t know about Swedish commercial buildings: a typical property uses 20 to 35 percent of its grid connection on average. The remaining 65 to 80 percent is capacity the owner pays for every month and never uses.

    Swedish grid fees rose 10.6 percent in 2025 — the largest increase in 30 years. For a commercial property with 500 kW peak demand, demand charges alone run roughly 385,000 SEK per year. The regulator’s revenue cap for 2024-2027 increased roughly 40 percent. Grid companies still have 30 billion SEK in unused revenue headroom. Sweden expects to double electricity consumption by 2045.

    The recent pause on residential capacity tariff rollout doesn’t change this. Commercial demand charges above 63 amps remain fully in effect, the EU Electricity Market Directive still requires capacity-based pricing, and operators who already implemented effekttariffer can keep them.

    And here’s the thing that changes the conversation with property owners: Swedish commercial …



    This is a public episode. If you would like to discuss this with other subscribers or get access to bonus episodes, visit frahlg.substack.com
    55 min
  • The Grid's TCP/IP Moment

    In 1962, a researcher at the RAND Corporation named Paul Baran looked at AT&T’s telephone network and saw something that the people running it could not see. The system worked. It carried every voice call in America. But it was structurally wasteful. Circuit-switched networks reserved entire connections for conversations that used less than 10 percent of available bandwidth. Baran’s idea was to break data into small packets, route them independently, and reassemble them at the other end. He called it packet switching.

    He presented this to AT&T’s engineers multiple times throughout the mid-1960s. They told him he did not understand how voice telecommunications worked.

    They were not stupid people. They were reasoning from the wrong model. They saw analog signals on dedicated lines. Baran saw data that could flow through any available path. The gap was not intelligence. It was architecture.

    I keep coming back to this story because we are living through the same moment in energy. And most of the people running the current system cannot see it.

    The numbers that should change how you think

    In the first half of 2025, the world installed 380 gigawatts of solar. That is 64 percent more than the same period in 2024. To put it bluntly, we deployed more solar in six months than existed on the entire planet as recently as 2017. Eight years of cumulative build-out, compressed into half a year.

    In the US, solar plus storage accounted for 79 percent of all new generating capacity. Not 79 percent of renewables. All capacity.

    Solar panels now cost roughly ten cents per watt. Stationary battery pack prices hit $70 per kilowatt-hour in 2025, a 45 percent drop in a single year. The lowest commercial cell prices are $36/kWh. These are not lab numbers. These are prices at scale.

    The hardware problem is solved. Panels are close to free compared to a decade ago. Batteries are following the same curve with a few years of delay. Deployment keeps outrunning every forecast the IEA publishes. This is not a story about scarcity. This is a story about abundance.

    But here is the part nobody wants to say out loud: we are wasting enormous amounts of this perfectly good electricity.

    Abundance without coordination is just waste

    California curtailed 3.4 million megawatt-hours of renewable energy in 2024. Ninety-three percent of that was solar. Germany set a new record of 1,750 GWh curtailed in 2025, with 575 hours where the wholesale price went negative. Generators paying someone to take their electricity.

    Spain’s solar capture prices collapsed from €61/MWh to under €17. The Netherlands posted 584 hours of negative prices, the most in Europe. Australia curtailed over 7 TWh. In South Australia, 38 percent of all utility-scale solar generation was thrown away.

    Across Europe, managing these surpluses cost utilities an estimated €4.3 billion in 2024. Globally, curtailment hit 72 TWh. That is roughly Austria’s entire annual electricity consumption. Gone.

    We spent billions deploying all this capacity. Then we pay people not to use the electricity it produces. That is not a generation problem. That is a coordination problem. And it is getting worse every month as more solar comes online.

    The pattern that keeps repeating

    The Baran story is not unique. The same structural shift has played out in shipping and in software platforms.

    In 1956, Malcolm McLean loaded 58 aluminum truck bodies onto a converted tanker ship in Newark. The shipping container was born. Loading costs dropped from $6 per ton to 16 cents. A 36x reduction. But the container itself was just a steel box. The revolution was the standardization: the standard size, locking mechanisms, and handling equipment. The coordination protocol that let any container from any shipper load onto any ship and transfer to any truck. A longshoremen’s union official watching McLean’s first container ship depart reportedly said he would like to sink that son of a b***h. The incumbents always react the same way.

    Apple launched the App Store in July 2008 with 500 apps. It hit 10 million downloads in 72 hours. Within a few years it was facilitating over a trillion dollars in commerce. Apple did not build the apps. They built the platform layer: the APIs, the SDKs, the payment infrastructure, the discovery mechanism that turned millions of individual devices into a coordinated ecosystem.

    The meta-pattern is always the same. A distributed resource exists but is uncoordinated. Incumbents dismiss it. A standardized coordination layer emerges. The economics flip. And an outsider, not an industry insider, drives the change.

    TCP/IP captured more value than any individual computer. The App Store captured more value than any individual app. The ISO container standard transformed more wealth than any individual shipping company.

    The coordination layer always wins.

    Virtual power plants are not a pilot anymore

    During California’s July 2025 grid stress test, over 100,000 home batteries delivered an average of 535 megawatts to the grid during the evening peak. The Brattle Group verified the results and concluded that the output was indistinguishable from dispatching a gas peaker plant. Grid operators could not tell the difference between 100,000 batteries coordinated by software and a single gas turbine.

    EnergyHub has introduced what they call the Huels Test, essentially a Turing Test for energy. Can a grid operator distinguish a VPP dispatch signal from a gas peaker? In trials with Arizona Public Service, Duke Energy, and National Grid, virtual power plants passed. Level 3. Automated and indistinguishable.

    The scale is already real. North American VPP capacity reached 37.5 GW in mid-2025. Octopus Energy’s Kraken platform manages 2 GW from over 500,000 connected devices. Kraken spun out as an independent company at a €7.3 billion valuation. Tesla’s Autobidder orchestrates over 3 GW across energy, capacity, and ancillary service markets. Base Power, a Texas startup, raised $1 billion and is installing 20 MW per month, targeting 100 MW per month by mid-2026.

    A 400 MW virtual power plant costs $43 per kilowatt-year. A gas peaker costs $99. Less than half. The DOE verified those numbers.

    Meanwhile, the United States has 2,600 GW of clean energy stuck in interconnection queues. That is more than twice total installed US generating capacity. Just waiting. Only 14 percent of solar projects that enter those queues ever get built. The average wait time in PJM is eight years.

    Eight years to connect a solar farm to the grid. Versus three years to build a 700 MW virtual power plant from home batteries. The distributed path does not compete with the centralized path. It laps it.

    The physics gap

    The classic grid was built for central control of big generators. Now we have millions of distributed devices at the edge. An inverter speaks Modbus RTU. An EV charger uses OCPP. A heat pump might use Modbus TCP or some proprietary protocol. A smart meter outputs a P1 port stream. Different devices, different languages, no common protocol.

    And the control requirements are brutal. Grid services like frequency response and voltage regulation need feedback on 100-millisecond to one-second timescales. Existing cloud-based interfaces have latencies of two to thirty seconds. There is no execution layer between cloud platforms and physical devices. The gap between what the cloud can do and what the grid actually needs is not a software bug. It is physics.

    Generation is no longer the bottleneck. Control is. We have the energy. We have the devices. What we do not have is the real-time, protocol-agnostic, edge-native intelligence layer that makes them work together at grid speed.

    Why we build from the Nordics

    Sourceful Energy is based in Kalmar, a small city on Sweden’s southeast coast. Not exactly famous for sunshine. But the Nordics have some of the most modern electricity grids in the world. Norway has 93 percent of residential contracts on dynamic tariffs. Finland is at 30 percent. Denmark has approved vehicle-to-grid aggregat…



    This is a public episode. If you would like to discuss this with other subscribers or get access to bonus episodes, visit frahlg.substack.com
    28 min
  • The Mess Is the Moat

    I recorded a podcast episode this week that I’ve been turning over in my head for months. It’s about where Sourceful is right now, what we’ve built, and why I think the next few months matter more than anything we’ve done so far. If you have the time, go listen. But if you want the written version, here it is.

    The clean problem and the dirty one

    Most energy tech companies pick a clean problem. They build monitoring dashboards. Analytics platforms. Pretty graphs sitting on top of someone else’s data. The physical world — the actual devices, the actual protocols, the actual hardware that lies about its own state — that’s always conveniently left to someone else.

    We went the other way. Sourceful has always been about the physical layer. Talking to actual devices. Sending actual commands. Getting actual confirmations that hardware did what it was told to do.

    This is an ugly problem. Every manufacturer implements protocols differently. Firmware updates silently change behavior. Documentation doesn’t match reality. The same device model bought two years apart can have different register maps. Nothing is clean. Nothing is standardized. Everything is edge cases stacked on top of edge cases.

    We chose this on purpose.

    What the grid actually needs

    There’s a fundamental misunderstanding in energy tech about what “smart grid” means. Most people hear it and think monitoring. Data collection. Visibility.

    That’s table stakes. Visibility is not a product. The product is control.

    A utility needs to curtail 40 MW of solar generation in under a second. An aggregator needs to simultaneously discharge two thousand home batteries to meet a frequency regulation bid. A grid operator needs to shift ten thousand heat pumps off-peak — right now — and know with certainty that it happened.

    Deterministic, real-time control of physical hardware. That’s what the flexibility markets pay for. That’s what grid operators need. That’s the product.

    And that product requires solving the integration problem at the device level. There’s no shortcut. There’s no abstraction layer that makes the physical world go away. Someone has to write the driver that talks to each specific device, handles its specific quirks, and confirms that commands were executed correctly.

    Why cloud coordination is a dead end

    I keep seeing well-funded startups building cloud-first coordination platforms. Some of them are smart. Most of them will fail. Not because the teams are bad — because the architecture is wrong.

    Cloud API round-trips take two to five seconds. Grid frequency balances every second. This isn’t a performance gap you can close with better infrastructure. It’s a physics problem. If your control logic lives in someone’s data center, you are structurally unable to participate in the energy markets that pay the most: frequency containment reserves, fast demand response, sub-second optimization.

    These markets require local execution. The coordination logic has to run on the same network as the device. At the edge. In the building. Next to the hardware.

    You cannot retrofit local execution onto a cloud architecture. The entire system has to be designed for it from the ground up. Most teams don’t realize this until they’ve already built the wrong thing and hit the ceiling.

    We started local. That decision — made before it was fashionable, before “edge computing” was a buzzword in energy — is now an architectural advantage that can’t be replicated without starting over.

    What we’ve been doing for the last six months

    I want to be honest about the journey, because the honest version is more instructive than the polished one.

    We didn’t start from first principles. We started the way startups start — shipping fast, accumulating debt, building what worked rather than what was architecturally right. That’s fine for finding product-market fit. It’s not fine for building infrastructure the grid depends on.

    The last six months have been about stripping back to first principles. Rearchitecting the entire backend. Killing legacy code paths. Rebuilding the foundation from the physics up. We shipped NovaCore — not a feature, a new foundation — in the last two months. The identity system. The control pipeline. The telemetry infrastructure. All redesigned around how the grid actually works.

    That work is done. The foundation is solid. And it earned us the right to tackle the hard part properly.

    AI-first integration: the 10x and 10x

    Here’s the thing that changes everything for us.

    We’ve built an AI-first integration engine — we call it Hugin — that can point at an unknown energy device, scan it, figure out how it communicates, cross-reference our existing driver library, and produce a working, tested driver. In minutes.

    The industry standard is weeks per device brand. One engineer, one brand, reverse engineering and manual testing. We’ve lived this. We have about thirteen OEM integrations today. The market has hundreds of brands. At the old pace, nobody wins.

    With AI-driven integration, the first device is roughly 10x faster than manual development. By the fifteenth integration, the AI has seen enough devices from the same manufacturers to recognize patterns — it already understands 80% of a new device before it starts. By the fiftieth integration, it’s 10x faster again. That’s 100x the pace of anyone still hand-coding drivers.

    And the curve doesn’t flatten. It steepens. Every driver teaches the AI about the next one. Every edge case gets encoded into the knowledge base. The messy physical world that everyone else avoids is literally the training data that makes our system smarter.

    A new partner needs fifteen device brands supported? Today that’s months. With this platform at scale, it’s a day.

    The people with skin in the game

    Here’s what most platforms get wrong about scaling integration. They treat it as an internal engineering problem. Hire more developers. Grind through the backlog. Even with AI, that’s still one company trying to cover an entire industry.

    What scales is when the people who need an integration the most are the ones building it.

    Who cares whether a specific inverter model works with Sourceful? The person who owns that inverter. The homeowner with the device in their garage. The electrician who installs that brand every week. These people have the hardware physically in front of them. They can plug in and run a probe.

    With AI-first tooling, they don’t need to be protocol engineers. They point the tool at their device, supervise the process, review the output, and submit a driver. That driver gets reviewed, signed, and distributed. Every Sourceful gateway in the world that encounters the same device model now has a working integration.

    One person solved their own problem. The entire network got smarter.

    The driver library grows faster than any internal team could build it. Coverage expands into regional brands and legacy models that no company would prioritize on a product roadmap. And we have the infrastructure to reward contributors when the time is right — we know who contributed what, how widely it’s used, and what revenue flows through it. We’re not building the incentive model today. But the pipes are ready.

    Four moats that compound each other

    I think most people in energy tech define moats wrong. A moat isn’t a feature or a patent or being first. A moat is something that gets stronger the more you use it, and that competitors can’t replicate without going through the same painful process.

    We have four, and they reinforce each other.

    The driver library. Every validated, production-tested driver represents real-world knowledge about how a device actually behaves — not how the documentation says it behaves. You can’t generate this from a spec sheet. You get it by connecting to real hardware in real installations. Every driver is a brick in a wall that competitors have to build from scratch.

    The AI knowledge base. Every integration teaches the system about the next one. The compounding curve is structural, not aspirational. A competitor starting …



    This is a public episode. If you would like to discuss this with other subscribers or get access to bonus episodes, visit frahlg.substack.com
    24 min
  • The Thesis

    Before we begin, I want to be upfront about something.

    The voice in this episode is mine, but it’s AI-generated.

    I cloned my voice using ElevenLabs, and the entire episode was produced that way. I think it’s important to be transparent about that. The words are mine. The ideas are mine. The delivery is artificial.

    That feels like a fitting place to start, because a big part of what I want to talk about is exactly that tension: how technology should be used as a tool, not as a replacement for what is real.

    This post is the written version of something deeper than a company update. It is not the pitch version. Not the investor version. This is the real version — what I actually believe, why I believe it, and what I’m asking of the people building with me.

    But first, something important.

    I did not start this company alone. I started it with my co-founders. This has always been about the team. I take my role as CEO extremely seriously, and I do everything I can to earn that position every day. But I would never pretend this is a one-man show. It isn’t. The reason we have something worth talking about is because a group of people decided to build it together.

    Some of you reading this are part of that team. Some of you are following from the outside. Either way, I want to be straight with you, because I think that is the only way any of this works.

    And to understand where we are going, you need to understand where this started.

    A kid in Småland

    I grew up in Åseda, a small town in Småland.

    If you know anything about Småland, you know it tends to produce stubborn people. People who do not quit easily. That matters more than it might seem.

    Even as a kid, I had a certain way of disappearing into things. My first-grade teacher told my parents that I was often somewhere else in my mind. Back then they called it daydreaming. It did not feel like daydreaming to me. It felt like locking in. When I got interested in something, everything else disappeared.

    That trait has followed me my whole life. On some days it is a superpower. On other days it is a curse.

    Very early on, I wanted to understand how things worked. I tinkered with hardware, took computers apart, put them back together, built machines from parts. I was not of the C64 generation. I started with a 286 PC running MS-DOS. From that point on, I was hooked.

    I read everything I could get my hands on — Tolkien, Asimov, anything that expanded the world. I was deep into RPGs, tabletop games, worldbuilding, systems. I wrote text-based games in QBasic and spent absurd amounts of time optimizing memory just to make them run. Back then, 640 kilobytes was supposed to be enough for everyone. It rarely felt like enough.

    What all of that taught me, early, was simple: systems have rules. If you understand the rules, you can make systems do what you want.

    That is still basically what I do for a living.

    By the age of eleven, I had set up a bulletin board system in my room called The Heart of Gold, named after the ship in The Hitchhiker’s Guide to the Galaxy. This was 1991. I was connecting with people over phone lines, learning how networks worked before I fully understood what a network even was. FidoNet. The proto-internet before the internet. I still remember the sound of a 2400 baud modem connecting.

    I was also part of the wares scene. The pirating movement. Cracking and distributing software. It was not legal, and I am not trying to romanticize it. But it taught me things school never did: how communities self-organize, how information flows, how systems that try too hard to close themselves eventually get routed around.

    By my mid-teens I was running Linux Slackware and compiling my own kernels. Not casually. Obsessively. Learning what each module did, what belonged, what did not, how the full system fit together. That bottom-up systems thinking never left me.

    And that is where Sourceful really comes from. Not from a business plan. Not from a market map. It comes from a kid in Småland who built PCs, ran a BBS, compiled kernels, and never stopped wanting to understand how systems work.

    Systems under pressure

    The Navy was where systems thinking stopped being theoretical.

    I started on fast attack craft with gas turbine propulsion. Raw speed. Raw power. In that environment, you are responsible for the whole system, not just one part of it. If something fails, you cannot call support. You cannot Google it. You fix it, or you have a serious problem.

    Later I moved to submarines with electric battery propulsion. A completely different environment — quieter, more confined, slower in some ways, but under even greater pressure. Weeks underwater. No help coming. The same principle applied: if you do not understand the full system, you are a liability.

    That shaped me profoundly.

    As a marine engineer, you learn that nothing exists in isolation. The electrical system affects propulsion. Propulsion affects cooling. Cooling affects air systems. Everything touches everything else. If you only understand a component but not the system, you are dangerous.

    And then there is the human side. Rough conditions. Broken sleep. Tight spaces. Stress. You learn to lead tired people in environments where mistakes have immediate physical consequences. In the Navy, the commanding officer stands in what we call the windshield — the position where the impact hits first.

    That idea stayed with me.

    That is how I think about leadership. When you are in the windshield, you do not get to have an off day. You do not get to be unprepared. The people around you depend on you being sharp, present, and honest about what you see and what you do not see.

    First principles or nothing

    After the Navy and a short period as a project leader, I did something that surprised a lot of people: I went into teaching.

    I became an adjunkt, teaching marine engineers subjects like pumping technology and hydromechanics. And that is where I really fell in love with first principles.

    I would stand at the whiteboard and derive SI units from scratch. No shortcuts. No hand-waving. I wanted students to understand where formulas came from, not just memorize them. I would spend so much time writing that I would lose my voice and wear out my arm.

    That period shaped how I think about everything.

    If you cannot derive it, you do not understand it. If you do not understand it, you cannot build on it.

    For a lot of people, “first principles” is a buzzword. For me, it is literal. It is years of standing at a whiteboard, reducing ideas to fundamentals until there is nowhere left to hide.

    That mindset later led me into a PhD, where I spent years studying how to optimize ship energy systems using machine learning. A PhD requires a specific kind of lock-in. But more than that, it taught me something about teamwork. Academic work is collaborative, but the thesis is still yours to defend. You build with others, but you also carry something alone.

    During that work, I encountered an idea that changed my worldview: Jevons paradox.

    William Stanley Jevons observed in 1865 that when coal became more efficient to use, people did not use less coal. They used more. Efficiency lowered cost. Lower cost increased accessibility. Increased accessibility increased demand.

    That realization broke my brain in the best possible way.

    Before that, I held a more traditional environmentalist mindset: conserve, reduce, use less. Jevons forced me to see that this framing was not morally wrong, but mechanically wrong. The path forward is not austerity. It is abundance. The way to outcompete fossil fuels is to make clean energy so cheap, so scalable, and so abundant that it wins on economics.

    That was a major shift for me. I stopped being a conservationist in the traditional sense and became something closer to an accelerationist — not the reckless kind, but the kind that believes we solve the climate problem by building overwhelming clean energy capacity.

    That insight became the seed of Sourceful.

    The real problem: coordination

    But abundance alone is not enough.

    You can pu…



    This is a public episode. If you would like to discuss this with other subscribers or get access to bonus episodes, visit frahlg.substack.com
    24 min
  • The Grid’s Missing Router: Why Software, Not Hardware, Will Save the Energy Transition

    Picture a spectacularly beautiful, cloudless spring day in California. Millions of solar panels across the state are operating at peak efficiency, churning out massive amounts of clean, zero-marginal-cost electricity. But behind the scenes, grid operators are frantically hitting the kill switch. They are actively disconnecting solar farms and shoving millions of dollars worth of pure energy straight into the dirt.

    Why? Because the power has nowhere to go. The electrical grid has no brain to route it, and no way to store it for when the sun goes down.

    In this episode of the podcast, we do a deep dive into the defining engineering challenge of our time. We explore why the greatest energy transition in human history isn’t bottlenecked by the physical hardware we put on roofs, but by the invisible information layer—the software—required to orchestrate it.

    Here are the core themes we unpack in the episode:

    1. The Hardware War is Already Over (And We Won)

    For decades, the systemic bottleneck of the grid was the sheer cost of generating power. That era is officially over. The manufacturing of solar panels and batteries has scaled so aggressively that the physical components are now effectively commoditized.

    * In just the first half of 2025, the world installed 380 gigawatts of solar capacity—the equivalent of 380 massive nuclear reactors.

    * Solar module prices have plummeted to a global average of roughly $0.10 per watt.

    * Stationary lithium-ion battery pack prices collapsed by 45% in a single 12-month period, hitting an astonishing $70 per kilowatt-hour.

    * Raw cell prices for Lithium Iron Phosphate (LFP) chemistry—the safest and most dominant chemistry for stationary storage—have dropped to just $36 per kilowatt-hour.

    2. The Symptoms of a “Dumb” Grid

    Because energy generation has become cheap and abundant, we’ve completely inverted the bottleneck. It is now entirely about system coordination. When you generate electricity, it must be consumed or stored the exact millisecond it is created. If the grid can’t handle it, operators are forced to curtail (throw away) the power to prevent the system from physically melting down.

    * In 2024, California curtailed 3.4 million megawatt-hours of renewable energy (93% of which was solar).

    * In the first part of 2025, Germany curtailed a record 1,750 gigawatt-hours and experienced 575 hours of negative day-ahead prices.

    * In Spain, solar capture prices collapsed from €61 to just €16.80 per megawatt-hour.

    This creates a self-reinforcing cycle of grid stress. The cheap solar drives new demand (a classic example of the Jevons Paradox, first observed in 1865), particularly from power-hungry AI data centers that demand 24/7 reliability.

    3. A Tale of Two Blueprints

    How do we solve this? The industry is currently split between two radically different architectural philosophies:

    The Centralized approach (The Mainframe): This is the top-down, massive infrastructure method. A prime example is the landmark project underway in Abu Dhabi spearheaded by Masdar. They are pairing a colossal 5.2-gigawatt solar plant with a 19-gigawatt-hour battery system. The goal is to use advanced “grid-forming inverters” to make intermittent solar behave exactly like a reliable, baseload nuclear plant.

    The Decentralized approach (The Internet):

    This is the bottom-up approach, relying on Distributed Energy Resources (DERs). This involves aggregating hundreds of thousands of small, distributed assets—like residential batteries, smart thermostats, and EV chargers—into massive “Virtual Power Plants”. We discuss movements like DePINs (Decentralized Physical Infrastructure Networks) and how protocols use cryptographic tokens to incentivize hardware deployment.

    4. The ZAP Gateway & The Path Forward

    To make the decentralized model work without causing physical blackouts, we need a universal translator at the edge of the network. In the episode, we discuss the “ZAP gateway”. This is a sub-€100 piece of hardware, built on the ESP32-C3 chipset, that acts as the physical bridge between chaotic software commands and fragile local grid hardware. It uses “controls forward design” to ensure that even if the internet goes down, the local battery safely manages its own limits without relying on a centralized cloud brain.

    5. The Regulatory Slog

    Finally, we touch on the painful reality of policy. While the software and hardware are ready today, regulatory frameworks are dragging their feet. In the US, FERC Order 2222 (which mandates that distributed energy can compete in wholesale markets) faces implementations delayed to 2028 or even 2030 by major grid operators. The EU faces similar sluggishness with Directive 2019/944.

    We have millions of the world’s fastest computers, but we are still trying to invent the router to connect them all together. That is the mission.

    🎧 Listen to the full episode now to hear the complete breakdown. Let me know your thoughts in the comments below—are we moving fast enough, or will the regulations keep us in the dark ages?

    — Fredrik



    This is a public episode. If you would like to discuss this with other subscribers or get access to bonus episodes, visit frahlg.substack.com
    53 min
  • 071 - Measure What Matters

    It’s fall 1999. A venture capitalist named John Doerr walks into a cramped office in Mountain View — thirty employees gathered around a ping-pong table that doubles as a boardroom. The company is called Google, and it’s the eighteenth search engine to arrive on the web. Doerr carries an $11.8 million check in one hand and a management system in the other. The check made Google possible. The management system made Google Google.

    This episode is a deep dive into that system — Objectives and Key Results — and the book that lays it all out: John Doerr’s Measure What Matters.

    What Are OKRs, Really?

    The story starts at Intel in the 1970s. Andy Grove, the legendary CEO, was staring at a crisis: the Japanese semiconductor industry was about to eat Intel alive. Grove needed every single person in the company to understand the mission and execute on it — fast. His answer was a deceptively simple framework. An Objective is what you want to achieve. Key Results are how you’ll know you’ve achieved it. That’s it.

    But the magic isn’t in the framework. It’s in what happens when you make everyone’s goals visible — from the newest intern to the CEO. Grove’s quote haunts the entire book: “There are so many people working so hard... and achieving so little.”

    The Four Superpowers

    Doerr identifies four things that OKRs unlock, and we spend most of the episode working through each one with real stories:

    Focus. Brett Kopf built Remind, an education app, but the company was drowning — trying to do everything at once. OKRs forced them to say no. They picked three objectives and killed everything else. The company survived.

    Alignment. MyFitnessPal grew to 100 million users with a tiny team. How? Everyone’s OKRs were transparent and cascaded from a single mission. No one wondered what they should be working on.

    Tracking. Bill Gates brought OKRs to the Gates Foundation to track something most organizations struggle to measure: progress against malaria deaths. You can only improve what you measure.

    Stretch. YouTube set a goal of one billion hours of watch time per day. They were at 100 million. That’s a 10x target — the kind of number that makes you stare at a whiteboard and question your sanity. They hit it.

    Beyond Goals: The Death of the Annual Review

    The second half of the book — and the episode — tackles something less glamorous but arguably more important: Continuous Feedback and Recognition (CFRs). Annual performance reviews are broken. A doctor changes a treatment protocol in January and doesn’t see outcome data until December. A software engineer ships a feature and gets feedback six months later. CFRs replace this with continuous, lightweight conversations.

    The examples from Zume Pizza and Lumeris (a healthcare company where lives are literally at stake) make the case that faster feedback loops aren’t just nicer — they’re a requirement when the world moves fast.

    OKRs as Coordination Infrastructure

    Here’s where I get personal. I run an energy infrastructure company. Every day I think about the same problem Andy Grove faced at Intel: how do you get thousands of distributed actors — solar panels, batteries, EVs, heat pumps — to coordinate toward a shared objective?

    The energy grid must balance supply and demand every single second. It’s a coordination problem at continental scale. And the answer, I think, starts with something Grove figured out in a semiconductor factory fifty-five years ago. Not more generation. Not bigger wires. Shared objectives with measurable key results, propagated across every node in the network.

    Measure what matters.

    Key Takeaways

    * OKRs are not a goal-setting exercise — they’re a coordination protocol for organizations (and systems) of any size

    * The four superpowers — Focus, Alignment, Tracking, Stretch — compound on each other

    * Transparency is the mechanism: when everyone can see everyone else’s goals, alignment happens organically

    * Stretch goals (10x, not 10%) change how people think about problems, not just how hard they work

    * Annual reviews are dead — continuous feedback is the faster loop that modern systems require

    * Coordination infrastructure — whether for companies or energy grids — requires shared, measurable objectives

    Behind the Scenes: A New Format

    This episode is an experiment. It’s the first episode of Coordinatedproduced in what I’m calling the Radiolab format — a multi-voice, multi-track production that feels closer to audio documentary than traditional podcasting.

    Instead of a solo monologue, this episode features four voice layers:

    * Daniel — the primary host, driving the narrative with a steady British broadcaster voice

    * Matilda — the co-host and audience proxy, bringing energy and genuine reactions

    * Fredrik (narrator) — stepping in for authoritative narration and synthesis

    * Fredrik (expert) — the same voice but with a “tape” EQ filter, used for quoting Doerr, Grove, and other real people. It creates the feel of archival audio.

    How It Was Built

    The entire production pipeline is automated — from book to finished episode. Here’s what happens under the hood:

    Pass 1 — The Episode Bible. The full text of Measure What Matters(~72,000 words) is split into 21 chapters. Each chapter is fed individually to Claude Opus, which extracts the most compelling stories, quotes, and emotional beats. The result is a ~28,000-word “episode bible” — a structured research document.

    Pass 2 — Script Generation. The bible is fed back to Claude in five separate passes (one per ACT), each with specific creative direction: the hook, the superpowers (split across two passes), the revolution, and the synthesis. Claude generates a structured JSON script with 458 segments, each tagged with speaker, production cues, and timing.

    Production Cues. Every segment carries metadata that controls the final mix: - Stereo panning — Daniel sits slightly left, Matilda slightly right, narrator centered - Tail-stepping — some reactions start 150-300ms before the previous line ends, creating that signature Radiolab crosstalk energy - Hard cuts — four moments in the episode where ALL sound drops to pure silence before a key revelation - Music beds— four mood tracks (tension, uplifting, contemplative, energetic) scored under narration sections - EQ presets — expert quotes get a “tape” filter (300-4000Hz bandpass) that makes them sound like archival recordings

    Audio Generation. All 458 segments are rendered through ElevenLabs’ text-to-speech API, each with per-voice model selection and tuned voice settings. The stems are then assembled on a timeline — not sequentially concatenated — with overlaps, fades, panning, and music beds mixed in.

    Mastering. The raw mix goes through dynamic range compression and two-pass loudness normalization to -16 LUFS (the podcast standard for Spotify and Apple Podcasts).

    The result: 75 minutes of produced audio from a single text file input. The entire pipeline — from book to finished MP3 — runs with one command.

    I’m excited to keep iterating on this format. The bones are there. Now it’s about tuning the voices, the pacing, and the music to make it feel less like AI and more like radio.

    Full transcript available below the audio player.



    This is a public episode. If you would like to discuss this with other subscribers or get access to bonus episodes, visit frahlg.substack.com
    1 hr 15 min
  • 070- Boil the Ocean

    In February 2026, Y Combinator CEO Garry Tan published a short essay arguing that “don’t boil the ocean” — the most common piece of startup advice — is now obsolete. His reasoning rests on a chain of ideas stretching back 160 years, through a Victorian economist, a radical architect, and two professors betting on the price of tin. I followed that chain. It changed how I think about everything.

    The Paradox That Triggered a Coal Panic

    In 1865, a 29-year-old English logician named William Stanley Jevons published The Coal Question. His central observation was so counterintuitive that economists are still debating it 160 years later:

    “It is wholly a confusion of ideas to suppose that the economical use of fuel is equivalent to a diminished consumption. The very contrary is the truth.”

    Making fuel more efficient does not reduce consumption. James Watt’s steam engine used 75% less coal than the Newcomen engine for the same work. And yet British coal production grew 3.5% per year for 80 straight years — from 5.2 million tons in 1750 to 292 million tons at peak in 1913. A 56-fold increase.

    Watt’s engine didn’t conserve coal. It made coal-powered work so cheap that steam engines migrated from mine pumps to cotton mills to railways to steamships. Every new application that became economically viable created demand that overwhelmed the efficiency gains.

    This is the Jevons Paradox. And it has repeated with eerie precision wherever a fundamental resource has gotten dramatically cheaper.

    14,000x Cheaper Light, 6,500x More Consumption

    Economist William Nordhaus traced the cost of artificial light from the 1300s to the present. One million lumen-hours cost the equivalent of £40,800 in the 1300s. By 2006: £2.90. A 14,000-fold decline.

    Did humanity respond by consuming the same amount of light? The average UK resident in 2000 consumed 6,500 times more artificial light than in 1800. Computing tells the same story — cost per gigaflop dropped from $18.7 million in 1984 to three cents in 2017. Total compute consumed went up by orders of magnitude. Storage, communication, bandwidth — same pattern, every time.

    The cheaper the resource, the more we consume. As long as human desire for it is elastic, Jevons holds.

    Fuller’s Arc: From Stone to Nothing

    While economists debated the paradox, Buckminster Fuller was watching the same phenomenon through a different lens. He called it “ephemeralization” — doing more and more with less and less until eventually you can do everything with nothing.

    Stone arches. Iron trusses. Steel cables. Wireless signals. Each generation of bridge required less material. But the number of connections, the volume of communication, the scope of what bridges enabled — that exploded beyond imagination.

    Fuller and Jevons aren’t contradictions. They’re two sides of the same process. We do more with less of this specific thing (Fuller’s insight), which makes the underlying capability so cheap that we consume vastly more of it (Jevons’ insight).

    The Ehrlich-Simon Bet

    In 1980, Stanford’s Paul Ehrlich — who predicted hundreds of millions would starve in the 1970s — bet economist Julian Simon $1,000 that five metals would rise in inflation-adjusted price over ten years. Ehrlich picked chromium, copper, nickel, tin, and tungsten.

    All five declined. Tin fell 55%. Tungsten dropped over 60%. The $1,000 basket was worth $423.93 by 1990 — despite world population growing by 800 million, the largest single-decade increase in human history. Scarcity incentivized innovation, substitution, and new discoveries. Ehrlich mailed a check for $576.07 and never bet on resource prices again.

    Intelligence Is Collapsing Faster Than Anything Before It

    Now there’s a resource collapsing in cost that makes coal, light, and metals look like gentle declines. That resource is intelligence.

    Epoch AI found that LLM inference prices are falling between 9x and 900x per year, with a median of 50x. Since January 2024, that accelerated to 200x per year. GPT-3.5-level performance dropped 280-fold in cost — from $20 per million tokens to 7 cents — in two years.

    And here’s the Jevons effect in real time: despite per-token costs falling 280x, total inference spending grew 320% over the same period. Researchers found super-elastic demand — a 1% price decrease drives a 1.42% volume increase. Price times quantity riseseven as price falls. Demand for intelligence is, in the paper’s language, “currently un-satiated.”

    No previous resource — not coal, not electricity, not computation — has become cheap this fast.

    This Is Personal

    I spend every day thinking about what happens when energy becomes the bottleneck. When intelligence is cheap but you need electricity to run it. When every home has solar and batteries and heat pumps and EVs, but nobody has figured out how to coordinate them.

    Germany had 457 hours of negative electricity prices in 2024. Generators paying people to take their power. Jevons would have recognized it instantly — we made electricity generation incredibly efficient, and demand exploded into categories nobody anticipated: data centers, EVs, heat pumps, AI inference clusters drawing megawatts.

    Tan’s essay distinguishes two responses to this moment. The zero-sum response: use AI to do the same thing cheaper, cut headcount, eke out 5% efficiency gains. The positive-sum response: attempt things that were previously impossible.

    Applied to the energy grid — the zero-sum response is building more solar panels and bigger batteries. Throwing hardware at the problem. The positive-sum response is asking: what if every home was a power plant? What if every battery was a grid asset? What if every EV was a node in a distributed network that could balance the grid in 200 milliseconds, from the edge, locally?

    The Ocean Is Already Boiling

    If Jevons is right — and 160 years of evidence says he is — the demand response to near-free intelligence will be proportionally extraordinary. The organizations and founders who raise their ambitions rather than protect their incumbency will define the next era. The ones who respond with zero-sum fear will find that the ocean is boiling around them whether they like it or not.

    Fuller, who died in 1983, anticipated this moment: “Ephemeralization trends towards an ultimate doing of everything with nothing at all.” Intelligence approaching zero marginal cost is the logical terminus of his arc from stone to wireless.

    The question is no longer whether this is happening. It’s whether we’ll use the moment to boil oceans — or drown in committee.

    Key Takeaways

    * The Jevons Paradox — making a resource more efficient doesn’t reduce consumption, it unleashes demand. Coal, light, computing, and storage all followed this pattern over 160 years.

    * AI inference costs are collapsing faster than any previous resource: 280x cheaper in two years, accelerating to 200x per year. Yet total spending on inference grew 320%, showing super-elastic demand.

    * Jevons and Fuller describe two sides of the same process: we do more with less material (ephemeralization) while consuming vastly more of the underlying capability (the paradox).

    * The energy grid is the next Jevons battleground — cheap solar created 457 hours of negative prices in Germany, and AI-driven demand is exploding. The positive-sum response isn’t more hardware, it’s coordination infrastructure at the edge.

    Full transcript available below the audio player.



    This is a public episode. If you would like to discuss this with other subscribers or get access to bonus episodes, visit frahlg.substack.com
    17 min
  • 069 - Building the Machine

    This episode is different. Instead of talking about the grid, energy markets, or coordination protocols, I’m talking about this podcast — how it’s made, why I rebuilt the entire production pipeline from scratch, and what it taught me about the relationship between tools and output.

    The NotebookLM Era

    Here’s what used to happen: I’d spend a week reading papers, articles, talking to people. Then I’d dump everything into NotebookLM, hit generate, and get a thirty-minute episode. Every time. Thirty minutes. No control over length, no control over focus, and zero memory of what I’d already covered three episodes ago.

    It was fine. But it wasn’t mine. It didn’t sound like me. Every episode existed in isolation — no arc, no continuity. Just... content.

    And if you know me at all, you know that drives me absolutely crazy.

    Physics Before Code (Yes, Even for Podcasts)

    We say this at Sourceful constantly: physics before code. The physical reality of the problem has to drive the architecture. Not the other way around.

    So I asked myself — what’s the physics of a podcast?

    A podcast is a conversation. A human being talking to other human beings. That’s the constraint. Everything else is infrastructure.

    Once I framed it that way, the architecture became obvious. Research goes in. A script comes out — not generated audio, a script. Something I can read, edit, argue with. The script is the single source of truth. Audio, transcript, blog post — all derived from that one artifact.

    One command. Research in, episode out.

    The Memory Problem

    Here’s the part that gets me genuinely excited: the system has memory.

    It knows what we talked about in episode twelve. It knows which topics we’ve beaten to death and which ones we’ve barely touched. When it generates a new script, it has the context of every previous episode.

    That means I can say: give me a ten-minute episode on grid storage, connect it to what we said about frequency regulation in episode forty-two, and don’t repeat the EV stuff from last week. And it does that. Because it has the memory.

    There’s an obvious irony here. I spend all day building local-first coordination infrastructure for the energy grid — systems with memory, context, and local intelligence. And then I was going home and using a cloud-only, no-memory, no-control tool to make my podcast.

    The cobbler’s children have no shoes, right? Not anymore.

    Fifteen Iterations to Sound Like Myself

    I should be honest about the process, because it wasn’t “write code, done.” It was deeply iterative.

    The first version sounded terrible. Flat. Robotic. Like a GPS navigation system reading my thoughts.

    So I started tweaking. Voice stability settings. Speed. Silence between segments. Which model to use for synthesis. It turns out that AI voice cloning is incredibly sensitive to these parameters. Too much “style” and my voice drifts into accents I’ve never had. Too little speed and I sound sedated. The wrong model and prosody falls apart completely.

    It took about fifteen iterations to get to what you’re hearing now. It’s still not perfect. But it’s mine.

    Tools Shape Output

    There’s a deeper point here that I keep coming back to: the tools we use shape the things we make.

    If your tool gives you no control, you get generic output. If your tool has memory, your output has continuity. If your tool understands your constraints, your output respects them.

    We’re not just consuming AI anymore. We’re building with it — giving it context, constraints, memory. Making it an extension of how we think, not a replacement for it.

    Same Principles, Same Architecture

    The same shift is happening in energy. From consuming to coordinating.

    Your solar panels don’t just generate power — they coordinate with the grid. Your battery doesn’t just store energy — it provides frequency response. Your EV doesn’t just drive — it balances load in your neighborhood. Every device becomes a participant, not just a consumer.

    That’s what Coordinated is about. Not just the energy grid. Not just markets and thermodynamics. It’s about the idea that complex systems need coordination. And coordination requires memory, local intelligence, and respect for the physics of the problem.

    Whether that problem is balancing fifty hertz across a continent... or making a podcast that actually gets better over time.

    Same principles. Same architecture. Same obsession with doing it right.

    This episode was produced entirely by the Coordinated pipeline — script generated by Claude Opus, voice rendered through ElevenLabs, blog post auto-generated, all from one command. The cobbler finally made himself some shoes.

    Key Takeaways

    * I rebuilt the podcast production pipeline from scratch because NotebookLM gave me no control over length, focus, or continuity — every episode existed in isolation with no memory of previous ones.

    * The new system treats the script as the single source of truth. Research goes in, a human-editable script comes out, and everything else (audio, transcript, blog post) derives from that one artifact.

    * Episode memory changes everything — the system knows what 68 previous episodes covered, so it can build on past conversations instead of repeating them.

    * The tools we use shape what we make. If your tool has no memory, your output has no continuity. The same principle applies to energy: devices need to be participants with local intelligence, not just dumb consumers on a cloud API.

    Full transcript available below the audio player.



    This is a public episode. If you would like to discuss this with other subscribers or get access to bonus episodes, visit frahlg.substack.com
    6 min
  • NATS as the Nervous System of the Grid

    In this special episode of Coordinated with Fredrik, we went deep — not at the strategy layer, not at the founder layer, but at the socket level.

    This was a strict engineering teardown of a single question:

    Can NATS become the autonomic nervous system of Sourceful Energy?

    What follows is the architectural synthesis.

    The Real Problem We’re Solving

    At Sourceful, we are not just operating a backend.

    We are coordinating:

    * High-throughput mobile app traffic

    * A growing mesh of backend microservices

    * Massive telemetry streams from distributed energy assets

    * Smart meters

    * EV chargers

    * Solar arrays in remote geographies

    * Wind turbines behind unstable uplinks

    This is not a traditional cloud-native architecture.

    It is cloud + edge + unreliable networks + financial correctness.

    That requires more than horizontal scaling. It requires:

    * Isolation of failure domains

    * Backpressure awareness

    * Autonomous routing

    * Dynamic topology adaptation

    * Edge survivability

    This is where NATS becomes interesting.

    The 15 MB Binary That Changes the Conversation

    NATS runs as a single static Go binary of roughly 15 MB.

    A single node can handle 15–18 million messages per second.

    That sounds unrealistic until you understand the engineering choices:

    Concurrency Model

    * Lightweight goroutines

    * User-space scheduling

    * Massive TCP connection density

    Memory Discipline

    * Zero-allocation parsing

    * Pointer passing instead of object churn

    * Minimal garbage collection pauses

    Routing Philosophy

    * Pure in-memory message routing

    * Disk I/O only when explicitly requested

    NATS is not a heavyweight enterprise broker.

    It is a highly optimized, high-throughput routing engine.

    Selfish Optimization: Protect the System First

    One of the most controversial ideas in NATS is “selfish optimization.”

    If a downstream consumer slows down:

    * NATS does not buffer indefinitely

    * NATS does not slow producers

    * NATS drops the connection

    From a traditional enterprise mindset, that sounds aggressive.

    But in distributed energy systems, it is correct.

    If the router collapses:

    * Telemetry stops

    * Control signals stop

    * Billing APIs stop

    * The entire system fails

    Protecting the health of the transport layer is non-negotiable.

    The whole must survive even if individual services fail.

    Core NATS vs JetStream

    NATS separates transient routing from durability.

    Core NATS

    * In-memory

    * Fire-and-forget

    * Ultra-low latency

    * No persistence

    If no subscriber exists, the message is dropped.

    Use this for:

    * Real-time telemetry

    * State queries

    * Fast internal RPC

    JetStream

    * Durable streams

    * Raft-based replication

    * Replayable consumers

    * At-least-once / exactly-once semantics

    Use this for:

    * Billing events

    * Immutable records

    * Financial correctness

    The key principle:

    Persistence is opt-in.

    You only pay for disk I/O when the workload requires it.

    Raft Without the Bottleneck

    Most distributed streaming systems rely on a single global consensus group.

    JetStream does something different:

    * One meta-consensus group for cluster metadata

    * Independent Raft groups per stream

    * Even per consumer

    If you run 5,000 streams, you run 5,000 independent consensus groups.

    Why does that not collapse under overhead?

    Because:

    * Each Raft group runs as a lightweight goroutine

    * Heartbeats are batched

    * Streams are isolated

    A spike in one stream does not block the others.

    This is horizontal scalability at the consensus layer.

    Subject-Based Routing Instead of IP-Based Thinking

    NATS routes by subject strings, not by IP addresses.

    Example:

    telemetry.eu.germany.meter80492

    Routing is powered by an optimized radix trie.

    This means:

    * No regex matching

    * No linear scans

    * Logarithmic routing complexity

    Subject hierarchies become your semantic network.

    Developers stop thinking about:

    * Hostnames

    * Ports

    * DNS

    * Reverse proxies

    They express interest in data.The infrastructure routes it.

    Request-Reply Without HTTP

    NATS supports request-reply patterns without point-to-point connections.

    Mechanically:

    * The requester generates a temporary reply subject

    * Publishes a message including that subject

    * A service processes and replies to that subject

    * The first response wins

    To developers, it feels synchronous.

    Under the hood, it is fully asynchronous and multiplexed.

    Queue groups provide built-in distributed load balancing.

    This eliminates internal service meshes and east-west load balancers for microservice communication.

    Public ingress still requires API gateways.Internal routing becomes dramatically simpler.

    Global Scaling with Superclusters

    Inside a region, NATS uses a full mesh cluster.

    Across regions, it uses superclusters connected by gateways.

    Gateways operate in interest-only mode.

    If Europe is not subscribing to US telemetry:

    * No bytes cross the Atlantic.

    The moment interest appears:

    * Flow begins automatically.

    This prevents blind data mirroring and reduces egress costs dramatically.

    Leaf Nodes: Edge Autonomy

    Leaf nodes are where NATS becomes transformative for energy infrastructure.

    A leaf node:

    * Runs locally on edge hardware

    * Initiates an outbound TLS connection to the core

    * Requires no inbound firewall rules

    * Multiplexes all traffic over a single connection

    If connectivity drops:

    * Local JetStream buffers telemetry

    * Local control systems continue functioning

    * No data is lost

    When connectivity restores:

    * The stream synchronizes automatically

    * Consumers resume from correct offsets

    This enables:

    Autonomous edge during disconnection.Seamless federation when connected.

    For EV chargers, solar arrays, and wind turbines, this is critical.

    Decentralized Security at Scale

    Traditional brokers rely on centralized authentication.

    That becomes a bottleneck at scale.

    NATS uses:

    * ED25519 keypairs

    * JWT-based trust hierarchy

    * Operator → Account → User model

    Authentication becomes pure cryptographic verification.

    No database lookups.No external latency.No central auth bottleneck.

    Permissions are embedded in JWT claims:

    * Publish rights

    * Subscribe rights

    * Data limits

    Revocation can be pushed in real time without cluster restarts.

    For enterprises tied to Okta or LDAP, auth callouts bridge existing identity systems into decentralized JWT issuance.

    This allows compliance without sacrificing performance.

    Kafka, RabbitMQ, MQTT — Where NATS Fits

    Kafka

    Designed for:

    * Durable append-only logs

    * Analytics pipelines

    * Data lakes

    Strength:

    * Historical retention

    Tradeoff:

    * Partition-bound scaling

    * Consumer rebalancing pauses

    * Operational overhead

    NATS:

    * Dynamic routing

    * Elastic worker scaling

    * Lower latency for microservices

    RabbitMQ

    Designed for:

    * Complex exchange-based routing

    Tradeoff:

    * Higher operational fragility under partitions

    * Cluster state complexity

    NATS:

    * Simpler subject routing

    * Gossip for cluster sync

    * Raft-backed durability

    MQTT

    Best for:

    * Constrained IoT devices

    NATS does not replace MQTT.

    It embeds an MQTT broker.

    MQTT topics are mapped directly to NATS subjects internally.

    This creates a unified backbone:

    * Edge devices speak MQTT

    * Backend services speak NATS

    * No external translation layer required

    The Paradigm Shift

    For decades, distributed systems have been built around:

    * IP addresses

    * DNS names

    * Blocking HTTP calls

    * Explicit service discovery

    NATS introduces a different idea:

    Express interest in a semantic subject.Let an autonomic system route it dynamically.

    In a world of:

    * Real-time AI inference

    * Autonomous energy assets

    * Fluid containerized workloads

    * Distributed edge computing

    IP-based thinking becomes friction.

    Subject-based thinking becomes leverage.

    What This Means for Sourceful

    Adopting NATS is not swapping a queue.

    It is:

    * Flattening internal service meshes

    * Eliminating east-west load balancers

    * Moving complexity into autonomic infrastructure

    * Enabling edge-first resilience

    * Protecting system health by design

    * Running a global coordination backbone on a single optimized binary

    The goal is operational simplicity.

    Push complexity into the transport layer.Free engineers to focus on energy optimization logic.

    If we get this right:

    The infrastructure becomes invisible.

    And the grid becomes programmable.



    This is a public episode. If you would like to discuss this with other subscribers or get access to bonus episodes, visit frahlg.substack.com
    41 min
  • Slaying the Broken Charger Dragon

    You know the feeling.

    You’re low on range. The map says there’s a charger around the corner. You pull up — relief. And then… black screen. Or “out of order.” Or worse: it looks fine, but nothing happens.

    That moment — that tiny spike of anxiety — is the real enemy of EV adoption.

    In this episode of Coordinated with Fredrik, we go deep into the engineering side of that problem. Not surface-level EV talk. Not market hype. We unpack the actual backend architecture required to build a charging network that doesn’t break — and more importantly, one that scales.

    This was a special deep dive made for David and the team at Sourceful Energy. The mission:

    How do you build a truly robust charging network using OCPP — but do it in a modern, open-source, event-driven way that fits a NATS-based architecture?

    Why OCPP 2.0.1 Is the Only Serious Choice Today

    We trace the evolution of OCPP from the early SOAP-based days (heavy XML over fragile 2G connections) to the WebSocket revolution of 1.6 — and then to the modern architecture of 2.0.1.

    Here’s the punchline:

    * 1.6 works, but it’s messy and vendor-fragmented.

    * 2.0.1 is structured, hierarchical, and event-driven.

    * It has native certificate handling.

    * It supports granular device modeling.

    * It enables accurate transaction handling.

    * It’s built for ISO 15118 and plug-and-charge.

    * And it cleanly prepares you for OCPP 2.1 and bidirectional charging (V2X).

    If you’re building from scratch in 2026, there’s no serious argument for staying on legacy 1.6 unless hardware forces your hand.

    The Architecture Question: Don’t Build a CSMS From Scratch

    The temptation is obvious: “We’re engineers. Let’s build it ourselves.”

    That’s a trap.

    Implementing the full OCPP spec — properly — is a multi-year effort. Edge cases, retries, timeouts, certificate handling, WebSocket state management… it’s a black hole.

    Instead, we explore the open-source landscape:

    * The old monolithic Java servers.

    * Client-side firmware stacks.

    * And finally: a modern, modular TypeScript-based backend designed for 1.6 and 2.0.1 side by side.

    The key architectural insight:

    Use a modular OCPP engine as the edge gateway.Inject a custom NATS adapter.Publish clean, validated events into your own internal event-driven system.

    Let OCPP parsing and compliance live at the edge.Let your business logic live in your own microservices.

    That separation is everything.

    NATS + OCPP 2.0.1 = Clean Topic Hierarchies

    OCPP 2.0.1’s hierarchical device model maps beautifully to NATS subject structures.

    Instead of a generic firehose of messages, you can structure topics like:

    ocpp.v2.station-42.evse1.connector.temperature

    ocpp.v2.station-42.transactionevent
    ocpp.v2.station-42.status

    Now your billing service only subscribes to transaction events.Your analytics service subscribes to metering data.Your ops dashboard listens to error codes.

    Fully decoupled. Clean. Scalable.

    This is how you avoid turning your backend into a spaghetti monolith.

    Reliability Is Not a Feature — It’s the Product

    Up to 25% of public chargers can be non-functional at any given time. That’s not a UX issue. That’s a systemic architectural failure.

    A huge reason: vague error reporting.

    If your charger only reports “Other error,” your operations team has no choice but to roll a truck. That’s expensive. And slow.

    In the episode, we talk about:

    * Mandating standardized granular error codes.

    * Using compliance tools to verify hardware implementations.

    * Making reliability a contractual requirement in procurement.

    Because here’s the uncomfortable truth:

    The world’s best backend can’t fix bad firmware.

    Architecture and hardware procurement strategy must align.

    The Bigger Play: From Charger to Grid Asset

    We close the episode with something bigger.

    OCPP 2.1 introduced proper bidirectional charging (V2X). That means EVs stop being passive loads and start becoming active grid assets.

    If your backend is:

    * Event-driven

    * Granular

    * Secure

    * High-throughput

    You’re not just running a charging network.

    You’re laying the foundation for a virtual power plant.

    And that only works if the software pipes are designed correctly from day one.

    If you’re building infrastructure — not just apps — this episode is for you.

    This wasn’t about theory. It was about architecture decisions that determine whether your network becomes resilient, scalable, and future-proof — or collapses under its own complexity.

    Thanks for tuning in to Coordinated with Fredrik.

    More deep dives coming.



    This is a public episode. If you would like to discuss this with other subscribers or get access to bonus episodes, visit frahlg.substack.com
    34 min

About Coordinated with Fredrik

From the publisher's feed

Coordinated with Fredrik is an ongoing exploration of ideas at the intersection of technology, systems, and human curiosity. Each episode emerges from deep research. A process that blends AI tools like ChatGPT, Gemini, Claude, and Grok with long-form synthesis in NotebookLM. It’s a manual, deliberate workflow, part investigation, part reflection, where I let curiosity lead and see what patterns emerge.