AC motor control speed twidosuite/soft and console magalis

insyspower

Member
Join Date
Jul 2014
Location
deadland
Posts
18
Hi there,

I want to control velocity(speed) of a AC motor SEW DT71D4, i am using automate telemecanique TWDLCAE40DRF, the console reference is magalis XBT N400, also the frequency variator (if needed) is altivar 31 ATV31H055M2.

My project is: controling a motor using twidosoft and a console, i have in the grafic(image) the control of speed of a motor variating with time in seconds, frequency is in Hz, and T1 and T2 are times in seconds that i can configure on the console, example T1=5s, and T2=10s(seconds), w1 are the speed of a motor rotating clockwise, and w2 is in counterclockwise, example w1=-w2=30Hz, also cycles are other variable to configurate in the console for example, cycle=4 that means that the motor have to rotate acordanly with the graffic(image), and do it 4 times.
So what i need is a code to twidosoft or twidosuite, i have started already, but i can´t control the motor, incomplete code, also missing timers.
Also i want to control a motor with a potenciomenter.

Also the PID in the code is to remove, and i want to replace the PID, for a code that can control a motor as above (grafic, image).

control_motor_speed_time(s)_frequency(Hz)_w1_speed.jpg program_part_1.jpg program_part_2.jpg console.jpg
 
Last edited:
If I understand correctly you want us to program the twido for you?
Do you know how to program?
Do you have an analogue output? I think you do if I look at the code you are writing to %qw which is an analogue output
If its 0-10 then just wire this output the the 0-10V analaogue input of the drive. And point the reference in the drive (FR1) to the correct channel.
Use LI2 on the drive (Default for reverse direction). You will wire a digital output to the LI2. Make sure you use a relay output on the plc and use the 24V of the ATV. If you dont have a relay out make sure you common the 0V of the drive and the plc together.
Any further questions just ask but no one is going to write the code for you.....well I'm not
 
Last edited:
The hardware is set, I don´t need to wire anything, just need to complete the program(ladder) on twido.
I know the very basics: inputs I0.0 outputs Q0.0 and negate them, rising edge, reset , set, MWords, counters , compare/operate blocks, timers, states %M0.
On i/O table i got adresses %qw1.0 and %iw1.1, thats the analogue outputs/inputs, the type is 0-10V and, minimun 0 and maximun 50Hz.
But i don´t know how to put a motor for example at 30 Hz.
And reverse the motor to clockwise or counterclosewise.
I think the Altivar is set up already and plc, maybe i am missing set up on twido, i study on School.

I am very new to this so i didn´t understand this sentences on botom, is this to set altivar and plc ?
FR1, LI2 thats new to me.

"And point the reference in the drive (FR1) to the correct channel.
Use LI2 on the drive (Default for reverse direction). You will wire a digital output to the LI2. Make sure you use a relay output on the plc and use the 24V of the ATV. If you dont have a relay out make sure you common the 0V of the drive and the plc together"

I_O_table.jpg
 
And include a potenciometer to control speed of a motor, can any1 give hints how to do that on twidosuite ?

This what i have done so far (images)

mw600 counts the cycles.
tm2 general time
tm0 - timer t1
tm1 - timer t2

on rung 5 the instrution : %QW0.1.0 := %MW501, this is not implemented, i want to replace this line, to program a potenciomenter to convert the input values [0,10]V to output [0,50] Hz, speed of motor, MW501 is the value to be writen on the console, but i don´t how to do it, so if any1 can help ?

Untitled4.jpg Untitled5.jpg
 
Last edited:
How to control a motor with potenciometer ?
Easy way, can i just use analog input outputs, or i must use PWM or pulse generator ?
 
Ok lets start slowly.
You are using %mw301 for tm0 and %mw302 for tm1.
You should have an operational block that sets %tm0.p:=%mw301 and another block for Tm1.p:=%mw302
So when you change the values on the xbt it will change the timer preset values in the twido

Then the pot you can connect straight on Analogue input1 (AI1) of the variable speed. Refer to inside of atv31 terminals cover for diagram.
 
But I dont think you have to use the pot. You do have analogue outputs and you have an hmi. You could control the speed via the xbt.......then again to keep things simple just use the pot
 
Ok thanks.

On rung 5- mw501 is the W1 (positive speed of motor)
mw502 is the W2 (negative speed of motor)

i did this: %MW501 := %IW0.1.0 , so if i rotate the pot the current value changes (i think is iw0.1.0 ) and its printed on xbtl. i don´t know if this is correct or i need to add something.

on rung 6:
this instruction %QW0.1.0 := %MW501 , what i am trying to do is the value (frequency Hz) mw501 on xbtl, is converted(attributed) to the motor output is QW0.1.0, so the motor rotates at frequency of current value on mw501.

Does the motor will rotate as i described above, or i need to add something on twido ?

Untitled4.jpg Untitled5.jpg
 
That function you are using %mw502:=0-%mw501 will not work...
Ok on the xbt you have %mw501 (fwd speed) and %mw502 (negative speed)
When the motor starts and runs fwd write %Qw0.1.0:=%mw501
Then when the timer is done for the fwd run and the motor now needs to run in reverse write %qw0.1.0:=%mw502. But to run the drive in reverse using the same analogue you must have a Digital output %qx.x that will switch power onto LI2 (control terminal on the ATV31). By default LI2 is the run reverse terminal.
When you just start the motor and it runs fwd you will have an output which switches 24v onto LI1 (Start terminal of ATv31). When you want to run in reverse you must switch power onto LI2 via another output from the plc
 
I dont think the expansion module TWDLCAE40DRF as a Digital output, so do i have to change the module ?

For negative speed do i write %q0.5:=%MW502, instead of %qw0.1.0:=%mw502?
And positive speed keep line %Qw0.1.0:=%mw501 ?

And in altivar31 do i have to change parameters/set up in menus ?
If so do i have to manually switch LI1 to LI2 ?
 
If you dont know what you are doing maybe you shouldnt be playing with electricity....That said here is the program

Attached are the sections
Please note that the inputs and outputs (%I and %Q) are not what you should use. You should check how your system is wired and where the start and stop buttons and outputs to the atv31 is wired
Check the atv31's manual to see how you must wire the twido's outputs to start and reverse the drive. Also you must wire the analogue output to the drive's analogue input. Depending on whether you use 0-10V or 4-20mA

twido1.jpg twido2.jpg twido3.jpg twido4.jpg twido5.jpg
 
Hi thanks!

The inputs %I are correct, in fact they are start and stop buttons, on the other hand the the outputs %Q0.1 and %Q0.2 are green and red signals, like a semaphore. The motor is the analogue output ? And drive analog input is the alt31 ?
I just plug the cable, I think the wires are done, but i will check/test this later on lab.

Also i know the Q0.5 is the frequency converter, so instead of Q=0.1 and Q=0.2, can i use Q=0.5 ?
 
Last edited:
Today i went to laboratory, somethings good, somethings not, the lights(red,green,yellow) in fact light up as it should.

On altivar31 it shows this message "USF" and the motor wont start so if any1 know how to fix this. Then i turn off turn on power of altivar, it shows "ready", past 10 seconds it shutdown automatically.

I looked at wiring and LI2 is connected to Q0.5, and LI1 is connected to Q=0.6, so just substitute Q0.1 and Q0.2 for Q=0.5 and Q=0.6 and the motor should run right ? But it didn´ t, in fact the motor it never starts.
The AI1 is connected to OUT+, The COM (up) is connected to CN1, and COM (down) is connected to Q0.13 i think.

Do i have to go into the menus on altivar31, to make it run ?
I think the setting are default from fabric.

Also i need to test something with potentiometer.
 
Last edited:

Similar Topics

Does anyone have any experience with working on piezoelectric motor control? I want to use off the shelf components to hopefully change the...
Replies
5
Views
763
So it looks like i am stuck with an old reliance DC drive on this project instead of the powerflex dc w/ 22-COMM-E. That being said i am trying to...
Replies
0
Views
1,193
powerflex755,,,, I set ptp as per page 128 of this document, but the motor does not work. I try to control using Absolute Encoder. Please let me...
Replies
0
Views
1,585
Hi all, Got an application where the customer is looking to use a servo motor, purely because of the very wide speed range required for different...
Replies
12
Views
3,720
Quick question on my first from scratch program needing to control the speed of a motor via controlled input to a motor drive; is it more...
Replies
10
Views
2,157
Back
Top Bottom