By using the API CyBle_GetDeviceAddress() to get the device address irrespective server or client.
Refer BLE component datasheet for more details about this API.
It is recommended to call this API only after ble stack is ON.
use API CyBle_GapGetPeerBdAddr() to get the peer device address irrespective of server or client.
Thank you very much for the support. Everything is running smoothly now.