X1.LY514A.TY.B05M.通讯协议.模块机.V200B3(确定后的文件)

整理文档很辛苦,赏杯茶钱您下走!

免费阅读已结束,点击下载阅读编辑剩下 ...

阅读已结束,您可以下载文档离线阅读编辑

资源描述

空调系统联网方案一、概述.........................................................................................................................................1二、简写定义...................................................................................................................................1三、MODBUS协议描述................................................................................................................13.1综述..............................................................................................................................................13.2字符结构(8,N,2).......................................................................................................................13.3MODBUS数据桢.............................................................................................................................13.4MODBUS协议定义的3种数据桢.................................................................................................13.5MODBUS数据桢长度制约.............................................................................................................13.6MODBUS数据编码.........................................................................................................................23.7MODBUS数据模型.........................................................................................................................23.8MODBUS地址模型.........................................................................................................................23.9MODBUS功能码.............................................................................................................................23.10PUBLICFUNCTIONCODES描述..........................................................................................................33.11错误通讯时的额外应答.............................................................................................................7四、系统应用...................................................................................................................................94.1、网络扑拓图................................................................................................................................94.2、网络通讯的数据........................................................................................................................94.3、通讯协议定义............................................................................................................................94.4、【读写开关量】用户操作命令..............................................................................................104.5、【只读整型量】版本信息......................................................................................................104.6、【只读整型量】公共区信息..................................................................................................114.7、【只读整型量】系统板的信息..............................................................................................124.8、【只读整型量】第N(0~15)个模块信息...........................................................................134.9、【只读整型量】参数属性......................................................................................................164.10、【读写整型量】N组参数.....................................................................................................171一、概述1.1应用范围适用于所有分体式电脑控制系统联网监控。1.2参考资料A、ModbusApplicationProtocol_v1_1.pdfB、VFD-B使用手册C、LG变频器使用说明书D、BAS通讯协议二、简写定义PDUProtocolDataUnit协议数据单元ADUApplicationDataUnit应用数据单元三、MODBUS协议描述3.1综述A.使用MODBUS协议RTU类型,B.采用RS-485多点总线型主从式结构、异步半双工方式,数据长度8位无校验位,波特率为9600bps。(8,N,2forRTU)3.2字符结构(8,N,2)8-databits11-bitscharacterframe3.3MODBUS数据桢协议数据单元(PDU)应用数据单元(ADU)3.4MODBUS协议定义的3种数据桢MODBUSRequestPDU(请求桢):funtion_code-[1byte]+request_data-[nbytes]MODBUSResponsePDU(应答桢):fuction_code-[1byte]+response_data-[nbytes]MODBUSExceptionPDU(额外桢):fuction_code||0x80-[1byte]+exception_code[1byte]3.5MODBUS数据桢长度制约PDU最大长度256bytes。01234567StartbitStopbitStopbitAdditonaladdressFunctioncodeDataErrorcheck23.6MODBUS数据编码例:发送数据0x1234,则先发送0x12,再发送0x34。3.7MODBUS数据模型PrimarytablesObjecttypeTypeofaccessCommentsDiscretesInputSinglebitRead-OnlyThistypeofdatacanbeprovidedbyanI/Osystem.CoilsSinglebitRead-WriteThistypeofdatacanbealterablebyanapplicationprogram.InputRegisters16-bitwordRead-OnlyThistypeofdatacanbeprovidedbyanI/Osystem.HoldingRegisters16-bitwordRead-WriteThistypeofdatacanbealterablebyanapplicationprogram.3.8MODBUS地址模型数据地址从0到65535DeviceapplicationMODBUSdatamodelMODBUSPDUaddresses3.9MODBUS功能码PublicfunctioncodesUser-DefinedfunctioncodesReservedfunctioncodesPublicfunctioncodesUser-DefinedfunctioncodesPublicfunctioncodesUser-DefinedfunctioncodesPublicfunctioncodesDiscreteinputCoilsInputregistersReadinput0Readcoils4Readregisters11...1.51..1..55127110100726513Publicfunctioncodes定义:FuctionCodescodeSubcode(hex)DataaccessBitaccessPhysicalDiscreteInputsReadDiscreteInputs0202InternalBitsOrPhysicalcoilsReadCoils0101WriteSingleCoil0505WriteMultipleCoils150F16bitsaccessPhysicalInputregistersReadInputRegister0404InternalRegistersOrPhysicalOutputRegistersReadHoldingRegisters0303WriteSingleRegister0606WriteMultip

1 / 18
下载文档,编辑使用

©2015-2020 m.777doc.com 三七文档.

备案号:鲁ICP备2024069028号-1 客服联系 QQ:2149211541

×
保存成功