Hello everyone, I am trying to implement a peak-shaving algorithm for a microgrid using the modelica building library on a Fedora OS. I manged to set the python path and run a very basic model, but I cannot get my module for peak-shaving to work. I am not sure how to read python error codes in openmodelica. I put my python code in the same path as the examples. Not sure why it is not working. I am attaching my .mo, .py, and .txt files a google drive. Thank you for the help. Also here is the error output:
Simulation process failed. Exited with code 255.
/tmp/OpenModelica_sigi_laptop/OMEdit/warehouse_eaxmple_version_0/warehouse_eaxmple_version_0 -port=40127 -logFormat=xmltcp -override=startTime=0,stopTime=3.1536e+07,stepSize=900,tolerance=1e-06,solver=dassl,outputFormat=mat,variableFilter=.* -r=/tmp/OpenModelica_sigi_laptop/OMEdit/warehouse_eaxmple_version_0/warehouse_eaxmple_version_0_res.mat -w -lv=LOG_STATS -inputPath=/tmp/OpenModelica_sigi_laptop/OMEdit/warehouse_eaxmple_version_0 -outputPath=/tmp/OpenModelica_sigi_laptop/OMEdit/warehouse_eaxmple_version_0
The initialization finished successfully without homotopy method.
Failed to load "peak_shaving".
This may occur if you did not set the PYTHONPATH environment variable
or if the Python module contains a syntax error.
The error message is "(null)"
Google Drive Link with files:
https://drive.google.com/drive/folders/19EO6d3AprigmE5khZ4WW-olnD9iswBi-?usp=share_link
Thank you all for the help