This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

multiple server on one client - light switch demo

Hellou. I'm developing application, which is modifiaction of light switch demo. I need use 128 servers and one client. But when I redefine in SERVER_COUNT to 128 in client application, it is no posible connect to servers (servers are not promisioned). I was read somewhere its needed change ACCESS_FLASH_PAGE_COUNT and DSM_FLASH_PAGE_COUNT . But I didn't find how many pages are needed for example 128 servers. My question is how many bytes are needed for writing data to ACCESS_FLASH and how many bytes are needed for writing data to DSM_FLASH by promisioning for 1 server. When i know how many bytes ist needed for 1 bytes, its enoght multiple by SERVER _COUNT(exactly 128) and from this calculate hoe many pages is needed for ACCESS_FLASH_PAGE_COUNT and  DSM_FLASH_PAGE_COUNT. 

Thank you for answer. 

  • Hi,

    The way our example designed is that for each command from the client node we use one client model. For example by default, we have 4 server node, and have 1 client to control LED on server 1, 1 client for server 2, 1 client for ODD Group and one client for EVEN group. Each client located on one element, we have 4 elements on the client node. 

    If you plan to have 128 server, you may not want to have 128 client models/elements to control each of them. I would suggest to use one single client to control multiple servers. You just need to change the publication address of the client to target one server, and can change that address when another server. 

    You can use dsm_address_publish_add() to add an address to the DSM, then use access_model_publish_address_set() to set the app key, and access_model_publish_address_set() to set the publication address of the client mode. 

     

  • Hi, i am not sure if you understand my question. I have 128 servers ( devices), each of this have same firmare, so i use same model for functionality between client and model. But I need connect this 128 servers to 1 client and drive this servers from client separately( unicast) and also broadcast. I need create connection between 128 servers and client (each server need be promisioned). So client need save information about each server. This information are saved to DSM_FLASH and ACCESS_FLASH. But nowhere is not describe how many bytes is needed for save information for 1 server for DSM_FLASH and ACCESS_FLASH. How many pages is needed for DSM_FLASH and ACCESS_FLASH for success promisioning for all 128 devices. 

  • Yes, I understand that what you need. I was just compare it to our light switch client we have in the SDK. Have you found that we have 4 client models/elements on the client node ? 

    If you plan to use only one client element to control all node, you would need to add the code I suggested to change the publication address on the client to target different servers.

    I assume your question is more about how the flash be allocated on the provisionner. I don't have a clear number of how many bytes needed on each server. But what you can do is to refer to the provisioner database (.xml file) we use in the python interactive script here.

    We don't recommend to use the nRF5 to be used as the provisioner for a large network, as it has quite limited memory and CPU. We suggest to use a PC or phone to manage the provisioning and storing the data base about the nodes. The interactive python is highly recommended.

     

     

  • Hello,

    Our project consists of one gateway device in the distribution box and up to 128 node devices located inside luminaires. We need only single model for communication between the gateway device and node devices – there is our propriatery protocol integrated inside the data which are sent between the devices. Could you please make a recommendation for us which topology is the optimal for the application in regards of memory requirements? Should the gateway device be a server or a client?

  • Hi, 

     

    The server/client model is more about where the data is stored. The data is to be stored on the server. If you have data on the gateway and the node need to acquire data from the gateway, then you can set the server on the gateway and client on the node. If you have data (like sensor data) on the node , or you have something you need to control on the node, you use the node as the server, and put the client on the gateway. 

    I don't think the model configuration has something to do with memory requirement. The memory allocation is on access layer, not on the model which in application layer. 

     

    Note that the data about each node ( devkey, address) doesn't need to be stored on the gateway, it just need to be stored on the provisioner, which doesn't have to be the gateway. It could be a phone or PC. 

Related