Conversation with M-bus. Does M stands for Messy or Marvelous?

srp 17, 2019

admin

Blog

0

Do you remember my story about MODBUS? If not, you can read it on this link: https://bit.ly/2Y0lP8B.

This story is about M-bus. We all know that M in M-bus stands for metering, but I am going to reveal if there is another adjective hidden in this M. Is this protocol messy and hard to work with, or is it marvelous and fun to deal with?

How we met each other? How our paths crossed?

The story about me and M-bus is very short. We met accidentally, and simply because there was a short deadline on one project and there was no other communication module available on stock. I thought that I am going to work with MODBUS again, but destiny had a much better plan. Dear destiny, if you are reading this – hugs, kisses and very big thanks from the bottom of my heart.

How did I prepare to meet M-bus?

With a very big precaution. I did my homework and before our face-to-face meeting, I tried to find everything about mysterious M-bus. I was searching so much about M-bus that maybe all analysts in Google started to think why M-bus is becoming the most searched term in 2019. So, after I did my homework, basically I learned that concept is pretty much similar to MODBUS (with some differences).

M-bus is used for?

In this example, it was used to read data from an electrical energy meter. Again, my task was easy. Connect electrical energy meter on 3 incoming phases in a distribution panel, connect its M-bus pins on RS485 network, set PLC as master and push received data to SCADA.

How I started the conversation with M-bus? How data reading went?

The one thing that made me fell in love with M-bus is that there is a possibility to send preset data frames.

Let’s dig more into the datasets and data reading. I am going to use an example for reading dataset which contains information about active energy. As you can see in picture bellow, telegram reading is pretty easy:


Marko, you are sugarcoating? Where is the trick?

Dear readers, the only problem was to understand why electrical energy meter is sending me the same telegram all the time (4/4). The trick was in dataset pointers. Everything else went smooth.

Just imagine you have 4 destinations to reach. You are going from 3rd to 4th. And you finally reach the 4th destination. What after that? That is the trick. After you received 4th telegram you have to tell energy meter where its pointer direction is. In this case, it must go again on 1st destination. Reset is done by sending special initialization telegram:


I lost a little bit of time on this, but it is ok. Now I got a new friend – a silver 3-phase energy meter. We understand each other. He understands that I need information about energy, voltages, currents and I am feeding him with electrons and protecting against short circuit, dust and water. 😊

Conclusion

Even if data reading is longer and the algorithm is more complicated, my heart goes to M-bus. For me M-bus protocol was easier to work with, documentation is more comprehensive and understandable. From this point, for reading energy meters, I definitely prefer M-bus protocol.

My conclusion is that M in M-bus stands for marvelous.

 

Marko Kancijan, mag.ing.el.techn.inf.

Post by admin

Prenijeto na ovu stranicu