langless28 (Customer) asked a question.

BRX Ethernet IP scanner help

Will there be more documentation coming for BRX and EDS integration? I am very new to Ethernet IP and am trying to learn it. I find a lot of value in reducing the amount of time field wiring on my projects. With that being said i am trying to hook up an IFM EIP IO link master. Connected to the master is a simple IO link sensor (just to test out). I am able to setup the right IP address, get it into the scanner service, import the eds. what i am getting stuck on is how to view all the other details (like status of info on each iolink port etc. I was following a P2k document where the data array is supposed to be formatted by the EDS. I am missing where to do that on a BRX. The AL1122 iolink master says i need more than 256 bytes of data so custom UDTs cannot happen. Is that why?

 

Again i am completely new to EIP and this side of automation. I am a simple hardwire discrete io guy...

 


  • Durallymax (Customer)

    There's multiple layers to working with IO-Link and not a lot of magic, maybe using premade AOPs for RA or ifm's libraries for Codesys, but otherwise it's a lot of work on your own.

     

    Connect to the AL1122 using moneo (I find LRDevice a bit easier for configuring a number of things, but Moneo is what ifm will tell you to use). Install the IODD for your sensor and it should populate on whatever port you connected it to. Configure the sensor as desired if needed. Referencing the AL1122 documentation, you'll find the offset where the process data for port 1 is located. Download the IODD viewer from IO-Link. Within this you'll be able to see how they map the process data for that sensor using the IODD file provided for that sensor (Moneo will also display it for you if you prefer but I find the IODD viewer nicer to work with).

     

    Within the BRX, find the bits you need and map them to your project variables. Since you're new to IO-Link, pay close attention to the IODD. Things aren't necessarily simply mapped as 16bit registers. 5 bits may correspond to one thing, followed by 8 bits for another with three status bits or any random combination of things.

     

    My experience with DmD is very limited and I have never used their E/IP features. How the rest is handled on their end I'll let someone else explain.

    Expand Post
  • Cap (Customer)

    I am Very Interested in this Thread..

     

    About 5 years ago I started Laying out a DmD Project and chose the IFM IO Link because AD did not have IO Link Pressure and Flow Sensors.. Then 3 years ago the Project came on Line.. So the Software I Started on was 5 Years old now.. and IFM and AD have Updated the Software available..

     

    I used the Mod Buss Version Of the AL IO Link Module.. and each Port of Each Block was programmed with about 3 reads to get the Data for that Sensor to Lay Out Properly in N Memory. I used N Memory because some of the Stuff I was dealing with was a Neg Value..

     

    If I remember properly I Programmed 16 AL Blocks.. but I've only activated about 6 of them.

     

    It was a LOT of Cut and Paste, with hand Modding the Addresses.. Brute Force, but Readable and Worked.

     

    Now the E-Net IP Scanner is a Thing in DmD, It wasn't then.. For the Sanity of the Person that will follow behind me I need to Learn it, and make the Software a little Smoother.. But It runs presently

     

    As I said, I'm Curious how you get across this Bridge..

     

    Please keep us Posted..

     

    Cap

    Expand Post
  • HOST_BobO (AutomationDirect)

    BRX UDTs are limited to 256 bytes so it isn't possible to use UDT's to crack the data, at least not directly. For blocks larger than 256 you can create BYTE, WORD, or DWORD arrays then create tags to reference data in place, or use PUBLISH and SUBSCRIB instructions to extract data as required.

     

    For any T2O or O2T block less than 256 bytes, we have a facility to automatically generate UDTs from the EDS definition.

    • langless28 (Customer)

      Thanks. Is the 256 bytes limitation only for BRX? Do other PLC's have higher UDT sizes available? That may be the element i am missing. Do you know any automation direct (or others) EIP devices with UTD's less than 256 byes so I can attempt to learn those?

       

      For example, my AL1122 needs 302 bytes for O2T block. How do i cross those 302 bytes to what information is contained in each byte or across bytes? I do understand that a single byte may have status bits and then other info.

       

      I am reading the AL1122 manual and i see this. Does this mean byte 0-97 are used for configuring the AL1122? so i wanted a certain configuration, i could copy hex words to these certain locations to set a configuration? Acyclic data 

      but then on the cyclic input assembly, i see another 0-~190 byes for the inputs? config assembly 

      I am sure this is basic stuff that I am simply not familiar with yet. Any good online tutorials to learn the basics of EIP?

       

       

      Expand Post
  • HOST_BobO (AutomationDirect)

    I don't know what the limitations of the other PLCs are, but as far as I'm aware, BRX is the only PLC that ADC sells that has native UDT support for T2O and O2T data. What you are showing above really wouldn't benefit all that much from a UDT though since it's mostly just bulk registers. Where the UDT shine is in cracking complex structures or bit picking multi-bit fields.

     

    The configuration assembly is sent as part of the command sent to start the connection. In BRX there is a table to set all of that up. The 256 byte UDT limit only applies to input (T2O) and output (O2T) data.

    Expand Post
    • langless28 (Customer)

      Thank you. Also to confirm, T2O is data from the iolink (EIP) device into the BRX and O2T is data from the BRX to the EIP device? I will try to get on the phone with someone from IFM to see how i can xreference the bytes of data to the data block i created in the PLC.

       

      Also for Port process data size (up to 32 bytes), how does one select this? Do you just go off the largest requirement given what IO link devices are plugged into the master?

       

      Expand Post
      • HOST_BobO (AutomationDirect)

        T2O = Target (Adapter) to Originator (Scanner - BRX) = Input Data.

        O2T is opposite = Output Data

         

        I know nothing about I/O Link or that device.

         

        Reading EDS files isn't all that hard though, so figuring out where stuff maps is pretty easy.

      • langless28 (Customer)

        Thanks for all your help. I was able to read the files and get some locations for the data. I have an iolink pressure sensor and the process data is 2 bytes long. The first two bits are for process output status and the the remainder 14 bits are for the process value (numeric). These are mapped to "testin206 and testin207" (unsigned bytes) of data on my BRX. I think the correct term is bit offset, so how do I take the two bytes of data and copy them to a single data spot and offset it so it does not factor in the first two bits of testin206.

        Expand Post
      • Durallymax (Customer)

        I dk DmD instructions, but the concepts are the same. If your data is 16 bits and bits 0 and 1 are the output status with the remaining 14 as process data I would map it to an Int16. Use partial variable access to map the LSBs to their respective BOOL variables in the program. Mask them off and shift the bits right twice in the int to get your process value then perform the float math to convert to the units you need.

         

        If "first two bits" means MSB, simply masking them off is enough without bit shifts.

         

        I'll let the Host folks point you to the correct way to do this in DmD, they likely have some nice instructions to handle it.

        Expand Post
  • Cap (Customer)

    I found that MY Data could be represented as a Neg Number.. I was using an Absolute Pressure Sensor.. Reading -15 to +30 PSI.. The Sensors Natively send the Data in Metric Units.. BAR/ Ltr/Min etc.. So I had to Convert.. But some flow Meters read GPM.. ??

     

    My Reads have my Data Read from each port as 7 N Locations long.. My Data Table is actually 8 N Locations for each Sensor Block Port, with the First 7 Locations being read from the Sensor Block, and the 8th Location is the Results of My Calculations for that Sensor. after the Read and Calculate id Performed.

     

    Also all data for all sensors is not in the same place.. Flow is in One Location, Pressure is in another.. and Temp from the Flow Meter is somewhere Else..

     

    MY Read is a Bruit Force Method with If/Then.. Location 7 in my Data Table read from the Port is Sensor Type. Loc 3 or 5 are the Output Data Present for Pressure Or flow Data Output Locations that I'll be using..

     

    IF the Sensor Reports as a 475 ( 0-14.7 PSI ) .. then Multiply Location 3 by 0.003631 and put at the End of that data table where my Internal Routine expects to find the Converted data for that Sensor..

     

    If Sensor Reports as a 390 ( 0-160 GPM Flow ) then Mult Loc 5 by 0.1000000 and store at the end of Table.

     

    If Sensor Reports as 473 ( ( 0-147 PSI ) then Mul Location 3 By 0.036310 and Store at the End..

     

    I'm dealing with 6 Sensors in my Wasteplant.. So I have an "If / then" input with 6 Lines..

     

    Ugly Bruit Force but it works and is very easy to understand while troubleshooting on the Fly..

     

    Cap

     

     

    Expand Post