pgold50 Posted April 23, 2013 Report Share Posted April 23, 2013 hi all, i have a question about using protocol fb. i have a phoenix empro ma250 power meter which can aommunicate using modbus rtu. i can communicate with the power meter using read holding register modbus fb flawlessly. what i want to do is use protocol fb to generate the send and receive modbus frame messages. i am having trouble constructing the messages in protocol fb. i have attached a picture of the frame structure of the meter. iam using a v350 for this, with one port for modem and the other port for the device/s. i wish to use protocol fb instead of modbus fb because i want to connect other devices that don't use modbus protocol. i hope anyone can help me. thanks all protocol fb question.bmp 1 Link to comment Share on other sites More sharing options...
Emil Posted April 23, 2013 Report Share Posted April 23, 2013 Please note that there can be conflict between two protocols which can mess te communication with one of them or both. Link to comment Share on other sites More sharing options...
nouy Posted April 24, 2013 Report Share Posted April 24, 2013 Hi pgold, That’s my problem too, I’ve wanted to communicate phoenix power meter EMPRO MA250 with FB Protocol, but it seems I am having a problem in construction of framing message or parameter configuration of such function block. However I’ve posted some screen, I made an application were I should be able to read power meter single register such as phase voltage. Thanks Link to comment Share on other sites More sharing options...
pgold50 Posted April 24, 2013 Author Report Share Posted April 24, 2013 hi emil, i considered the conflict of the two protocols that is why i want to use fb protocol and not modbus. if i use fb protocol, then i can initialize the com port for protocol fb. i can communicate with the first device via fb protocol but i don't know how to construct the messages in the attached picture for the second device which is the power meter Link to comment Share on other sites More sharing options...
Tony Spearing Posted April 24, 2013 Report Share Posted April 24, 2013 Hi Paul Have seen your FaceBook message and have read the gist of your requirement. I think the answer is Yes, it can be done, the Modbus frame is small and can be constructed using the Protocol FB. I am training all day Thursday but if you would like to talk through your problem on Friday my number is 01480 276446.RegardsTony. Tony Spearing - Technical Manager, i4 Automation Ltd Link to comment Share on other sites More sharing options...
pgold50 Posted April 25, 2013 Author Report Share Posted April 25, 2013 hi tony, maybe we can talk through skype if we're both free, my id is cruzifixx_11, im from the philippines so i don't know if our times will sync, haha, or maybe we can chat on fb or skype, thanks Link to comment Share on other sites More sharing options...
Tony Spearing Posted April 26, 2013 Report Share Posted April 26, 2013 Hi Paul As you had also put through your question on Facebook I assumed you were UK based. I used the coms sniffer on a V570 to look at a known working Modbus command, read holding registers 0-31 and then tried to duplicate the message using the Protocol FB. I came across a small snag in that the CRC byte order in wrong, it's back to front. The working message is 01 03 00 00 00 20 44 12 which the Protocol FB generates as 01 03 00 00 00 20 12 44 I cannot see a way to reverse the CRC bytes automatically but as I guess you do not need to have many messages you could work out the CRC using the above method and then hard code it in the Protocol FB. The method for generating the CRC for Modbus appears to be binary, zero forward offset, zero backward offset, CRC-16, 256 (100H), 2 bytes. Note that the message is only 8 bytes long including the CRC, the screen shots added by Nouy would look like this for my message, two extra bytes at the front of the message. 00 01 00 03 00 00 00 20 xx yy Hope this helps but if you still have issues them please get back to me. Tony Link to comment Share on other sites More sharing options...
MVP 2014 Simon Posted April 28, 2013 MVP 2014 Report Share Posted April 28, 2013 There is a checksum variable in the list of variables for the protocol message. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now