efesotomasyon.com -Toshiba inverter,drive,servo,plc

E6581315

4.6. Examples of Communication programs

According to the hardware configuration of the computer used, select a serial output port. To use an RS232C port on the computer, you will have to prepare an RS232C-RS485 conversion unit sepa- rately.

An USB-RS485 conversion unit (USB0001Z) is available as our standard offering.

Ex. 1: BASIC program for monitoring the output frequency continuously (RS232C, ASCII mode) (Toshiba version of Advanced BASIC-86 Ver. 3.01.05J)

Monitoring the output frequency continuously 1) Examples of programs

10 OPEN "COM1:9600,E,8,1" AS #1

20 A$=”FE00”

30 PRINT #1,"("+”R”+A$+")"

40 INPUT#1,B$

50 AAA$=“&H”+MID$(B$,7,4)

60F$=LEFT$(STR$(VAL(AAA$)/100),6)

70PRINT " Output frequency =";F$+“Hz”

80GOTO 20

---9600 baud, even parity, 8-bit length, 1 stop bit

---Specifies the communication number for monitoring the output frequency.

---Transmits data to the inverter.

Note: The carriage return code is added automatically.

---Receives data returned from the inverter.

---Extracts only data items from the data re- turned.

---Converts data into decimal form.

---Displays the output frequency.

---Repeats.

2)Examples of program execution results (stop command issued during 80 Hz operation) Output frequency = 80 Hz ...

Output frequency = 79.95Hz

:

:

Output frequency = 0Hz

24

Page 25
Image 25
Toshiba TOSVERT VF-AS1 instruction manual Examples of Communication programs