Ask Your Question
0

How to get the system frequency? in the following code I get only voltage and frequency error. File ".\psspy.py", line 49525, in busdat psspy.BusdatError: busdat Error: ierr=2

asked 2023-04-06 04:27:25 -0500

Ibrahim gravatar image

updated 2023-04-06 11:32:58 -0500

jconto gravatar image

Hi everyone, I want to get the system frequency, but in the following code I get only voltage and frequency error.

import os, sys 
# Set environment for psse33.04
PYTHONPATH = r'C:\Program Files (x86)\PTI\PSSE33\PSSBIN'
sys.path.append(PYTHONPATH)
os.environ['PATH'] += ';' + PYTHONPATH
import psspy

# Get the system voltage    
ierr,voltage = psspy.busdat(2,'KV')

# Get the system frequency
ierr,freq = psspy.busdat(2,'FREQ')

File ".\psspy.py", line 49525, in busdat psspy.BusdatError: busdat Error: ierr=2

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
0

answered 2023-04-06 05:19:52 -0500

perolofl gravatar image

API BUSDAT only returns load flow data. Frequency is not a parameter in load flow studies. Error code 2 means: "Bad value of 'STRING'; 'RVAL' unchanged", i.e. 'FREQ' is not an allowed argument to BUSDAT.

In dynamics, the bus frequency (in pu speed deviation) is seen in a bus frequency channel.

edit flag offensive delete link more

Comments

I want to get the system frequency. What command should I use? Thank you!

Ibrahim gravatar imageIbrahim ( 2023-04-06 05:40:18 -0500 )edit

Do you mean if the case is in 50 or 60 Hz option?

perolofl gravatar imageperolofl ( 2023-04-06 05:42:44 -0500 )edit

In dynamic simulation, I want to get the system frequency after run dynamics 5s. And print frequency.

Ibrahim gravatar imageIbrahim ( 2023-04-06 06:02:43 -0500 )edit

There is nothing called "system frequency". You get the speed deviation for individual generator rotors and for buses, using channels.

perolofl gravatar imageperolofl ( 2023-04-06 08:01:21 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

[hide preview]

Question Tools

1 follower

Stats

Asked: 2023-04-06 04:27:25 -0500

Seen: 236 times

Last updated: Apr 06 '23