Effacer les filtres
Effacer les filtres

PSAT Compatibility issues for MATLAB

20 vues (au cours des 30 derniers jours)
Parthsarthi
Parthsarthi le 10 Juin 2024
Réponse apportée : Vandit le 17 Juin 2024
Hello Guys,
I have been trying to run PSAT for MATLAB, however even the example files are not working for me. Has the code become obsolete? Is the PSAT no longer working?
I tried the latest available version for PSAT(2.1.11) with MATLAB R2024a and R2018a but both did not work.
This is the error message which gets generated when I try to load an example .m file from the tests folder and hit power flow button.
Error using fprintf
Invalid file identifier. Use fopen to generate a valid file identifier.
Error in fm_wcall (line 49)
count = fprintf(fid,'function fm_call(flag)\n\n');
Error in fm_spf (line 41)
fm_wcall;
Error in fm_set (line 721)
fm_spf
Error while evaluating UIControl Callback
For the .mdl example file, it is generating the following error
Simulink Model Conversion
Simulink File <d_hvdc.mdl>.
Loading Simulink Model
Error using delete
Cannot access method 'delete' in class 'matlab.ui.Root'.
Error in fm_bar (line 41)
if ishandle(Hdl.bar), delete(Hdl.bar); end
Error in sim2psat (line 133)
fm_bar open
Error in fm_dirset (line 474)
check = sim2psat(filename,pwd);
Error in fm_dirset (line 563)
check = fm_dirset('convert');
Error using uiwait (line 81)
Error while evaluating UIControl Callback.
I made sure to unzip the folder correctly and even add to path, but still the problem persists.
Any help would be greatly benefical.
Best Regards

Réponse acceptée

Vandit
Vandit le 17 Juin 2024
Hello Parth,
To address PSAT compatibility issues with MATLAB, problems may arise when attempting to run PSAT directly from its directory without having write access to that directory. PSAT maintains a record of the directory you are in when you start running it and sometimes attempts to write the file "fm_call.m" into that directory. Here's how you can resolve this issue:
  1. Begin by rerunning MATLAB with administrator privileges. Afterward, initiate PSAT again from the command window. This step ensures that MATLAB has the necessary permissions to execute PSAT correctly.
  2. The issue may arise if you start running PSAT from its directory without write permissions. To circumvent this, ensure that PSAT is included in your MATLAB path. Then, start PSAT by its name while you are in a directory where you have write access. This workaround prevents the problem by ensuring PSAT does not attempt to write to a directory where you lack the necessary permissions.
For more clarity, you can refer to the following MATLAB Answers thread:
Hope this helps!

Plus de réponses (0)

Produits


Version

R2018a

Community Treasure Hunt

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

Start Hunting!

Translated by