Read/Create zsam file

5 posts / 0 new
Last post
rdprado
Read/Create zsam file

There is the need in the project that I work to geta zsam file and import it in our software integrated with the SAM sdk. Our software uses the photovoltaic flat plate pv part of the SDK. The other way around is also important (to be able to, from all the required input parameters, create a file that can be opened by the SAM software)

Is it possible to do that? I noticed that the zsam file is not easy to read/write programatically...

Thank you,
Renato

Paul Gilman

Dear Renato,

The SDK does not have tools for creating .zsam files.

However, SAM does create files that you can use to duplicate a SAM simulation from the SDK. When you run a simulation in SAM 2014.1.14, it creates a text file in the folder C:\Users\<name>\.SAM\ssc with a list of all of the input variables with their values for each SSC module called by the simulation. It also creates a set of files that assign values to the SSC inputs in the LK scripting language as well as for the Java, C#, Python, and MATLAB language wrappers. You can use those files to get the SAM input variables into your SDK model.

Best regards,
Paul.

rdprado

Hi Paul, thank you very much for the answer.

Dealing with photovoltaics people usually exchange zsam files with each other since SAM is a good software for that. I think it would be nice if projects integrated with SAM could generate zsam files so anyone using SAM would be able to open them (and not everybody has access to my software, for example). It would be nice to configure a simulation in a software other than SAM and other people still be able to open it keeping this exchange possible and increasing the number of projects integrates with SAM.

But I understood your answer that there is currently no way of doing that. Do you think this would be supported in the future, or if I can programatically build a zsam file by myself without the SDK (is it a common format)?

Thanks again!
Renato

Paul Gilman

Hi Renato,

I agree that such a feature for the SDK would be useful. We discussed your request at last week's development meeting -- it's something we'd like to do if we have time, but it is not on our immediate To Do list, but might be something we add later.

For the current version of SAM (2014.1.14), a .zsam file is actually a zip archive. You can change the extension from .zsam to .zip to see its contents. You can see that the file consists of several binary files and folders.

For the next version we plan to release late this fall, we are completely reworking the software and changing the file format.

Best regards,
Paul.

rdprado

Hi Paul,

sorry for my late feedback, was away for a while. I'll check the current zsam and wait for your changes.
Thanks for discussing this, for your time and answer.

Best regards,
Renato

Theme by Danetsoft and Danang Probo Sayekti inspired by Maksimer