Hello jagroop;
Actually, you (the programmer) tell the DP-master what data you will exchange over the bus and where it will be "dumped", as you say.
When you use the Profibus Configurations software of the DP-master (HWConfig for S7 PLCs, Com Profibus for S5/505s, Sycon for Schneider and others) you select a slave to be placed into the bus configuration (once the gsd file is integrated in the configurator) and you give it a unique Profibus address so it can exchange data with the master.
Then you select "modules" for the slave's data exchange, that is, based on the contents of the slave's gsd file you select either a telegram or some data type/size that will be sent/recieved by the master. This is how you tell the master what data to expect.
You then attribute to each one of the selected modules an address (or an address range) in the master's memory bank. This is how you tell the master where to find the data to send to the slave or to save the data recieved from the slave.
Finally, you compile and download the configuration to the master, before it can go online.
When the Profibus network is initialized, the master starts by connecting to every slave, finding out if there is no addressing mismatch and sending to each slave the configuration data that concerns it, so master and slave "agree" on the data exchange to be done. Then the master starts polling each slave in a cyclic order.
Hope this helps,
Daniel Chartier