Clear Filters
Clear Filters

Visualize Real Measured Battery Temperature Data?

21 views (last 30 days)
I am using Simscape Battery to model and simulate a battery pack from a real world application and I am using a real world measured current load for my simulations. I am visualizing the temperatures of the pack using the BatterySimulationChart and exporting the video to a file. I want to also visualize the Measured data which corresponds to the current load that is applied to the simulation so that I can assess the performance of the model. I thought of editing the temperatures in the simlog object but the only way I can get to temperatures in the simlog object is by using values() but it is meant to return the values of temperature of voltage or state of charge and does not give me a way to edit them. I used the example for visualizing a simulation but my workflow for the project is divided into multiple scripts and folders so I don't know if posting any code would be helpful or cause more confusion but I'll post my relevant code for creating the video of the simulation data. My questions is: Is there a way I can visuzlize real measured battery temperature on the BatteryPack object that I have created?
simulation.alldata=load("../0_DATA/SIMULATION_DATA/with_adjusted_params.mat");
%% Plotting the video of temperature change
import simscape.battery.builder.*
battery_object=load("created_library\myBatteries.mat");
battsimlog = BatterySimulationLog(battery_object.UREaccu,simulation.alldata.simlog.cells);
battsimlog.SelectedVariable = "temperatureCell";
battsimlog.SelectedVariableUnit="degC";
f = uifigure("Color","w");
g = uigridlayout(f, [1,1]);
moduleChart = BatterySimulationChart(Parent = g,BatterySimulationLog = battsimlog);
moduleChartColorBar = colorbar(moduleChart);
ylabel( moduleChartColorBar, strcat(battsimlog.SelectedVariable, " (", battsimlog.SelectedVariableUnit,")") );
createVideo(moduleChart,"BatterySimulationChart_Temperature_Video",PlaybackSpeed=30,FrameRate=60);

Answers (0)

Categories

Find more on Battery Pack Modeling in Help Center and File Exchange

Products


Release

R2024a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!