esp-now and number of nodes [WIFI-2126]
-
- Posts: 6
- Joined: Tue Mar 17, 2020 4:36 am
esp-now and number of nodes [WIFI-2126]
i am building application that will have one master and many salves those will need to synchronize with master after every few min.
I read esp-now has 20 peer node max limit, two questions i have
1. Do i have to add node to my peer list to send message? can i just send message without adding to peer list. Can i reieve message from node that's not in my peer list?
2. Can i add node to my peer while i need to communicate and remove after wards so that i can communicate with other nodes. Then i readd once i am expecting to talk to node again.
In my this application i can drive most of the communication initiated by master except the case when salve mode when starting up.
Thanks,
Sajjad
I read esp-now has 20 peer node max limit, two questions i have
1. Do i have to add node to my peer list to send message? can i just send message without adding to peer list. Can i reieve message from node that's not in my peer list?
2. Can i add node to my peer while i need to communicate and remove after wards so that i can communicate with other nodes. Then i readd once i am expecting to talk to node again.
In my this application i can drive most of the communication initiated by master except the case when salve mode when starting up.
Thanks,
Sajjad
Re: esp-now and number of nodes [WIFI-2126]
Moderator's note: edit the topic title for issue tracking, thanks.
-
- Posts: 34
- Joined: Mon Aug 28, 2017 3:27 am
Re: esp-now and number of nodes [WIFI-2126]
hi sajjadakhter,
Yes, you have to add node to the peer list, otherwise, `esp_now_send()` will return error, but you can receive message from node that's not in peer list.1. Do i have to add node to my peer list to send message? can i just send message without adding to peer list. Can i reieve message from node that's not in my peer list?
Yes, you can add peer with `esp_now_add_peer()` and delete it with `esp_now_del_peer`.2. Can i add node to my peer while i need to communicate and remove after wards so that i can communicate with other nodes. Then i readd once i am expecting to talk to node again
-
- Posts: 6
- Joined: Tue Mar 17, 2020 4:36 am
Re: esp-now and number of nodes [WIFI-2126]
Then why there is limit of number of nodes, is it to help with broadcast to all nodes? I don't understand why there is limit of peers especially if I don't need it to receive message.
-
- Posts: 34
- Joined: Mon Aug 28, 2017 3:27 am
Re: esp-now and number of nodes [WIFI-2126]
We set the number of nodes because of resource constraints, especially for the encrypted node, we need to save the key.
-
- Posts: 6
- Joined: Tue Mar 17, 2020 4:36 am
Re: esp-now and number of nodes [WIFI-2126]
why not allow a Send with key as parameter instead of managing peer list. This way user of the API can decide how to manage peers. In my case i could use NVS to store all the peer info as it only need to send messages occasionally.
-
- Posts: 34
- Joined: Mon Aug 28, 2017 3:27 am
Re: esp-now and number of nodes [WIFI-2126]
I'm sorry, I don't think there is any conflict between managing the peer list and your application.
-
- Posts: 6
- Joined: Tue Mar 17, 2020 4:36 am
Re: esp-now and number of nodes [WIFI-2126]
Well it would be much cleaner interface, where can i find sources for esp-now and how can i modify it?. In my case i have quite a few peers but those are configured and saved to nvs/flash. So there is no point of keeping such list dynamic /in memory.
-
- Posts: 34
- Joined: Mon Aug 28, 2017 3:27 am
Re: esp-now and number of nodes [WIFI-2126]
Currently you can't mofify it
Who is online
Users browsing this forum: Bing [Bot], Majestic-12 [Bot], romboidale, sirOwlBeak, snutw_, sohaib.q and 87 guests