This solution enables an interactive connection to and management of distributed energy sources (DER), such as batteries of electric vehicles and solar charging stations, to form a smart grid. This enables the conversion of previously passive energy generation and storage assets into active assets that can automatically trade energy to where and when it is required. The core of the L7 Drive offering is its patented innovation in battery management, CAN Gateway, and an industrial-grade security cloud data processing application. This IoT solution monitors and controls batteries within milliseconds. The L7 Drive solution enables the connection of batteries of electric vehicles together with other energy storage assets and charging sources (grid, solar, wind), as well as to automatically manage the resulting grid load and balancing. The system is responsive to sudden changes in the grid balancing requirements, such as during a power outage, and manages energy flows intelligently based on dynamic price information.