0% found this document useful (0 votes)
3K views

Modbus Configuration Example For An Allen Bradley Micrologix 1400 - Mesta Automation PDF

Latest PLC Allen Bradley Micrologix 1400 is provided with Modbus TCP and RTU. This is a powerful feature and with this post I explain how to enable and how to use it. To configure the Modbus communication you need to know at least the basic information about Modbus protocol.

Uploaded by

FernandoCamargo
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
3K views

Modbus Configuration Example For An Allen Bradley Micrologix 1400 - Mesta Automation PDF

Latest PLC Allen Bradley Micrologix 1400 is provided with Modbus TCP and RTU. This is a powerful feature and with this post I explain how to enable and how to use it. To configure the Modbus communication you need to know at least the basic information about Modbus protocol.

Uploaded by

FernandoCamargo
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 7

26/09/2015

Home

ModbusconfigurationexampleforanAllenBradleyMicrologix1400MestaAutomation

PLC

WPF

C#

Downloads

About

SubscribebyEmail SubscribetoRSS

Youarehere:Home>ModbusconfigurationexampleforanAllenBradleyMicrologix1400

ModbusconfigurationexampleforanAllenBradley
Micrologix1400
by Mesta on JUNE 19, 2012 in ALLEN BRADLEY, PLC

MOSTPOPULAR

Modbus with C#: libraries, code,


utilities and examples
Communication with Siemens S7 Plc
with C# and S7.Net plc driver

Tweet

Like

Share

Share

Modbus configuration example for an


Allen Bradley Micrologix 1400

ThelatestPLCAllenBradleyMicrologix1400isprovidedwithModbusTCPandRTU.Thisis
apowerfulfeatureandwiththispostiexplainhowtoenableandhowtouseit.
ToconfiguretheModbuscommunicationyouneedtoknowatleastthebasicinformation
aboutModbusprotocol.

Real-time Line charts with WPF and


Dynamic Data Display
PLC-PC communication with C#: a
quick resume about data exchange
libraries

Quick overview of Modbus protocol


Modbusprotocolcanbeusedwithserialcables(ModbusRTU:RS232orRS485)orwith
ethernetcable(ModbusTCP).
ModbusTCParchitectureisclientserver(likeforwebsites,youwiththebrowserare
theclientthataskinformationtotheserver,andtheserverreply).ModbusTCPdevicescan
bebothclientserverandtheprotocolismultimaster,soeverydevicecanstartthe
communication.
ModbusRTUarchitectureismasterslave(masteristheclient,slaveistheserver).The
onlydevicethatcanstartacommunicationisthemasterandtherecanbeonlyonemaster

RoboticCase
Packer
CallTodaytoDiscussYour
RoboticCasePackingNeeds!

(usuallyasupervisor)andasmanyslaveasyouwant.EveryslavehasaNodeaddress,so
themastercansendpackettoasingleslave.MasterdoesnothavetheNodeaddress.

The registers

Weusecookiestoensurethatwegiveyouthebestexperienceonourwebsite.If
youcontinuetousethissitewewillassumethatyouarehappywithit.

Youhave4typesofregisters:

Ok

FOLLOWMESTAAUTOMATION

2arereadonly(forbitsandintegers)
2arereadableandwritable(forbitsandintegers)
Booleanblockes.B3:
ReadOnlyregistersarecalledContacts.
Read/WriteregistersarecalledCoils.
Numericblockes.N7:
ReadOnlyregistersarecalledInputRegisters.
Read/WriteregistersarecalledHoldingRegisters.

Enabling Modbus TCP:

MestaAutomation
59likes

LikePage

80

subscribers

Share

12

followers

RECENTPOSTS

Communication with Siemens S7 Plc


with C# and S7.Net plc driver
Create DPI-aware and resolutionaware WPF applications
WPF touch-friendly controls for
resistive touch-screen
Snap7: an open source Siemens S7
communication library

http://www.mestaautomation.com/modbusconfigurationexampleforanallenbradleymicrologix1400/

1/7

26/09/2015

ModbusconfigurationexampleforanAllenBradleyMicrologix1400MestaAutomation
OxyPlot: a new open source chart
library for WPF

RECENTCOMMENTS

Cesar Sosa Zuiga


Hi, I've
been working with a simiens s7
1200 and a C# interface but i...
Sep 25, 7:30 PM
mesta
Hi Jblee, there is a
maximum limit on the size of the
DB and unfortunately... Sep 20,
7:34 PM

Importantnote:onceyouflagModbusTCPandsavetheconfiguration,youshouldpowerup
thePLCagain.

Enabling Modbus RTU Slave


ToenableModbusRTUyouhavetoconfigurechannel2asModbusRTUSlave.

mesta
Hi Daniela, to get
started with simple
communication you can download
the sources
(https://goo.gl/LeZkbk) and...
Sep 20, 7:24 PM
jblee
Plc.DB1.cs :The following
code was added. PlcTag.cs :The
following code was added.
MainWindow.xaml.cs : The...
Sep 18, 10:26 AM

RoboticCase
Packer
CallTodaytoDiscussYour
RoboticCasePackingNeeds!

Block configuration:
CATEGORIES

C# (24)
Fonts (2)
Graphics (3)
PLC (29)
Scada (2)
WPF (33)

ARCHIVES

Withthisconfigurationihave:
B9:readonly
B10:r/w
N7:readonly
N15:r/w

2015 (1)
January (1)
2014 (3)
2013 (2)
2012 (26)
2011 (4)
2010 (1)

Expandedflag:thisflagpermittouse4moreNregisterscontigoustoN15inorderto
expandtheholdingregistersarea.
ToenableexpandedregistersyouneedtodeclareN15N16N17N18N19andtoset
alltheregisterswordsto256.

http://www.mestaautomation.com/modbusconfigurationexampleforanallenbradleymicrologix1400/

2/7

26/09/2015

ModbusconfigurationexampleforanAllenBradleyMicrologix1400MestaAutomation

Sample code
Youcandownloadasampleapplicationfromhere.
TheprogramhasbeentestedwiththeModbusTCPtesterthatyoucanfindat
http://www.codeproject.com/Articles/16260/ModbusTCPclass.
Tweet

Like

Share

Share

Related

PLCPCcommunicationwith
C#:aquickresumeabout
dataexchangelibraries
In"AllenBradley"

ModbuswithC#:libraries,
code,utilitiesandexamples
In"C#"

ResourcesforSiemensand
AllenBradleyPLCs:PLC
DEVwebsite
In"AllenBradley"

AllenBradley,Modbus,PLC,PLCprogramming
GitHub:GITGUItutorialtogetstartedwithgit
Dataexchangebetween2Controllogixusingproducedandconsumedtags.

29 Responses to Modbus configuration example for an Allen Bradley


Micrologix 1400
graySeptember18,2012at00:01#
HiMesta
Thanksforthenotesmuchappreciated.
WhatversionofRSLogix500areyourunning?Iamrunning8.10.00andnoticedthat
theModbusselectionisnotavailable.Ihaventinstalledamodbussoftwaredriverinto
thePLC,notsureifIhaveto.
Regards
Gray
REPLY

mestaSeptember18,2012at21:26#
IwasrunningRsLogix500version8.40.00.
PleasenotethatModbusprotocolisavailableonlyonMicrologix1400Ser.B.
Micrologix1400Ser.AdoesntprovideModbuscommunication.
REPLY

http://www.mestaautomation.com/modbusconfigurationexampleforanallenbradleymicrologix1400/

3/7

26/09/2015

ModbusconfigurationexampleforanAllenBradleyMicrologix1400MestaAutomation

shridharNovember20,2013at07:05#
8.3rlater
REPLY

ducsiSeptember9,2013at12:35#
HelloMesta,
DoyouknowhowmanyclientconnectionsaMicrologix1400Ser.B.canhandle?
ItrytoconnecttoaPLCfroma2ndPCanditdoesnotwork.
REPLY

mestaSeptember9,2013at13:56#
ItdependsifitsModbusTCPorRTU.
ForModbusTCPiconnectedupto3computerstimeago,butinevertriedwith
more.
ForModbusRTUitdependsiftheMicrologisissetasmasterorslave.
REPLY

sarangSeptember17,2013at08:24#
Himesta,
IhaveMicrologix1400SerBPLC.IhavetoestablishacommunicationwithModbus
TCP&RTU.HowtouseRSLinxClassictoconfiguredriverforthesame?
REPLY

mestaSeptember17,2013at16:01#
RsLinxcantcommunicateinModbus,itusestheproprietaryprotocols
ofRA.
TheethernetportofMicrologixcancommunicatewith2or3protocols
simultaneously,andthesimilEthernet/IPisthedefault,andyoucanchoose
whatotherprotocolyouwanttocommunicatewith,inyourcaseModbus.
SowithRsLinxyousetEthernetDevices(notEthernet/IP,itwillnotwork)and
youcancommunicatewithRsLogix,whilewithyourapplicationsandotherplcs
youcommunicateinModbus.
REPLY

sarangOctober16,2013at10:07#
HiMesta,
WhataboutModbusRTU???WhatIamsupposedtoselectinRsLinxwhile
configuringML1400SerBthroughModbusRTU?Ihavedonechannel
configurationthroughRSLogix500.Butitisunabletoestablisha
communicationlink.
Kindlyrevertback.
REPLY

mestaOctober16,2013at12:25#
IdontrememberiftheserialportofMicrologixcantalk2
differentprotocols.Ifitdoes,thenyouhavetoselectDF1inRsLinx.If
itcancommunicateonlyModbusRTU,youhavetousetheotherserial
portorconnectthroughtheethernetport.

http://www.mestaautomation.com/modbusconfigurationexampleforanallenbradleymicrologix1400/

4/7

26/09/2015

ModbusconfigurationexampleforanAllenBradleyMicrologix1400MestaAutomation

krishnaSeptember19,2013at06:00#
HiMesta,
Iamannewbiein.net,basicallyfromPLC,SCADAdomain.
BigfanofADVHMI,Nowcansomeonesharemeaprojectwheretherealtimedata
fromPLCcanbeloggedtosqlserver.
Iwanttomakeascreenfordataandanotheroneforreports.
Doessomeonehavedonethisinadvancedhmi.
Thanks
Krishnamoorthy
REPLY

HectorQuirozOctober22,2013at17:37#
HelloMesta:
ImworkingwithwebserverembedonMicrologix1400PLCandRSLogix8.40.
ImonitoreddirectoryenabledandN7:0,(eg)
Usingcodes<ABDRTxxx)butonlyforreading,myquestionis:
IsthereanycodewithwhichIcannowwritetothatblock(N7:0)?
Thankyou.
REPLY

mestaOctober22,2013at19:11#
IhavenoexperienceofworkingwithembeddedwebserverofMicrologix
1400.IntheprojectsbasedonML1400wasusingEthernet/IP,OPCclientor
ModbusTCPprotocolswithallofthemiwasusingC#orANSICcompilers.
REPLY

shridharNovember20,2013at07:11#
HImesta
doyouhaveasamplerslogix500plcprogramformodbusTCP/IPcommunicationpls
[email protected]
REPLY

mestaNovember20,2013at10:56#
Actuallyidonthaveaworkingsample,butyoucantestthatifyour
programworksbyusingtheModbusclientthatyoucanfindon
http://www.plcsimulator.org/
REPLY

RohanAugust18,2014at09:09#
Haveyougotsolutionforyourabovesaidquestion?iamworkingonthe
sameifyouhaveanydetailspleasesharewithmealso.
Thankx
REPLY

mestaAugust26,2014at10:56#

http://www.mestaautomation.com/modbusconfigurationexampleforanallenbradleymicrologix1400/

5/7

26/09/2015

ModbusconfigurationexampleforanAllenBradleyMicrologix1400MestaAutomation
ActuallyIdonthavethehardwareneededtomaketests,soicant
makeaprogramandassureyou100%itworks.Atthetimethati
wrotethearticle,iwasworkingonaprojectwheretheML1400was
connectedviaModbusTCPwithotherPLCsanditwasworking.
REPLY

RohanAugust18,2014at09:10#
[email protected]
REPLY

padmarajApril25,2014at02:23#
Imake.Alltheconfigurationasyousaidbutthereisconnectiontimeoutbya
networkthismessageiscomingout
REPLY

padmarajApril25,2014at02:26#
IsthispossibletheChanel0makemodbusRTUandChanel1makemod
busTCPinsameplc
REPLY

AnonymousApril30,2014at16:52#
Mesta,samequestionaspdmaraj:isitpossibletousebothChannel0
(ModbusRTU)andChannel1(ModbusTCP)atthesametime?Mygoalisto
read/writedataonbothchannelsasIdohaveaRS485networkandthePLC
communicateswiththescadausingmodbusTCPTHANKS!
REPLY

mestaMay2,2014at13:22#
AccordingtoRsLogix,itseemsthatyoucanuseModbusRTUonchannel
0.AtleastinmyversionyoucansetModbusontheprotocolinsteadofDF1.
REPLY

PhillMcKieMay20,2014at11:28#
Hi,doyouhaveanyexamplesshowingtheuseofModbusRTUMaster?I
haveanAseries1400andImtryingtoconfigureaRTUmaster
REPLY

AnonymousFebruary11,2015at10:33#
hiiwanttotakeDeltaDTA4848TemperatureControllerDataonAllen
BrdleyML1400orML1100PLC..AnyBodycanpleasetellmethefullprocedure
REPLY

mestaFebruary14,2015at11:47#
Youhavetosetupmessages.Googleformicrologixmessagingmodbus,
thereareplentyofexamples.

http://www.mestaautomation.com/modbusconfigurationexampleforanallenbradleymicrologix1400/

6/7

26/09/2015

ModbusconfigurationexampleforanAllenBradleyMicrologix1400MestaAutomation
REPLY

JoeApril3,2015at19:19#
WhileusingaMicroLogix1400asaserialModbusRTUslaveIamnotableto
findthelocationofthediscreteinputs(contacts).Theyarenotshowingupinthe
1000119999rangeasdocumentationsuggested.Doyouhaveanyideas?Thanks.
REPLY

mestaApril7,2015at07:55#
Didyoutrytochecktheaddressfrom0000to9999?Becauseusually
thefirstnumberisthefunctionidentifier,and1meanscontactaddressarea.
Therearedifferentfunctionsforeachaddressarea(1234etc).
REPLY

SinghApril26,2015at10:09#
DEARALL,
iamfacingproblemtoaccessdataofmasibustemperaturescannerthroughmodbus
TCP/IPonML1400.IfanyoneofyouhavesampleapplicationofML1400
communicationwithanydeviceonmodbusTCP/IPpleasesendmeat
[email protected]
REPLY

kristopherMay8,2015at20:24#
Pleasehelpme!!!
howtosetuptheMl1400rev.bbymodbusTCPlikeaclient?
REPLY

mestaMay11,2015at19:22#
IfML1400hastoreadfromaModbusserver,youcandoitwith
messages.Itshouldntbedifficult,justrunasearchongoogle.
REPLY

Leave a Reply
Enteryourcommenthere...

Copyright 2012 Mesta Automation. All Rights Reserved.

http://www.mestaautomation.com/modbusconfigurationexampleforanallenbradleymicrologix1400/

7/7

You might also like