Before you can use the datasocket server, you have to properly configure it. For that you use the datasocket server manager. The interface of the manager is not that complicated: on the left you find two important headers: "permission groups" and "predefined data items." I never really touch the 3d header "server settings."
In "predefined data items," you specify your own data item, say "my_write_space." Do this by pressing the new item button. You wil notice on the right side that that you have to specify "read access" and "write access." It is these permissions I was talking about. You can create your own permission by pressing the "new group" button. Call it something like "project_name." On the right you have to specify who is getting permission to access the data item that this permission is specified for.
-everyhost is any incoming call
-localhost is just the computer the server is running on
-you may add the computer name or ip-address of a remote computer you want to use to communicate with the server.
To begin with I would define everyhost, so you can be sure that the permission is not the bug you are chasing anymore.
Then make sure you set this permission to the read/write access of your data item, save the settings (file>save / ctrl-s) and IMPORTANT: shutdown DS server and restart it.
then you are good to go. Good luck.