Dear Peter,
I don't think there is a way to completely integrate your Excel-based battery model with SAM at the moment. Can you tell me more about how you would expect such an integration to work? What inputs does your model require, and what outputs does it generate?
One possibility for partially integrating the models is to use your model to generate a dispatch schedule for SAM. The current dispatch schedule is limited to the weekday and weekend hour-by-month matrices and up to 6 dispatch periods, so you cannot control the dispatch at a finer temporal resolution than that. You could use Excel Exchange or LK scripting to read dispatch data from your Excel file and populate the inputs on SAM's battery storage input page.
With an LK script, you could run simulations in SAM to generate PV generation and load profils, pass that data to your Excel file, and then read battery dispatch data back from the Excel file.
To use the SDK, you would write a program in C/C++ or one of the other supported languages (Python, C#, VBA, etc.) and use it to call SSC, which is the library that SAM uses to run simulations. Because VBA is among the supported languages, you could use a VBA script in your Excel model to run SAM simulations.
You can find recordings of webinars introducing these options on the
Webinars page
, or find more information by searching the website. Let me know if you have specific questions, and I can answer those here.
Best regards,
Paul.