Hello,
I'm designing a product where there is a one to one pairing of a controller and a robot and for this I would like to use Bluetooth using the ESP32 H2 module. This is nice and easy and I can see how to do this.
However I want there to be interaction between the robots on certain events. For example one robot should be able to effect all the other local robots when a power up is picked up. For this I am considering if mesh is a possible way forward? I don't want any type of phone app to be involved and ideally things need to be as easy as possible. I've been looking at the BLE mesh examples in the IDF but they all contain either a provisioning master phone app or have server and client models with no explaination of what a server/client's role in the system is. I've watched videos and read through as many docs as I can find but I'm more confused then ever.
Is mesh the best way to acheive what I want or is there a simpler way?
Really appreciate any input on this one.
Best regards, Ben
Bluetooth Communications and Mesh
-
- Posts: 4
- Joined: Thu Oct 24, 2024 8:45 am
Re: Bluetooth Communications and Mesh
An example of the type of thing I'm after.
Controller A connects to and controls Robot A
Controller B connects to and controls Robot B
Controller C connects to and controls Robot C
When Robot B encounters an external event it can inform all other controllers and robots in real time (without a big delay).
Is this a setup that BLE mesh can do? In this scenario which are the servers and clients?
Is there something else that is more suitable?
Controller A connects to and controls Robot A
Controller B connects to and controls Robot B
Controller C connects to and controls Robot C
When Robot B encounters an external event it can inform all other controllers and robots in real time (without a big delay).
Is this a setup that BLE mesh can do? In this scenario which are the servers and clients?
Is there something else that is more suitable?
-
- Posts: 4
- Joined: Thu Oct 24, 2024 8:45 am
Re: Bluetooth Communications and Mesh
I've been playing around with the BLE Mesh examples and have come a bit further with my knowledge and started to formulate a plan.
The BLE Mesh Sensors example seems to do self provisioning. A single client seems to be able to provision and work with multiple servers. So my plan is to do the following based on the sensor code.
All controllers and robots will start up as servers and wait to see if they are provisioned. If the controller is not provisioned within a few seconds then it will switch to be a client and provision the network. There might need to be some work to ensure that two controllers don't both decide to do this together and end up with two distinct networks. The user may have to do something like a scan to create the network.
Once this is established you have a network containing all controllers and robots, then it's just a case of communicating to each node and collecting things like the Bluetooth MAC and the ROM device type to see which device is which. Hopefully this is workable.
Still if anyone has any experience on this or input to give this would be greatly appreciated.
Best regards, Ben
The BLE Mesh Sensors example seems to do self provisioning. A single client seems to be able to provision and work with multiple servers. So my plan is to do the following based on the sensor code.
All controllers and robots will start up as servers and wait to see if they are provisioned. If the controller is not provisioned within a few seconds then it will switch to be a client and provision the network. There might need to be some work to ensure that two controllers don't both decide to do this together and end up with two distinct networks. The user may have to do something like a scan to create the network.
Once this is established you have a network containing all controllers and robots, then it's just a case of communicating to each node and collecting things like the Bluetooth MAC and the ROM device type to see which device is which. Hopefully this is workable.
Still if anyone has any experience on this or input to give this would be greatly appreciated.
Best regards, Ben
-
- Posts: 4
- Joined: Thu Oct 24, 2024 8:45 am
Re: Bluetooth Communications and Mesh
Ok new plan,
Following the Bluetooth mesh examples has me tied up in knots. Plus the total lack of a response here leads me to believe BT Mesh is not the future.
So i'm ditching it in favour of using BT LE SPP and having multiple connections active at once. Apparently 9 or 10 links can be active at the same time which is great and gets me around the issue.
The robot is the server and the controller is the client so that each controller connects to it's corresponding robot based on MAC address.
The controller has an option to host a party in which case it also becomes a server, or join a party in which case it looks for controller servers to join.
The master host controller then perfoms all the actions to sync events between robots.
The only downside to this is that a party can only be say 8 or 9 robots max but this is probably plenty for what I want to acheive.
Knowing this I'm able to make progress again.
Anyway thanks for all the help, great community
I'll post again when I'm further along. Assuming anyone cares
Following the Bluetooth mesh examples has me tied up in knots. Plus the total lack of a response here leads me to believe BT Mesh is not the future.
So i'm ditching it in favour of using BT LE SPP and having multiple connections active at once. Apparently 9 or 10 links can be active at the same time which is great and gets me around the issue.
The robot is the server and the controller is the client so that each controller connects to it's corresponding robot based on MAC address.
The controller has an option to host a party in which case it also becomes a server, or join a party in which case it looks for controller servers to join.
The master host controller then perfoms all the actions to sync events between robots.
The only downside to this is that a party can only be say 8 or 9 robots max but this is probably plenty for what I want to acheive.
Knowing this I'm able to make progress again.
Anyway thanks for all the help, great community
I'll post again when I'm further along. Assuming anyone cares
Who is online
Users browsing this forum: kaxx1975 and 218 guests