Professional Documents
Culture Documents
Configuracion Acs 355 PDF
Configuracion Acs 355 PDF
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
Contents
Introduction...................................................................................................................................................................4
Safetyinstructions .........................................................................................................................................................4
Limitations .....................................................................................................................................................................4
Fieldbusgrounding ....................................................................................................................................................6
Fieldbusshield ...........................................................................................................................................................6
Endtermination.........................................................................................................................................................6
Pullup/pulldownresistors........................................................................................................................................6
Driveswithembeddedfieldbus.................................................................................................................................7
FieldbusmodulesforABBdrives...............................................................................................................................8
Commonrecommendations......................................................................................................................................8
ABBcableTK505........................................................................................................................................................9
AC500COM1Masteratthebuslineend .........................................................................................................11
AC500COM2Masteratthebuslineend .........................................................................................................11
AC500eCoCOM1Masteratthebuslineend..................................................................................................11
AC500eCoCOM2Masteratthebuslineend..................................................................................................12
Driveconfiguration......................................................................................................................................................13
StartingupACS310driveswithembeddedModbusRTU .......................................................................................14
StartingupACS355driveswithFMBA01ModbusRTUadapter ............................................................................15
StartingupACS800driveswithRMBA01ModbusRTUadapter............................................................................17
StartingupACS850,ACQ810driveswithembeddedModbusRTU ........................................................................18
StartingupACS880driveswithFSCA01ModbusRTUadapter..............................................................................19
StartingupACSM1driveswithFSCA01ModbusRTUadapter ..............................................................................20
Installdriveslibrary .................................................................................................................................................21
ControlBuilderPlusforPLCandDrives.......................................................................................................................22
Hardwareconfiguration ..........................................................................................................................................22
IPconfigurationofCPU(forEthernetconnectionbetweenPCandPLC) ...............................................................24
CODESYS ..................................................................................................................................................................25
CODESYStabs ......................................................................................................................................................25
ModbusRTU 2 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
LibraryManager ..................................................................................................................................................26
PLClogic...............................................................................................................................................................27
DownloadprogramtoPLC...................................................................................................................................32
Createbootproject .............................................................................................................................................33
Testtheprogram .................................................................................................................................................34
ReadandwritemoredatabetweenPLCanddrive(optional) ............................................................................36
Visualizations .......................................................................................................................................................43
Addmoredrives(optional)..................................................................................................................................46
Actualizationrate ................................................................................................................................................47
Otherusefuldocumentation .......................................................................................................................................47
Revision .......................................................................................................................................................................47
ModbusRTU 3 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
Introduction
ThisguidewilltakeyouthroughthehardwareinstallationandconfigurationofABBACSDrivesandPLCinorderto
prepare for Modbus RTU control. ABBspecific readymade function blocks and visualizations from the PS553
DRIVES library will be used for the control of the drives. While the guide is applicable to all AC500 PLCs and all
ModbusRTUcompatibleABBACSdrives,theexampleisbuiltupwithanAC500eCoPLCandanACS355drive.
Note! The material in this application might need to be adapted according to actual equipment and function
beforeitisused.Testingoftheequipmentmustalwaysbeperformedbytheresponsiblestartuppersonaccording
tocurrentlegislationbeforetheequipmentisplacedinservice.ABBdoesnottakeanyresponsibilityforpossible
damagecausedbyusingthematerialinthisapplication(shownexamples,data,projecttools,etc.).
Safetyinstructions
Followallsafetyinstructionsdeliveredwiththeusedcomponents:
Readthecompletesafetyinstructionsfortheuseddrivebeforeyouinstall,commissionorusethedrive.
Thecompletesafetyinstructionsaregivenatthebeginningofthedrivesusersmanual(e.g.forACS355:
3AUA0000066143[English]).
Read all safety and installation instructions of the used PLC. See the online help in CoDeSys (Help
ContentsTargetSystemAC500/S500IntroductionOverviewRegulations).
Limitations
Thefollowinglimitationsarevalidforthisguide:
General
o AllinstructionsinthisguidearebasedondefaultsettingsinPLCanddrives
o PS501ControlBuilderPlusversion2.2.0orlater
o ThedrivemustbeequippedwithembeddedModbusRTUoraModbusRTUadapter
FunctionblockandvisualizationlibraryPS553DRIVEScompatibility
o Communicationprofile:ABBdrives
o Drivetypes:AllModbusRTUcompatibleABBACSdrives
o Applicationtypes:Speed/FrequencycontrolorTorquecontrol
ModbusRTU 4 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
Setupexample
ControlBuilderPlus
ETHERNETor
serialconnection
AC500PLC
ABBACSDrives
ABBModbus
RTUmodules
orembedded
ModbusRTU
ModbusRTU 5 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
Hardwarephysicalconnection
Inthefollowingchapter,physicalconnectionofthehardwarewillbeexplained.
Fieldbusgrounding
For AC500, which has optoisolated COM interfaces, it is recommended not to connect the ground. For AC500
eCo, where the COM interfaces are not optoisolated, it is recommended to connect the ground at one place,
typicallyinthebusmaster.Forconnectionexamples,seechapterInstallationexamples.
Fieldbusshield
TheshieldshouldalwaysbeconnectedinaModbusRTUline.ThepurposeoftheshieldistoprotectagainstEMC
disturbancesandreflectiononthebusline.Forconnectionexamples,seechapterInstallationexamples.
Endtermination
Purpose:Toavoidsignalreflections.
Resistorsize:120Ohms,W.
Wheretoconnect:Oneresistorineachendofthebusline(firstandlastnode).
Pullup/pulldownresistors
Purpose:Tokeepadefinedhighlevelonthebuswhilethereisnodataexchange.
Resistor size: Depends on bus master (COM) voltage level. 470 for AC500(5 V output) and 270 for
AC500eCo(3.3Voutput).
Wheretoconnect:Activatepullupandthepulldownresistors,butonlyonceoneverybusline,atthebus
master.
ModbusRTU 6 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
AC500andAC500eCoCOMportoverview
AC500 AC500eCo CM574RS
COM1 COM2 COM1 COM2 COM1=COM2
(optional) (seeCOM1of
AC500,exceptpull
up/pulldown)
COMVoltagelevel 5V 5V 3,3V 3,3V 5V
Optoisolated YES YES NO NO YES
(electricallyisolated) optional*)
Maximumbuscable Acc.toRS485 Acc.toRS485 50m 50m Acc.toRS485
length standard standard *)Accto standard
RS485
standard
Connection Terminal 9poleDsub 9poleDsub Terminal Terminal
*)Terminal
Terminationresistor NO NO NO NO NO
builtin
Terminationresistor 120 120 120 120 120
size
Pullup/pulldown YES(connect NO NO YES(connect YES(connectwith
resistorsbuiltin withbridges) *)yesconnect withbridges) bridges)
withbridges
Pullup/pulldown 470 470 270 270 475
resistorsize
Pullup/pulldown Master(CPU) Master(CPU) Master(CPU) Master Master(CPU)COM
resistorsconnection COMport COMport COMport (CPU)COM port
point port
Pullup/pulldown Bridges:1to External470 External270 Bridges:1to Bridges:1to2and3
connection 2and3to4 resistors resistors 2and3to4 to4
*)usingTK506RS485isolatorforPM554/PM564withindexA3andhigher
Driveswithembeddedfieldbus
ThefollowingABBdriveshaveModbusRTUembedded:
ACS310
ACS/ACH550
ACS850
Since the builtin end termination of the drive automatically also activates pullup/pulldown resistors, it is
recommendedtoskipthebuiltinoption.
Itisrecommendedtoconnectaseparateendterminationresistortothefirstnode(i.e.thePLCCOMinterface)
andthelastnode(i.e.thelastdriveonthebus).
Forconnectionexamples,seechapterInstallationexamples.
ModbusRTU 7 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
FieldbusmodulesforABBdrives
The following ABB drives Modbus RTU modules have an option to activate builtin end termination and pull
up/pulldownresistors.
RMBA01(usedwithforinstanceACS550andACS800)
FSCA01(usedwithforinstanceACS880andACSM1)
ThefollowingABBdrivesModbusRTUmoduledoesnothaveanoptiontoactivatebuiltinendresistorsincluding
pullup/pulldownresistors.
FMBA01(usedwithforinstanceACS355)
Since the builtin end termination of the modules (RMBA01 and FSCA01) automatically also activates pull
up/pulldownresistors,itisrecommendedtoskipthebuiltinoption.
Itisrecommendedtoconnectaseparateendterminationresistortothefirstnode(i.e.thePLCCOMinterface)
andthelastnode(i.e.thelastdriveonthebus).
Forconnectionexamples,seechapterInstallationexamples.
Commonrecommendations
Note!Thefollowingbulletsareonlyrecommendationsandnogeneralrules.
Installationwheretotalcablelengthismorethan50m
o UseCPUAC500ratherthanAC500eCoorAC500eCowithTK506RS485isolatorforCOM1.
Installationwherethereisariskthatgroundconnectionsindifferentnodescouldvaryinvoltagepotential
(typicallyinshipinstallationsorwithcablelengthsmorethan50m).
o UseCPUAC500anddonotconnectgroundcable,onlyshield2wiresolution,oruseAC500eCo
withTK506RS485isolatorforCOM1.
WhenAC500eCoisused
o Use of 3wire connection is recommended because the COM interface is not optoisolated,
oruseAC500eCowithTK506RS485isolatorforCOM1.
o Use of cable length more than 50m should be realized with repeaters,
oruseAC500eCowithTK506RS485isolatorforCOM1.
Cabletype
o Use only cables with twisted pair wires and braided shields. Foil shields are not robust enough,
cannotbecontactedwellandhavepoorHF(HighFrequency)properties.
o Groundthecableshielddirectlywithaclipwhenenteringtheswitchgearcabinet.Donotcutthe
shielduntilthecablereachestheconnectedmodule.
o TheconnectionbetweenthePEbarandtheshieldbarmusthavelowimpedance.
o UseABBcableTK505whensuitableforeasyinstallation.
ModbusRTU 8 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
Busline
Construction 2cores,twisted,withcommonshield
Conductorcrosssection >0.22mm2(24AWG)
recommendation 0.5mm2correspondsto0.8mm
Twistingrate <10/meter(symmetricallytwisted)
Coreinsulation Polyethylene(PE)
Resistancepercore <100/km
Characteristicimpedance Appr.120(100150)
Capacitancebetweenthecores <55nF/km(ifhigher,thenmaxbuslength
mustbereduced)
Terminatingresistors 120,Watbothlineends
Remarks CableswithPVCcoreinsulationandacore
diameterof0.8mmcanbeuseduptoa
lengthofappr.250m.Inthiscase,thebus
terminatingresistorisappr.100.
ABBcableTK505
ForaneasyModbusinstallationintheCPUend,thepremadeABBcableTK505canbeused.Itincludesa9poleD
sub contact with builtin end termination (120 ) and pullup/pulldown resistors (2*270 ). This contact is
suitableforAC500eCoCOM1.ItcanalsobeusedforAC500COM2(eventhoughanothervoltagelevelisused),
butonlyiftheGNDwireisnotconnectedtotheModbusslaves(2wiresolution,preferredforAC500COMports).
ModbusRTU 9 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
Installationexamples
Bestconnectionofshieldistoconnectdirectlytothemountingplateofthecabinetasnearaspossibletothe
AC500.Themountingplatehastobeconnectedtocommonearthinthecabinetatonepoint.
or
ModbusRTU 10 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
AC500COM1Masteratthebuslineend
AC500COM2Masteratthebuslineend
AC500eCoCOM1Masteratthebuslineend
ModbusRTU 11 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
AC500eCoCOM2Masteratthebuslineend
ModbusRTU 12 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
Driveconfiguration
DriveswithoutembeddedModbusRTUneedtobeequippedwithModbusRTUadapteraccordingtoactualdrive
type.
ThefollowingdriveconfigurationstepswilladaptthedrivetoModbusRTUcontrolbasedonABBspecificdrives
libraryPS553DRIVES.
Driveparameterscanbesetfromthedrivescontrolpanelorfromdrivespecificpctool(DriveWindowLightfor
ACS355andACS550,DriveStudioforACS850andACSM1,DriveComposerforACS880andDriveWindowfor
ACS800).
Note!Allparametersettingsarebasedondrivedefaultsettings.Ifthedrivehasbeenparameterizedpreviously,
returntodefaultsettingsbeforecontinuing.Itcanbedoneby:
Changingmacro(andthenchangingbackagain)inparameter99.02forACS310,ACS355andACS550.
Settingparameter99.03APPLICRESTOREtoYESinACS800.
Settingparameter16.04ParamrestoretoRestoredefsinACS850andACSM1.
Settingparameter96.06ParameterrestoretoRestoredefaultsinACS880.
ModbusRTU 13 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
StartingupACS310driveswithembeddedModbusRTU
Minimumrequiredparametersettings(basedonfactorydefaultsettings)
Parameter Description Setting Comment
Optionalparametersettings
30.18 COMMFAULT [optional] Howthedrivereactstoafieldbuscommunication
FUNC break.
30.19 COMMFAULTTIME [optional] Timebetweencommunicationbreakdetectionand
theselectedaction.
(11.05) REF1MAX [Scalemax] Maxspeed/frequencyscalingvalue(usedinfunction
block/visualizationinputSPEED_REF_MAX).Must
belessorequaltodriveparametermax
speed/frequency.
ModbusRTU 14 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
StartingupACS355driveswithFMBA01ModbusRTUadapter
Minimumrequiredparametersettings(basedonfactorydefaultsettings)
Parameter Description Setting ApplicMacro Comment
AC500
MODBUS*)
Optionalparametersettings
30.18 COMMFAULT [optional] FAULT Howthedrivereactstoafieldbus
FUNC communicationbreak.
30.19 COMMFAULTTIME [optional] Default:.3s Timebetweencommunicationbreakdetection
andtheselectedaction.
(11.05) REF1MAX [Scalemax] Maxspeed/frequencyscalingvalue(usedin
functionblock/visualizationinput
SPEED_REF_MAX).Mustbelessorequalto
driveparametermaxspeed/frequency.
*)inPar.99.02theApplicationMacrocanbesettoAC500Modbus(10)thentheparametersareautomatically
setasshown.
ModbusRTU 15 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
StartingupACS550withembeddedModbusRTU
Minimumrequiredparametersettings(basedonfactorydefaultsettings)
Parameter Description Setting Comment
Optionalparametersettings
30.18 COMMFAULT [optional] Howthedrivereactstoafieldbuscommunication
FUNC break.
30.19 COMMFAULTTIME [optional] Timebetweencommunicationbreakdetectionand
theselectedaction.
(11.05) REF1MAX [Scalemax] Maxspeed/frequencyscalingvalue(usedinfunction
block/visualizationinputSPEED_REF_MAX).Must
belessorequaltodriveparametermax
speed/frequency.
ModbusRTU 16 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
StartingupACS800driveswithRMBA01ModbusRTUadapter
Minimumrequiredparametersettings(basedonfactorydefaultsettings)
Parameter Description Setting Comment
Optionalparametersettings
30.18 COMMFLTFUNC [optional] Howthedrivereactstoafieldbuscommunication
break.
30.19 MAINREFDST [optional] Timebetweencommunicationbreakdetectionandthe
OUT selectedaction.
(11.05) EXTREF1 [Scalemax] Maxspeed/frequencyscalingvalue(usedinfunction
MAXIMUM block/visualizationinputSPEED_REF_MAX).Mustbe
lessorequaltodriveparametermaxspeed/frequency.
ModbusRTU 17 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
StartingupACS850,ACQ810driveswithembeddedModbusRTU
Minimumrequiredparametersettings(basedonfactorydefaultsettings)
Parameter Description Setting Comment
Optionalparametersettings
58.07 Commlosstout [optional] DefinesthetimeoutlimitfortheEFB
communicationmonitoring.
58.08 Commlossmode Noneor Enables/disablesEFBcommunicationloss
AnyMessage
monitoringanddefinesthemeansforresetting
thecounterofthecommunicationlossdelay.
58.09 Commlossaction [optional] DefinesthedriveoperationaftertheEFB
communicationlossmonitoringawakes.
58.10 Refreshsettings [optional] Refreshesthesettingsofparameters
58.0158.09.
(19.01) Speedscaling [Scalemax] Maxspeed/frequencyscalingvalue(usedinfunction
block/visualizationinputSPEED_REF_MAX).Must
belessorequaltodriveparametermax
speed/frequency.
ModbusRTU 18 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
StartingupACS880driveswithFSCA01ModbusRTUadapter
Minimumrequiredparametersettings(basedonfactorydefaultsettings)
Optionalparametersettings
50.02 FBAAcommloss [optional] Definesthedriveoperationafterthe
func communicationlossmonitoringawakes.
51.06 MODBUSTIMEOUT [optional] Timebetweencommunicationbreakdetection
andtheselectedaction.1=100ms.
51.07 TIMEOUTMODE CONTROL Howthedrivereactstoafieldbuscommunication
WRITE break.
51.27 FBAPARREFRESH REFRESH Updatesfieldbussettings(groups50to53)
ModbusRTU 19 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
StartingupACSM1driveswithFSCA01ModbusRTUadapter
Minimumrequiredparametersettings(basedonfactorydefaultsettings)
Parameter Description Setting Comment
Optionalparametersettings
51.06 MODBUSTIMEOUT [optional] Timebetweencommunicationbreakdetection
andtheselectedaction.1=100ms.
51.07 TIMEOUTMODE CONTROL Howthedrivereactstoafieldbuscommunication
WRITE break.
50.02 COMMLOSSFUNC [optional] Definesthedriveoperationafterthe
communicationlossmonitoringawakes.
51.27 FBAPARREFRESH REFRESH Updatesfieldbussettings(groups50to53)
ModbusRTU 20 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
Installdriveslibrary
Note!InControlBuilderPlusV2.3andlater,theACSDrivesBaselibraryisalreadyinstalled.Youcanfinditinthe
subfolderPS553DRIVESofthedefaultlibraryfolder(seeleftpicturebelow)
Note! The version of the library can differ, nevertheless the name will stay the same! Creation date and main
changescanbeseeninthelibrarymanagerofCODESYSonly.
ForolderVersionsofControlBuilderPlusyoucandownloadtheinstallationpackageinthefollowingwayfrom:
o www.abb.com/PLC:
o On right side menu under heading "Your preferences": Select "English" as language ... (country doesnt
matter).
o Onrightsidemenuunder"MoreInfoLinks":Clickon"PS501Updates".
o Select"PS501UPDA:PS553DRIVES"todownload*.zipfile.
InstallthedriveslibraryPS553DRIVESwithreadymadefunctionblocksandvisualizationobjectsbyunzippingto
atemporarydirectoryandclickingonthefilesetup.exe(seerightpicturebelow).
ModbusRTU 21 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
ControlBuilderPlusforPLCandDrives
StarttheControlBuilderPlusPCtoolforPLCconfigurationandgothroughthefollowingsteps.
Hardwareconfiguration
File New Project Choose AC500 project and name the project. Choose PLC device according to your
equipmentandthenAdddevice.
Doubleclick CPU_parameters and configure according to your application. Set for instance Check battery =
OffifyourCPUdoesnothaveabatteryinstalled.
RightclickactualCOMinterface(COM1isusedintheexample)andclickPlugDevice.SelectCOMXModbus
andclickPlugDevice.
ModbusRTU 22 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
DoubleclickCOMX_ModbustoconfiguretheModbussettings.Doatleastthefollowingsettings:
SetBaudrate,Parity,DatabitsandStopbits(1)accordingtosettingsinactualdrive.
SetOperationmodetoMasterandAddressto0(2).
SetRTScontroltoTelegram(3)
(=RS485inAC500eCothisisalreadyset)
ModbusRTU 23 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
IPconfigurationofCPU(forEthernetconnectionbetweenPCandPLC)
IftheCPUhasanEthernetportandtheCPUIPaddresshasnotalreadybeenconfigured,followthestepsbelow.
Deactivate the firewall of the PC, or allow the connection if question comes up. Connect an Ethernet cable
betweenPCandPLC(orviaaswitch).
OpentheIPconfigurationtoolfromtheToolsmenuandpresstheScanbutton.
SelectactualPLCfromthescannedobjects(1),makeyournetworksettings(2)andpresstheSendConfiguration
button. This needs to be done the first time you connect to the PLC even if the IP address is already correct.
Note!ThePLCneedstobeinSTOPmodeforIPconfiguration.
AfterthenewconfigurationwassentthePLCwillautomaticallyreboot.
ModbusRTU 24 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
CODESYS
DoubleclickAC500fromtheDevicetreeintheControlBuilderPlusprojecttoopenCODESYS.
CODESYStabs
InCODESYStherearefourdifferenttabsforprogramming,configuration,etc.
1. POUs(ProgramOrganizationUnits):ThistabcontainsyourFunctions,FunctionblocksandPrograms.
2. Data types: In this tab, along with the standard data types you can define your own userspecific data
types.
3. Visualizations:Inthistabyoucancreateyourownorusepredefinedvisualizationstodisplayyourproject
variablesgraphically.InOnlinemode,thesecanthenchangetheirform,color,text,position,output,etc.
inresponsetospecifiedvariablevalues.
4. Resources: In this tab you can configure and organize your project. It includes Global variables, Library
manager,etc.
ModbusRTU 25 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
LibraryManager
Open the Library Manager by doubleclicking Library Manager from the Resources tab. Rightclick in the
libraryfieldandchooseAdditionalLibrary.
Note! When copying projects the used libraries must be found on the same library path as on the original PC.
Otherwiseawarningwillshowthatalibrarycannotbefound.Ifso,thisredmarkedlibraryhastobedeletedand
addednewlyfromthenowdifferentpathtotheproject.
ModbusRTU 26 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
PLClogic
ThefollowingprogramhandlesaSpeedcontroldriveapplication.
Compileyourproject,chooseRebuildallfromtheProjectmenu.
RightclickPLC_PRGinthePOUstabandchooseConvertObject.ChooseTargetLanguageFBDandclick
OK.
RightclickinthePOUsfieldandchooseAddObject.SetTypeofPOUtoProgramandLanguageofthePOUto
FBD,givethenewProgramasuitablenameandclickOK.
ModbusRTU 27 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
DoubleclickPLC_PRG(1)toopenthemainprogram.Selectthedottedbox(2)inNetwork0001andinsertabox
(3).WritethenameofyournewProgram(Drive1(PRG)intheexample)tocallforitfromthemainprogram.
Doubleclick your new program and add a box as described above. This time, press F2 while the block title is
selected and choose ACS_COM_MOD_RTU from Standard Function Blocks, then click OK (Tip: untick the
StructuredboxintheInputassistant).
Give the instance of the drive access block a suitable name (1) and declare the variable of type
ACS_COM_MOD_RTU(2)(automaticsuggestion).
ModbusRTU 28 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
Doubleclick Global_Variables in the Resources tab (1) and create a global variable for the Modbus token
handling of type ACS_MOD_TOKEN_TYPE (2). This variable will be used for connecting the drive to a certain
Modbusline.
Note!Thisvariableshouldbeglobal(Onesinglevariableusedforalldrives).
Open the program again from the POUs tab and connect the function block inputs and outputs according to
yourneeds.Intheexamplebelow,theblockwillalwaysbeenabled,COMport1ofthePLCisused,thedrivehas
Modbus node number 1, default timeout 1000 ms is used, drive type is ACS355, no extra parameters besides
StatuswordandActualspeed/torquearereadfromthedrive.
Tip! Click inside the name of the function block and press F1 toopen the description of the block in the online
help.
ModbusRTU 29 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
ModbusRTU 30 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
Createasecondnetwork(Ctrl+T)inthesameprogramandaddtheblockACS_DRIVES_CTRL_STANDARDinthe
samewayasforACS_COM_MOD_RTU.Connectthefunctionblockinputsandoutputsaccordingtoyourneeds.
Intheexamplebelow:
Theblockwillalwaysbeenabled
ThedriveisstartedbythevariableDriveStart
Emergencystopfunctionsarenotusedinthisexample
RampstopbysettingDriveStart=FALSE
CoaststopbysettingDriveCoastStop=TRUE
FaultresetbysettingDriveResetFault=TRUE(positiveedge).
Speed reference is set by the variable SpeedRef as a value between 20000 and 20000, where 20000
correspondstoaparameterinthedrive(seechapterDriveconfiguration).
The variables declared between VAR and END_VAR in the picture below are local variables inside this
program.(Toaccessthemfromanotherparte.g.anyvisualizationtheprogramsnamehastobeusedfollowedby
adotandthevariablesname.E.g.Drive1.DriveOperating
Note!ThevariableconnectedtoACS_DRIVES_CTRL_STANDARDDRIVE_DATAmustbethesameastheone
connectedtoACS_COM_MOD_RTUDRIVE_DATAandmustbeoftypeACS_DRIVE_DATA_TYPE.
ModbusRTU 31 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
DownloadprogramtoPLC
Save the program and choose Communication Parameters from the Online menu. Set communication
Parametersaccordingtoyouronlineconnection.Intheexamplebelow,theAddress192.168.0.10corresponds
tothe IPaddressofactualCPUandis alsothedefaultIPaddressofAC500CPUs.Note thatin caseofEthernet
connection, the IP address of your PC port or Ethernet adapter should belong to the same subnet as the CPU,
192.168.0.XXX(XXXbetween1and255).
ChooseLoginfromtheOnlinemenuandinthefollowingpopupwindow,clickYes.ThenchooseRunfrom
theOnlinemenutostartthePLC.CheckthatthePLCgoestoRUNmodeinthePLCdisplayorled.
Note!IfthePLCdoesnotgotoRUNmode,youmighthavesomePLCerrorsthatyouneedtoreset.Youcando
that either by pressing the DIAG button on the PLC itself (not in the eCo series) followed by the OK button
until all errors are reset. You can also do it in online mode by using the diagreset command from the PLC
BrowserintheCODESYSResourcestab.
ModbusRTU 32 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
Createbootproject
In online mode (Login), choose Create boot project from the Online menu. With this command, the
compiledprojectisstoredtotheflashinsuchawaythatthePLCwillloaditautomaticallywhenrestarted.
ModbusRTU 33 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
Testtheprogram
Ifthedrivehasanactivefault(TRIPPEDoutputiscoloredblue)(1),thentrytoresetbysettingtheRESETinput
=TRUE(2).DoubleclicktheinputvariableandchooseWriteValuesfromtheOnlinemenu(3).
When the READY output is TRUE (blue) (1), then set the SPEED_REF input (2) to desired speed value and
STARTinput=TRUE(3).WritevaluesfromtheOnlinemenuorCtrl+F7.Checkthatthedrivestartsandfollows
thegivenspeedreference.
Note!SpeedreferenceissetintheblockinputSPEED_REFasavaluebetween20000and20000,where20000
correspondstoaparameterinthedrive(seechapterDriveconfiguration).
ModbusRTU 34 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
ModbusRTU 35 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
ReadandwritemoredatabetweenPLCanddrive(optional)
While the already implemented function block ACS_COM_MOD_RTU has builtin functionality to read more
data/parameters from predetermined Modbus register addresses in the drive, the function blocks
ACS_MOD_READ_N_PRMandACS_MOD_WRITE_N_PRMcanreadandwritedata/parametersfromModbus
registeraddressesaccordingtouserchoice.
ExampleReaddrivedatawithACS_COM_MOD_RTU
ValuesarereadfromModbusregisteraddresses40007..40030.Thenumberofreadparametersdependsonthe
functionblockinputNVAR_READ.Configurationisforinstancemadeinparameters53.12to53.17forACS310,
ACS355 and ACS550, or in parameters 58.35 to 58.58 for ACS850 and ACQ810. The supported number of
parametersthatcanbereadinthiswaydependonactualdrivetype,forinstance6parameterscanbereadfrom
ACS355or24parameterscanbereadfromACS850.
Additionalparametersettingsinthedrivearenecessary,seeexamplebelowwithanACS355drive:
53.12=107Modbusregister40007willconsistofACS355parameter1.07DCvoltage.
53.13=110Modbusregister40008willconsistofACS355parameter1.10Drivetemp.
53.14=120Modbusregister40009willconsistofACS355parameter1.20Analoginput1.
Note!Aftertheseparametersettings,thedriveneedsareboot(poweroff/poweron)toactivatethesettings.
SetACS_COM_MOD_RTUblockinputNVAR_READaccordingtonumberofparameterstoberead(1).Createa
newvariableconnectedtoblockoutputREAD_VALUES(2)andpressthebutton (3)tosetthevariableof
typeARRAY(4)ofINT.GivethearrayStartindex1andEndindex24(5),pressOK.
ModbusRTU 36 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
Theparametervaluesfromthedrivearethenwrittentothenewarrayvariable(6).
ModbusRTU 37 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
ExampleReaddrivedatawithACS_MOD_READ_N_PRM
ValuesarereadfromModbusregisteraddressesaccordingtouserchoice.Noadditionalparametersettingsinthe
drivearenecessary.
Createanewnetworkinthesameprogram(POU)andaddtheblockACS_MOD_READ_N_PRM.
ModbusRTU 38 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
Setfunctionblockinputsaccordingto:
EN=TRUE(1)Theblockwillalwaysbeenabled.
PRIO=Leftunconnected.
NVAR=Numberofparameterstoberead(2)2parameterswillbereadinthisexample.
PRM_NUM=Startaddressofparameterstoberead(3)parameters12.02and12.03willbereadinthis
example.
DATA is connected via an ADR block to a new variable (4). Press the button (5) and choose type
ARRAY(6),setStartindexto1andEndindextothenumberofvaluestoberead,2inthisexample(7).
SettypetoINT(8)andpressOK.
DRIVE_DATA=ThesamevariablethatisconnectedtoACS_COM_MOD_RTUDRIVE_DATA(9).
ModbusRTU 39 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
Note!SeveralACS_MOD_READ_N_PRMblockscanbeactivatedatthesametime.Seeexamplebelow.
ModbusRTU 40 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
ExampleWritedrivedatawithACS_MOD_WRITE_N_PRM
ValuesarewrittentoModbusregisteraddressesaccordingtouserchoice.Noadditionalparametersettingsinthe
drivearenecessary.
Createanewnetworkinthesameprogram(POU)andaddtheblockACS_MOD_WRITE_N_PRM(1).
Setfunctionblockinputsaccordingto:
ENisconnectedtoanexecutevariableoftypeBOOL(1).Atrisingedgethevariableiswrittenonce.
PRIO=Leftunconnected.
NVAR=Numberofparameterstowrite(3)2parameterswillbewritteninthisexample.
PRM_NUM=Startaddressofparameterstobewritten(4)parameters12.02and12.03willbewritten
inthisexample.
DATA is connected via anADR block to a new variable (5) of type ARRAY [1..X] OF INT according to
instructionsfortheACS_MOD_READ_N_PRMblock.
DRIVE_DATA=ThesamevariablethatisconnectedtoACS_COM_MOD_RTUDRIVE_DATA(6).
ModbusRTU 41 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
Note!SeveralACS_MOD_WRITE_N_PRMblockscanbeusedintheprogram.Seeexamplebelow.
Note!ThevariableisonlywrittenatarisingedgeoftheENinput.
ModbusRTU 42 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
Visualizations
VisualizationsareoptionalandcanbeagoodwaytotestthecommunicationbetweenPLCanddrive.Gooffline
(Logout from the Online menu). Rightclick Visualizations in the Visualizations tab (1) and choose Add
Object,givethevisualizationpageasuitablename.Fromthenewpage,chooseVisualizationfromtheInsert
menuanddrawabox.SelectVisualizationACS_COM_MOD_RTU_VISU_PH.
DoubleclickthenewvisualizationobjectforSettingsandclickPlaceholder.SelecttheReplacementfieldand
pressF2.
ModbusRTU 43 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
To make a connection to the instance of the function block ACS_COM_MOD_RTU, choose the instance from
actualprogram(PRG)andclickOKuntilallpopupwindowsareclosed.
Tip!TicktheStructuredboxintheInputassistantwindowforabetteroverview.
On the same page, create a visualization window for the drive control. Insert Visualization Select
ACS_DRIVES_CTRL_STANDARD_VISU_PHdoubleclickthenewobjectandclickPlaceholderPressF2from
theReplacementfield ChoosetheinstanceoffunctionblockACS_DRIVES_CTRL_STANDARD clickOK
untilallpopupwindowsareclosed.
ModbusRTU 44 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
GoonlineagainbychoosingLoginfromtheOnlinemenuandthenRunfromthesamemenu(ifthePLCis
notalreadyinrunmode).
Thestatusofthefunctionblockinputsandoutputsarenowdisplayedinthevisualizationwindow.Blockinputs
which have not been connected to the function blocks in the program PRG can be changed from the
visualizationwindow.
Someexamplesofwhatcanbeseeninthevisualization:
READY:ifthedriveisreadytostart.
OPERATING:ifthedriveisoperating(magnetizingthemotor).
TRIPPED:ifthedrivehasanactivefault.
ACT_SPEED:actualspeedvalue.
ACT_SW:actual16bitStatusWordfromthedrive.
USED_CW:actual16bitControlWordsentfromthePLCtothedrive.
MESSAGEfield:informationabouttheactualstate,e.g.OperationorWaitforrisingedgeofSTART.
ModbusRTU 45 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
GoofflinebychoosingLogoutfromtheOnlinemenu.
Addmoredrives(optional)
IntheCODESYSPOUstab,rightclicktheprogramforyourearlierdriveandchooseCopyObject,givethenew
program a suitable name and doubleclick PLC_PRG. Add the new program to the main program by copying
Network0001toNetwork0002andrenametheblockinNetwork0002toaccordingtoyournewprogram.
Doubleclickandopenthenewprogram.ChangeSLAVEnumberoftheACS_COM_MOD_RTUblockaccording
totheModbusRTUnodeaddressofactualdrive.
Continuetoaddasmanydrivesasyouneed.Ifyouwanttocreatevisualizationpages/objectsfortheadditional
drives,makesurethatyouconnectthePlaceholderstothefunctionblockinstancesforthecorrectprogram(PRG),
Drive2inthisexample.
ModbusRTU 46 PLCanddrivesintegration
Quickstart Guide
ABB PLC and drives integration using Modbus RTU
Actualizationrate
BeawarethatonaModbusRTUlineonlyoneModbusjobisperformedatatime.Thatmeansthattheupdate
rate of the variables increases with the number of active Modbus blocks, such as ACS_COM_MOD_RTU,
ACS_MOD_READ_N_PRMofACS_MOD_WRITE_N_PRM.
TheACS_COM_MOD_RTUfunctionblockautomaticallyreadstheactualdataallthetimeandexecutesawritejob
eachtimetheControlWordorthereferencevalues(speedortorque)havechanged.
Otherusefuldocumentation
CODESYSHelp(ContentsTargetsystemAC500/S500ACSDrivesLibraries)
UsersmanualModbusAdapterModuleFMBA01 [3AFE68586704]
UsersmanualModbusAdapterModuleRMBA01 [3AFE64498851]
ModbusProtocolManualRS485AdapterModuleFSCA01 [3AUA0000044530]
UsersmanualACS355drives [3AUA0000066143]
ACS850FirmwareManualStandardControlProgram [3AUA0000045497]
ACQ810FirmwareManualStandardPumpControlProgram [3AUA0000055144]
FirmwaremanualACS880primarycontrolprogram [3AUA0000085967]
ACSM1FirmwareManualSpeedandTorqueControl [3AFE68848270]
ACSM1FirmwareManualMotionControl [3AFE68848270]
UsersManualACS55001Drives [3AUA0000001418]
FirmwareManualACS800StandardControlProgram [3AFE64527592]
Revision
ModbusRTU 47 PLCanddrivesintegration
For more information please contact your local ABB Copyright 2012 ABB. All rights reserved.
Specifications subject to change without notice.
representative or visit:
www.abb.com/drives
www.abb.com/drivespartners