# How exactly is AS used to configure Modbus IO station to generate an XML for use with ModbusTCP Toolbox?

**URL:** <https://community.br-automation.com/t/how-exactly-is-as-used-to-configure-modbus-io-station-to-generate-an-xml-for-use-with-modbustcp-toolbox/5116>\
**Category:** Controls & Vision\
**Tags:** automation-studio, modbus\
**Created:** [December 4, 2024, 2:46pm UTC](https://community.br-automation.com/t/how-exactly-is-as-used-to-configure-modbus-io-station-to-generate-an-xml-for-use-with-modbustcp-toolbox/5116 "2024-12-04T14:46:33Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![M\_S](https://avatars.discourse-cdn.com/v4/letter/m/FF8800/32.png) [@M\_S](https://community.br-automation.com/u/M_S)\
**Post date:** [December 4, 2024, 2:46pm UTC](https://community.br-automation.com/t/how-exactly-is-as-used-to-configure-modbus-io-station-to-generate-an-xml-for-use-with-modbustcp-toolbox/5116/1 "2024-12-04T14:46:33Z")

</div>

Hello all,

this topic is marked solved, but I do not see a suitable solution to be honest. I am in a same exact ditch. 4PPC70 panel + BC0087 with CM8281 mixed IO module after it.

What have I tried so far: Simply dragging a BC0087 to the project in AS and adding CM8281. This is added as an unconnected module, so I can not configure it, I can not drag it to ETH port where I already have three ModbusTcp\_any devices, nothing. So first question/issue would be - how exactly is AS used to configure Modbus IO station to generate an XML for use with ModbusTCP Toolbox?

I have decided to see if at least default configuration works. Changed IP to my desired range using toolbox, that went OK. Added this IP as a ModbusTcp\_any and configured FC3 input reading for first 7 words and writing first two words, as per the excel help file.

 ![image](https://europe1.discourse-cdn.com/brcommunity/original/2X/5/5a82c43897d08cfc699d6936bdbda96e336b82cf.png)  
 ![image](https://europe1.discourse-cdn.com/brcommunity/original/2X/c/c73a4ef940f19017c294e39636845a4b22d9d020.png)

Reading works, writing does not.

I have tried CAS Modbus Scanner. FC3 reading from offset 1 yields correct data:  
Address 40004 in CAS is address 0x0003 in Excel and those are digital inputs. Excellent.  
As you can see, this value is 1, because I connected first DI on card to 24V

 ![image](https://europe1.discourse-cdn.com/brcommunity/original/2X/5/5dd735b6fb9615c7525a27b7c42db77fa35c3b21.png)  
Same is shown in AS monitor mode.  
 ![image](https://europe1.discourse-cdn.com/brcommunity/original/2X/7/716d534fbb089c999577359d7c842b2c39c4033c.png)

For writing, I used following logic. Excel suggests the 0x0800 address is the two DO I have. Since CAS Modbus Scanner uses +1 notation, I am trying to write “3” to address 0x801 = 2049.  
Output:

 ![image](https://europe1.discourse-cdn.com/brcommunity/original/2X/6/6c4436a2e265bdf226eb0b0ac39de9dde3961004.png)  
 ![image](https://europe1.discourse-cdn.com/brcommunity/original/2X/4/4b3811b5cdf254f0085c34163f83ca17570351ca.png)  
The address 2049 is correct, 2048 yields illegal write, since it would be trying to write to read only registers.  
 ![image](https://europe1.discourse-cdn.com/brcommunity/original/2X/4/4a2b40812aac67aef147f14ce28faaa4a31f3911.png)

With AS, I am using the following configuration:

 ![image](https://europe1.discourse-cdn.com/brcommunity/original/2X/a/a14b3cf6d200c633155af725b6f4ecbfa61ed35a.png)  
I keep getting a MODBUS error with error counter going up and no reaction from the card of course.  
 ![image](https://europe1.discourse-cdn.com/brcommunity/original/2X/9/9d422669d1ea221046fcd8b63733fda12860b2a8.png)

Can someone shine more light on this?  
Thank you

* * *

Originaly added to this already closed topic. [Connectivity between 4PPC30.043F-21B & X20BC0087 via Ethernet](https://community.br-automation.com/t/connectivity-between-4ppc30-043f-21b-x20bc0087-via-ethernet/4026). @gohe can you share with us your findings?

---

<div class="post-metadata">

**Author:** ![M\_S](https://avatars.discourse-cdn.com/v4/letter/m/FF8800/32.png) [@M\_S](https://community.br-automation.com/u/M_S)\
**Post date:** [December 4, 2024, 8:13pm UTC](https://community.br-automation.com/t/how-exactly-is-as-used-to-configure-modbus-io-station-to-generate-an-xml-for-use-with-modbustcp-toolbox/5116/2 "2024-12-04T20:13:10Z")

</div>

Traditional self-reply: No wonder I got errors, watchdog got triggered.  
After clearing it by writing 0xC1 to 0x1044, all is well and writing to outputs seems to work.

 ![image](https://europe1.discourse-cdn.com/brcommunity/original/2X/5/5bf99f646bbcd7c576e00e47f1565d00c8ddd987.png)

However, the XML configuration of BC0087 and modules connected to it is still unclear to me.

---

<div class="post-metadata">

**Author:** ![tommi.piiparinen](https://dub1.discourse-cdn.com/brcommunity/user_avatar/community.br-automation.com/tommi.piiparinen/32/2183_2.png) [@tommi.piiparinen](https://community.br-automation.com/u/tommi.piiparinen)\
**Post date:** [December 5, 2024, 8:51am UTC](https://community.br-automation.com/t/how-exactly-is-as-used-to-configure-modbus-io-station-to-generate-an-xml-for-use-with-modbustcp-toolbox/5116/3 "2024-12-05T08:51:50Z")

</div>

You will need to create a configuration in Automation Studio and select the “ModbusCPU” as the CPU.

![image](https://europe1.discourse-cdn.com/brcommunity/original/2X/6/6239f6f46c4094d4ad7c0a92c13061dba9e74994.png)

Add and configure your I/O Modules

 ![image](https://europe1.discourse-cdn.com/brcommunity/original/2X/6/6a35871d1ea68436be3bb352d94987d35a9d57fa.png)

Build the configuration and find the output files in the following folder.

```auto
<ProjectFolder>\Temp\Objects\<ConfigurationName>\ModbusCPU\AsFDOutput

```

 ![image](https://europe1.discourse-cdn.com/brcommunity/original/2X/1/1083ce6490bd730bda613ef4881aba650b7c08b0.png)

The output files also include nice documentation for the generated station.

---

<div class="post-metadata">

**Author:** ![M\_S](https://avatars.discourse-cdn.com/v4/letter/m/FF8800/32.png) [@M\_S](https://community.br-automation.com/u/M_S)\
**Post date:** [December 13, 2024, 10:19pm UTC](https://community.br-automation.com/t/how-exactly-is-as-used-to-configure-modbus-io-station-to-generate-an-xml-for-use-with-modbustcp-toolbox/5116/4 "2024-12-13T22:19:34Z")

</div>

Thank you Tommi, that helped. I found out that I am actually good with the default config of the module (at least for now), but glad I learned something new.
