Frankly speaking I have tried a few a bit different solutions and I don't like anything I did.
As a base I use:
constantly working DPRD_DAT and
DPWR_DAT blocks to read/write entire address areas to Global DB. This DB, for its part has two UDTs, say, "reading", "writing".
To send a command (the commands are to be sent to 1st byte of the 1st word) I pass needed
hex value to respective DB address further it is passed by DPWR_DAT block to the respective DP module register.
Reading the status word happens similar way.
It works, but I don't like this way. It has some drawbacks, probably connected with DP module HW or FW. Every day I learn something new about its behaviour.
What I don't like? It requires more deeper discussion. Let's speak about methods first.
So, I'm looking for methods to do that in different way. Perhaps someone suggests something unusual or smarter.
Thanks in advance!