Siemens S7 Address Question

Using the Ignition Siemens S7-400 driver (version 7.7.5). I can successfully read address types such as Input Words using an opc item path such as “[device]IW0”.

However, I am having issues reading data block addresses.
For example, the PLC has data in address DB40.DBD8

I have tried several formats in the OPC item path with no luck.

[device]DB40,DBD8
[device]DB40,D8
[device]DB40.DBD8
[device]DB40.D8

What am I missing?

[device]DB40,D8 should work, assuming you’ve got the right data block number and offset.

Old Topic I know.
Working with a SIEMENS S7-1510

Programmer supplied me with Data Base addresses of:
DB90.DBD0
DB90.DBD4
DB90.DBD8
DB90.DBD12
DB90.DBD16
DB90.DBD20

I have tried the “DB90.D0” approach but the tag fails.
I know the connection is good because I am able to bring back the “HostName” string and it returns the correct valve.
What am I missing??

Comma, not a Dot after the DB number. The rest needs to follow IA’s type codes (no extra “DB” after the comma).

Phil,
Still no go.

I am still getting a “null,Bad” error
I am using

Ignition OPC UA Server
ns=1,s=[Siemens1]DB90,REAL0

Assuming the addresses are correct, there’s also a number of annoying settings you need to ensure are correct in the PLC:

Considerations for 1200 and 1500 Devices

The following considerations and configurations changes must be made when using the S7-1200 and S7-1500 drivers:

  1. Only global DBs can be accessed.
  2. The optimized block access must be turned off.
  3. The access level must be “full” and the “connection mechanism” must allow GET/PUT.
  4. Reads and Writes can not be used in TM/CT areas.

From Siemens - Ignition User Manual 8.1 - Ignition Documentation

Since you have an S7-1500 it probably has a built in OPC UA server that you’d be much better off using instead.

Kevin,

Thanks!
It was the “GET/PUT” setting that was missing…

I would be interested in knowing why the built in OPC UA server is a better alternative.

Tried it out on a project not too long ago, and it didnt seem to give me as a designer anything worth writing home about. Tag data type was wrong, no description etc…

The biggest advantage is that you have symbolic tag addressing, allowing much more streamlined addressing (make the names match).

You can also enable security and you can read complex structure in one subscription (e.g. a whole recipe structure)

You do need a runtime licence. It is not currently enforced, but might be in future.

1 Like

As @deon.korb said… you get browsing and symbolic tag access, as well as access to optimized DBs, and you don’t need to make all the other configuration changes. Efficiently accessing structures is a bit of a pain, so there’s a trade off, but that’s Ignition’s fault more than anything.

OPC UA is the the official method endorsed by Siemens for external access. The S7 protocol is not open or documented, and everybody accessing tags that way, including us, is doing it with reverse engineered code (whether they did it themselves or licensed a library from somebody else who did it).

1 Like