Control SCPI instrument from simulink

조회 수: 5 (최근 30일)
Tobias Kammler
Tobias Kammler 2023년 6월 19일
댓글: chrisw23 2023년 6월 20일
Hi,
i'm trying to interact with a power supply controller from simulink via SCPI commands to set voltage and current for an electrolysis-stack. The device uses a serial RS232 interface and I've plugged the cable from the controller via an addapter into the USB-port of my PC. I'm able to control the device with the supplied software (so i dont need to install an other driver?!), but i dont manage to get a connection to the device from simulink ("PSC RS232 EXT" from Delta Elektronika).
I'm using the "query instrument"-block to send the SCPI command and get a response and test the connection, but could also use the "serial receive"-block. The instrument should identify it self with the command *IDN?
The configuration parameters (COM1, Baudrate) are set correct, and the manual says that it can be controlled with SCPI commands from other programs. I also tried to receive the voltage of the power supply. When i sent the query command to receive the voltage and set the data format to binary the Display showed "82".
Does anybody know what i'm doing wrong?
Is it a problem with the data format?
  댓글 수: 1
chrisw23
chrisw23 2023년 6월 20일
Check your Windows Device Manager for the COM Port used. COM1 is not common for Serial-Usb converter com ports. Typically they start at COM3. Just to check...
Before you can send cmds and queries a communication session must be opened and it has to be closed too. The supplied software can't be used in parallel. The session is probably exclusive to one application.

댓글을 달려면 로그인하십시오.

답변 (0개)

카테고리

Help CenterFile Exchange에서 Target Computer Setup에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by