I'm trying to access data from a PLC input variable through an ADS Client using the variable's IndexGroup and IndexOffset. I used the SymbolLoaderFactory to get access to the symbol. With the symbol, I can use an ADS client to read it's data. But, I would like to read it's data through it's IndexGroup and IndexOffset. When I use the symbol's IndexGroup and IndexOffset, I cannot get the expected data. The IndexGroup and IndexOffset (and port) do not match what I see for the variable in TwinCAT. Why do they not match? How can I get the correct IndexGroup and IndexOffset so I can read the data correctly?
Additional Details: I created a PLC variable called MAIN.Input1. The ADS Info defined in TwinCAT is Port: 350, IGrp: 0x8502000, IOffs: 0x8005DFEA, Len: 1
Using the SymbolLoaderFactory (with client on port 851), the MAIN.Input1 symbol says it has an IndexGroup and IndexOffset of IGrp: 0x0000F020, IOffs: 0x0005DFEA