====== Driver M-bus ====== ===== Description ===== * Protocol implementation according to EN 13757-2 and EN 13757-3 * connection of M-bus devices through local M-Bus converter * connection of M-bus devices through unlimited number of remote M-Bus/TCP converters * driver for reading M-Bus devices uses primary addressing * configuring basic M-Bus device parameters: * primary address * secondary address * transfer speed * reading basic parameters: * manufacturer * medium * primary address * secondary address * integrated M-Bus telegram analyzer, which can be used to create read profile from unknown device * creating M-Bus telegram with command (e.g. command to disable button) and its sending through associated Bacnet point * it is possible to assign mathematical operations to each M-Bus point: * add value * substract value * multiply by value * divide by value * mathematical operations are computed with double precision float numbers * each M-bus device has created point containing state value of last reading * active reading profile can be tested and its return results displayed * Bacnet point for manual start of M-Bus devices reading * virtual M-bus/TCP converter: * allows direct device configuration with manufacturers software on device * slave mode - paralel sensor reading with packet insertion from TCP client * master mód - disables devices reading and master client gains exclusive access to M-Bus converter :!: Knowledge of [[http://www.m-bus.com/mbusdoc/default.php|M-bus]] protocol is required to work with this driver. ---- ===== Virtual gateway M-bus/TCP ===== Enables direct configuration of M-Bus devices with manufacturers software. Virtual COM port emulator is requried to use this function. For Windows we recommend to use [[http://www.eterlogic.com/Products.VSPE.html|VSPE]], 32-bit version is free. ==== Master connection ==== Enables exclusive access to M-Bus converter. All M-Bus functions of M-Bus/Bacnet converter are disabled while connection is active.\\ 8-) Connection is established with **TCP** protocol on port **2001**. ==== Slave connection==== Retains M-bus/Bacnet converter functions and adds received telegrams from TCP client to telegrams sent to converters software. Responses on these telegrams are returned on open TCP connection. 8-) Connection is established with **TCP** protocol on port **2000**. ---- ===== Bacnet implementation ===== ^ M-bus ^ Bacnet ^ | Value from telegram | AnalogInput | | Manual M-bus read| BinaryValue| | State of last read| AnalogInput| | M-bus command| AnalogValue| Properties: * objectName * objectType * presentValue * statusFlags * outOfService * covIncrement * priorityArray * relinquishDefault * units ==== Values of state point of M-bus device ==== * **0** - OK * **1** - No response * **2** - Failed to open port * **3** - CRC error * **4 -** Failed to decode telegram * Writing any value through Bacnet starts manual reading of device ==== Bacnet point of M-bus command ==== Written value will be used as M-bus address when command is sent to M-Bus. ==== Bacnet point for manual devices reading ==== Writing any value will start manual reading of all devices. ---- ===== Driver settings ===== {{:en:menu-drivers.png|}} {{ :en:mbus-driver-konfig.png?600|}} **Communication speed:**\\ Transfer speed of local port.\\ **COM port:**\\ Selection of local COM port.\\ **Manual reading - point name:**\\ Name of Bacnet point to start devices reading. Reading starts after writing any value to this Bacnet point.\\ **Status of master M-Bus connection:**\\ Displays status of master M-Bus connection.\\ M-Bus functions of converter are blocked while connection is active.\\ **Disconnect master client**\\ Disconnects master client.\\ **Virtual COM ports**\\ Virtual ports manager.\\ ^ Button ^ Description ^ | {{ :sk:button-save.png|}} | Save settings | |{{ :sk:button-undo.png|}}| Undo| |{{ :sk:button-add-virtual.png|}}|Add virtual COM port| |{{ :sk:button-minus.png|}}|Delete selected| |{{ :sk:button-info.png|}}| Check availability of virtual ports| :!: Only TCP connection is supported currently. ---- ===== M-bus devices settings ===== {{:sk:menu-mbus.png|}} {{ :en:mbus-device-config.png|}} ---- ==== Port configuration ==== {{ :sk:mbus-port-speed.png?400|}} **Transfer speed** Currently set transfer speed of local M-Bus converter. Changes are applied immediately. :!: Warning! Transfer speed also affects reading algorithm of M-bus/Bacnet driver.\\ **Select COM port**\\ Selection of used port for devices configuration ==== Commands sending ==== {{ :sk:mbus-dev-setup-commands.png?400|}} **Primary address**\\ Primary address of configured device: * **254** - command for all devices (broadcast) * **253** - command for secondary addressed device through **Slave select** **snd_nke**\\ Sends telegram snd_nke \\ **req_ud2**\\ Sends telegram req_ud2\\ **Slave select**\\ Select device with secondary address\\ **Change primary address**\\ Changes primary address of device\\ **Change secondary address**\\ Changes secondary address of device\\ **Change transfer speed**\\ Changes transfer speed\\ ---- ==== Decoded req_ud2 response ==== {{ :sk:mbus-dev-setup-status.png|}} In this part will be displayed decoded response to req_ud2 telegram. ---- ===== M-bus device profiles ===== Profile is template configuration for converting M-Bus telegrams to Bacnet points.\\ {{:sk:menu-mbus.png|}} {{ :en:mbus-profily.png |}} ---- ==== Editor for M-bus device profiles ==== {{ :en:mbus-profily-part1.png?400|}} In top part of the screen is located list of current profiles.\\ ^ Button ^ Description ^ |{{ :sk:button-plus.png |}}|Create profile| |{{ :sk:button-mbus-add.png |}}|Create profile from M-Bus device| |{{ :sk:button-minus.png |}}|Delete selected profiles| |{{ :sk:button-save.png |}}|Save profile settings. :!: Warning, only this option saves changes permanently to file. Other save options will save changes in memory. **Remember to use this option at the end of your work!**| |{{ :sk:button-undo.png |}}|Undo| |{{ :sk:button-test.png |}}|Test profile on M-Bus device| ---- ==== Editor for M-bus device profile ==== {{ :en:mbus-profily-part2.png?500|}} **Bacnet object name:**\\ Name of M-Bus status point on Bacnet\\ Symbol **@** will be replaced with given text on profile upload to M-Bus read configuration.\\ **REQ_UD2:**\\ "C Field" of sent telegram.\\ **Timeout [s]:**\\ Telegram reading timeout in seconds.\\ Data from TCP converters will be processed after time limit. M-bus device needs to send all data or CRC errors can occur.\\ **Description:**\\ **Notes:**\\ User description and notes.\\ ^ Button ^ Description ^ |{{ :sk:button-save.png |}}|Save settings| |{{ :sk:button-undo.png |}}|Undo| **List of telegram entries**\\ These entries are exported as Bacnet points\\ ^ Button ^ Description ^ |{{:sk:button-plus.png|}}|Add entry| |{{:sk:button-minus.png|}}|Delete selected entries| |{{ :sk:button-save.png |}}|Save entries settings| |{{ :sk:button-undo.png |}}|Undo| ---- ==== M-Bus telegram records editor ==== {{ :en:mbus-profily-part3.png?400|}} **Bacnet object name:**\\ Name of M-Bus point on Bacnet.\\ Symbol **@** will be replaced with given text on profile upload to M-Bus read configuration.\\ **Bacnet units:**\\ Units accessible through Bacnet\\ **Telegram number:**\\ **Position in telegram:**\\ Informative value on automatic read from M-Bus device\\ **VIF+VIFE:**\\ VIF+VIFE value\\ **DIF+DIFE:**\\ DIF+DIFE value\\ **Search by:**\\ Entry in telegram is searched by VIF+VIFE, or by VIF+VIFE and at the same time by DIF+DIFE. You can find more informations about structure of M-Bus telegram [[http://www.m-bus.com/mbusdoc/default.php|here]].\\ **Mathematical functions and their values**\\ Allows modification of decoded values before they are written to Bacnet point.\\ ^ Button ^ Description ^ |{{ :sk:button-save.png |}}|Save settings| |{{ :sk:button-undo.png |}}|Undo| **Telegram data**\\ Hexadecimal representation of recieved telegram on automatic profile generation. ---- ==== Generate profile from M-Bus device ==== {{:sk:button-mbus-add.png|}} {{ :en:mbus-profily-add-dialog.png?direct&400|}} ^ Button ^ Description^ |{{:sk:button-globe.png|}}| Read M-Bus device on specified COM port and req_ud2| |{{:sk:button-ok.png|}}|Generate profile from received data| |{{:sk:button-cancel.png|}}|Cancel profile generation| ---- ==== Test profile on M-Bus device ==== {{:sk:button-test.png|}} {{ :en:mbus-profily-test.png?direct&400|}} ^ Button ^ Description ^ |{{:sk:button-globe.png|}}|Test profile on specified COM port and req_ud2| |{{:sk:button-ok.png|}}|Close window| ---- ===== M-Bus device settings ===== {{:sk:menu-mbus.png|}} {{ :en:mbus-reading.png|}} ---- ==== M-Bus devices editor ==== {{ :en:mbus-reading-devices-editor.png?direct&400|}} In top part of the screen is located list of currently configured devices.\\ ^ Button ^ Description ^ |{{ :sk:button-plus.png |}}|Create M-Bus device| |{{:sk:mbus-reading-add-profile.png?direct|}}|Create M-Bus device from profile| |{{:sk:mbus-reading-update-profile.png?direct|}}|Update selected device from profile| |{{ :sk:button-minus.png |}}|Remove selected devices| |{{ :sk:button-save.png |}}|Save devices settings. Warning, only this option saves changes permanently to file. Other save options will save changes in memory. **Remember to use this option at the end of your work!**| |{{ :sk:button-undo.png |}}|Undo| |{{ :sk:button-test.png |}}|Test current settings on M-Bus device.| ---- ==== M-Bus device editor ==== {{ :en:mbus-reading-device-editor.png?direct&400|}} **Primary address:**\\ Primary address of M-Bus device\\ **Bacnet object name:**\\ Name of M-Bus status point in Bacnet\\ **REQ_UD2:**\\ "C Field" of send telegram.\\ **COM port selection:**\\ Port of connected device\\ **Timeout [s]:**\\ Telegram reading time limit in seconds.\\ Data from TCP converters will be processed after time limit. M-bus device needs to send all data or CRC errors can occur.\\ ^ Button ^ Descrition^ |{{ :sk:button-save.png |}}|Save settings| |{{ :sk:button-undo.png |}}|Undo| **List of telegram entries**\\ These entries are exported as Bacnet points\\ ^ Button ^ Descrition^ ^ |{{:sk:button-plus.png|}}|Add entry| |{{:sk:button-minus.png|}}|Delete selected entries| |{{ :sk:button-save.png |}}|Save entries settings| |{{ :sk:button-undo.png |}}|Undo| ---- ==== M-Bus telegram entry editor ==== {{ :en:mbus-reading-record-editor.png?direct&400|}} **Name of Bacnet point:**\\ Name of M-Bus entry on Bacnet.\\ **Bacnet units:**\\ Units accessible from Bacnet\\ **VIF+VIFE:**\\ VIF+VIFE value\\ **DIF+DIFE:**\\ DIF+DIFE value\\ **Search by:**\\ Entry in telegram is searched by VIF+VIFE, or by VIF+VIFE and at the same time by DIF+DIFE. You can find more informations about structure of M-Bus telegram [[http://www.m-bus.com/mbusdoc/default.php|here]].\\ **Mathematical functions and their values**\\ Allows modification of decoded values before they are written to Bacnet point.\\ ^ Button ^ Description ^ |{{ :sk:button-save.png |}}|Save settings| |{{ :sk:button-undo.png |}}|Undo| ---- ===== M-bus commands settings ===== {{:sk:menu-mbus.png|}} {{ :en:mbus-commands.png|}} ---- ==== M-bus commands editor ==== {{ :en:mbus-commands-editor.png?direct&400|}} In top part of the screen is located list of current commands.\\ ^ Button ^ Description^ |{{:sk:button-plus.png|}}|Add M-Bus command| |{{:sk:mbus-reading-add-profile.png|}}|Add predefined command| |{{:sk:button-minus.png|}}Delete selected commands| |{{ :sk:button-save.png |}}|Save commands configuration| |{{ :sk:button-undo.png |}}|Undo| ---- ==== M-bus command editor==== {{ :en:mbus-commands-command-editor.png?400|}} **Bacnet object name:**\\ Name of the Bacnet object\\ **Enabled**\\ Exports command to Bacnet\\ **COM port:**\\ COM port on which will be command sent\\ **Timeout [s]**\\ Response time limit, used to clear RX buffer\\ ****\\ Telegrams "C-field"\\ ****\\ Telegrams "CI-field"\\ ****\\ Hexadecimal representation of telegrams data\\ \\ Telegram address will be included from defined value in Bacnet object. Length and CRC will be calculated before telegram is sent. \\ ^ Button ^ Description ^ |{{ :sk:button-save.png |}}|Save settings| |{{ :sk:button-undo.png |}}|Undo| ----