Meaning of 'fuel' sensor in electric vehicles

Gentlemen, we are working on the integration between Matlab and BeamNG.Tech. We have made progress with combustion vehicles and have started working with electric vehicles. So far, we managed to configure the vehicle from Matlab via MathWorks scripts, control the vehicle, read sensor data, and we customized a CO₂ emission sensor in BeamNG. These activities were done for combustion vehicles, but for electric vehicles I couldn’t find sensors for current, voltage, or battery state of charge. However, among the available sensors there is a ‘fuel’ parameter that is normalized between 0 and 1. I would like to know if the ‘fuel’ corresponds to the state of charge?

Hello @Helio,

Thanks for reaching out!

Yes, in the context of electric vehicles in BeamNG, the fuel parameter exposed via the Electrics sensor is repurposed to represent the battery’s state of charge (SoC), normalized between 0.0 and 1.0. While the parameter name remains “fuel” for consistency across vehicle types, it effectively reflects the remaining charge for battery.

That said, BeamNG.tech currently does not provide default or dedicated sensors for voltage, current, or battery temperature out-of-the-box. These parameters would need to be implemented through custom Lua extensions or by enhancing existing Electric sensor behavior in your vehicle definition or controller scripts, much like you approached CO₂ sensing for combustion vehicles.

You can find the full list of Electrics sensor fields here:

Please ensure the vehicle you’re using supports fuel simulation, as electric or modded vehicles may not reflect fuel consumption.

Best regards,
Abdulrahman Saeed
Research Software Engineer
BeamNG.tech Support Team