PLC_N00B_5

How to control VFD speed Via HMI?

17 posts in this topic

Hello, i am a novice when it comes to PLC programming so i was wondering if i could get some help designing a ladder circuit that allows me to control the speed of a motor connected to a VFD from my HMI. the components i am working with are as follows, NX1P2 omron PLC (with a few digital input & output cards), NA5-7 (V1) omron HMI, and a yaskawa GA500 VFD. Essentially i have a customer who would like to view and make adjustments the speed of a group of VFD's from their HMI located on the main control cabinet. I would like a little help designing the circuit within the controller (If at all possible) or maybe a bit of guidance as to the type of functions i can use to get the desired results.

 

any and all help is much appreciated, thanks

Share this post


Link to post
Share on other sites

We can point you in the right direction - how are you communicating with the drives?

Are you controlling speed(rpm) or hz?

 

 

Share this post


Link to post
Share on other sites

the drives will be communicating to the PLC via the input and output terminal strip on the drives, its S1-S7 i believe. i just confirmed that we will not be using ethernet. 

I would like the speed control to be in Hz to either speed up or slow down the motor.

Share this post


Link to post
Share on other sites

You didn't mention any analog outputs on the PLC, are you just programming a few presets in the drive for the GPIOs or will you be giving it a speed reference via analog?

Share this post


Link to post
Share on other sites

apparently we have the analog output cards on order so thats what its going to end up being.

Share this post


Link to post
Share on other sites
2 hours ago, PLC_N00B_5 said:

apparently we have the analog output cards on order so thats what its going to end up being.

OK so the general flow of things will be:

1) The user enters a Hz value on the HMI

2) The PLC converts this to an analog output which is the reference for the drive

 

You'll need to create some variables in the PLC first (feel free to call them whatever you want). Make them in the Global Variables section.

HMI_Speed_Setpoint  (REAL datatype, retained)

VFD_Out_Scaled(REAL datatype, non-retained)

VFD_Analog_Out (INT datatype, non-retained)

On the HMI go to Variable Mapping and drill down to User Variables for your PLC. Give the HMI_Speed_Setpoint variable a name so you can use it on the HMI. I like to right click on user variables and select create device variable with prefix. Select none and the variable names will be the same as the PLC.

Add a Data Edit object to the screen page you want to modify the speed from. Give it limits so the user can't enter an invalid frequency. Assign the varible HMI_Speed_Setpoint

In the PLC go to the program you want to create the logic in and add a ScaleTrans block. The SclIn variable will be HMI_Speed_Setpoint. X0 will be REAL#0, Y0 will be REAL#0, X1 will be REAL#60, Y1 will be REAL#8000.   (This is assuming your analog card's resolution is 8000 and your speed is 0-60Hz)

The output of the ScaleTrans block will be VFD_Out_Scaled

You then convert the datatype to INT and map it to the card. Use REAL_TO_INT - the input will be VFD_Out_Scaled and the output will be VFD_Analog_Out.

Then go to your I/O Map and put the VFD_Analog_Out variable on the output that is going to the drive.

This is a very simple version of what needs to be done - you may need to modify it to meet your application's needs.

 

 

 

Capture.JPG

Share this post


Link to post
Share on other sites

Thanks a lot for the info, we have the scale and real to int created exactly as you specified now ill have to go into the HMI program to create a data edit object and test out, i still do not have my analog output cards in stock yet.

 

Another question, we have standard stranded copper 20GA wiring going from our VFD's into our PLC output cards (when we get them) instead of a twisted shielded cable. will this be an issue if we are sending the output signal from the plc to the drive? we havent decided if we are going to use a 4-20ma signal or a 0-10v signal.

Share this post


Link to post
Share on other sites
34 minutes ago, PLC_N00B_5 said:

Thanks a lot for the info, we have the scale and real to int created exactly as you specified now ill have to go into the HMI program to create a data edit object and test out, i still do not have my analog output cards in stock yet.

 

Another question, we have standard stranded copper 20GA wiring going from our VFD's into our PLC output cards (when we get them) instead of a twisted shielded cable. will this be an issue if we are sending the output signal from the plc to the drive? we havent decided if we are going to use a 4-20ma signal or a 0-10v signal.

Depends where you route the wires... hard to say. The noise, if any, will probably have no effect on operation. 4-20ma is a better choice if this is your concern but I doubt you would see any issues either way.

Share this post


Link to post
Share on other sites

Is there anything special i need to do in order to integrate the speed reference function into a stop start circuit? or is there a way i can reference all motors that need adjustable speeds to the one function block?

Share this post


Link to post
Share on other sites
1 hour ago, PLC_N00B_5 said:

Is there anything special i need to do in order to integrate the speed reference function into a stop start circuit? or is there a way i can reference all motors that need adjustable speeds to the one function block?

If you are going to have the same speed for all the motors the I would just make a an integer variable for each on the analog outputs and based on a selection bit MOVE E_Analog_Out into the other analog outputs as needed.

You should also move 0 into the output if the motor is supposed to be stopped

Share this post


Link to post
Share on other sites

yes essentially i will have three sections of conveyors.

the first section will have 8 conveyors, each conveyor needs to have the ability to adjust their speeds individually.

the second and third sections of conveyors will have 7 conveyors each. I will need to be able to adjust the speed of conveyor sections (2) and (3)  so we can achieve a sort of flow control within the factory.

 

 

Share this post


Link to post
Share on other sites
1 hour ago, PLC_N00B_5 said:

yes essentially i will have three sections of conveyors.

the first section will have 8 conveyors, each conveyor needs to have the ability to adjust their speeds individually.

the second and third sections of conveyors will have 7 conveyors each. I will need to be able to adjust the speed of conveyor sections (2) and (3)  so we can achieve a sort of flow control within the factory.

 

 

For conveyors with individual speed control you'll need to clone the existing code and conveyors with shared speed reference you can use 1 scaling block and pass the output to multiple drives.

Share this post


Link to post
Share on other sites

Could you take a look at the code that I have so far?

Share this post


Link to post
Share on other sites

can you share it? The simulator in Sysmac is a great debugging tool

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now