Why ESPNow is awesome - hint: ACKs & Retries!

Поділитися
Вставка
  • Опубліковано 2 жов 2024
  • Let's dig a bit deeper into ESPNow and explore unicast, broadcast and how they affect acknowledgements and retransmissions.
    Get 10 PCBs for $5 USD at www.pcbway.com
    Explore my sensors series - • My Ultra Low Power Wir...
    GET THE WEMOS D1 MINI
    ==================================
    ╚═ Wemos d1 mini (4M version)
    ■ AliExpress - s.click.aliexp...
    ■ Amazon.com - amzn.to/35ii3tw
    ■ Amazon.ca - amzn.to/2ViSXcC
    ■ MrDIY store - store.mrdiy.ca...
    Music: www.bensound.com
    DISCLAIMER: Some of the links found here may be affiliate links, meaning I will make commission on sales you make through my link. This is at no extra cost to you to use my links/codes, it's just one more way to support me and my work. Much of the information contained is based on personal knowledge and experience. It is the responsibility of the viewer to independently verify all information.

КОМЕНТАРІ • 37

  • @kumarvivek5649
    @kumarvivek5649 2 роки тому +7

    For unicast packets, retransmissions are at 6mbps, 2 mpbs and 1 mbps -different data rates. All packets have the same sequence number and all but the first packet have retransmission flag set. Can't explain the mystery of ghost ACK packets. ? Broadcast packets being self ACK?

    • @MrDIYca
      @MrDIYca  2 роки тому

      That is very possible.

    • @mayankraichura
      @mayankraichura 2 роки тому +1

      @@MrDIYca I had the same idea. Because the broadcast is sent to all addresses (it does not exclude the address of the sender), the node sending the broadcast will receive one on itself and since this node is actually powered on, it will send an acknowledgement (not that the sender cares about it). Just an idea though.

  • @Andrew-rc3vh
    @Andrew-rc3vh 2 роки тому +6

    This is a brilliant video. First of all it was entirely logical and straight forward and secondly it gave me all the information I needed to know, which is, as you say, not clear with many other discussions of the protocol. One other point worth mentioning is the protocol works in conjunction with standard WiFi, so it apparently does not cause frames to clash according to Espressif's Ivan Grokhotkov, (the person who wrote most of the code). In fact broadcast mode only transmitting the once is exactly what I need it to do. You can then be flexible and add your own network control. I need to synchronise clocks, so I need to know the precise time it takes.

  • @ingni123456
    @ingni123456 2 роки тому +3

    Great video, thank you for clearing up a few questions I had about ESPNow!

  • @fjs1111
    @fjs1111 2 місяці тому

    MrDIY: I don't know about ESPNOW persay, but usually 2.4Ghz chipsets with proprietary protocol capability allow for TTL modifications, etc.. Maybe a register or code? Very interesting video thanks for sharing

  • @mumbaiverve2307
    @mumbaiverve2307 2 місяці тому

    Very useful video ! Clears up a lot of concepts. I have one query though : In Unicast if the packet is not ACKed, there is a re-transmit. Is this in control of the code ? How does it decide how many retries ?

  • @joseasibal7601
    @joseasibal7601 2 місяці тому

    Thanks for a very good video. i wanted to trace espnow packets on mac laptop, but i cannot get any of espnow 802.11 packets...what version of wireshark and what option did you use to capture these espnow 802.11 packets.. thanks in advance..

  • @SachinBhangale
    @SachinBhangale 2 роки тому +1

    Nicely explained, thanks for making video.

  • @FrankGraffagnino
    @FrankGraffagnino 2 роки тому +2

    great video. really appreciate you setting up wireshark and showing the packets. thanks!

    • @MrDIYca
      @MrDIYca  2 роки тому

      Glad it was useful!

  • @YigalBZ
    @YigalBZ 2 роки тому +1

    Great video! I have few questions, if I may. the 1st: Do you think I can start with a broadcast (send the xFF*), and then each slave alive will respond back with a pre-set package? So the master could collect all MAC IDs of the slaves. Then to change mode tp unicast? This way the system I try to design will not need to hard code the MAC IDs of the slaves, as they may change over system life time.

    • @Mr._Tony
      @Mr._Tony Рік тому

      Yes this setup would work

  • @italorosse
    @italorosse 2 роки тому +1

    Hi, I've tried to replicate the Wireshark capture but nothing was captured! Any leads? Thanks for the great video!

    • @MrDIYca
      @MrDIYca  2 роки тому

      Try putting your card into 'monitoring mode'. Google it for your wifi card and OS.

  • @YigalBZ
    @YigalBZ 2 роки тому

    Few more questions: on 4:35 you show a PCB with ESP32 on your own PCB design. So far I used the DEV-kits only, which are big and ugly, yet include the USB connection. Can you share the PCB design? How do you program it when needed? Do you solder the ESP32 yourself or do you order it with the PCB? (So far I use TH only with PCBs I made, perhaps it's time to move to SMT).

  • @dirkeisner4551
    @dirkeisner4551 Рік тому +1

    Hi, MrDIY excellent video I love your work very well explained. Would you be so kind explaining the following? In the broadcast mode, it is effectively firing, and forget, do the sender pair with the receiver? The reason I ask I would like to have many senders and this would mean I don't get to the maximum of 20 pairs. Thank You

    • @MrDIYca
      @MrDIYca  Рік тому

      correct

    • @dirkeisner4551
      @dirkeisner4551 Рік тому +1

      Thank you for your quick response, do you know if there is some collision avoidance system in the ESPNow protocol, eg CDMA or listen before talking?

  • @gazzacroy
    @gazzacroy 7 місяців тому +1

    cool. very helpful :)

  • @hansroemerszoonvanderbrikk7626
    @hansroemerszoonvanderbrikk7626 2 роки тому +1

    Can you exclude there's no other esp-now device within range? As far as it seems the protocol is embedded in many devices.
    Self ack it's kinda dumb behavior ...but still possible

    • @tvm73827
      @tvm73827 8 місяців тому +1

      “Self ack” 😂. I had the exact same thought but was too embarrassed to put it in a comment, and then I saw yours!!

    • @hansroemerszoonvanderbrikk7626
      @hansroemerszoonvanderbrikk7626 8 місяців тому

      @@tvm73827I admit I was just asking since I've no experience into ESP-NOW protocol, but it still remains something strange to investigate

  • @YigalBZ
    @YigalBZ 2 роки тому

    Last question (for today): what batteries do you use? Sometimes a small size one is needed, sometimes lots of power is needed (like with motors). Do you charge while connected to the ESP? while in work? or only separated?

  • @Hennie588
    @Hennie588 Рік тому +1

    Thank you well explained

  • @ciliamadani3046
    @ciliamadani3046 4 місяці тому +1

    Great content

  • @dirkeisner4551
    @dirkeisner4551 Рік тому

    Hi MrDIY, thank you for your quick response, do you know if there is some collision avoidance system in the ESPNow protocol, eg CDMA or listen before talking?

    • @veitklub
      @veitklub Рік тому

      did you find an answer for that?

  • @ismzaxxon
    @ismzaxxon 5 місяців тому

    The ACK packages are from other esp8266 devices. Home automation etc. I was using broadcast, however, so many people use that format, that i hade to include encoded security, to make sure my messages were only from my devices.

    • @rvtub
      @rvtub 5 місяців тому

      Great VIDEO MrDIY,
      @ismzaxxon, how are you using security, can you pl. elaborate. Do you mean encryption provided by esp-now?

    • @ismzaxxon
      @ismzaxxon 5 місяців тому +1

      @@rvtub Encryption doesn't work on broadcast. I just use a structure to send my data. At the beginning i have a 16bit number. Whenever i get a message, i look for this number. If the number matches, then the data is for me, otherwise i just ignore the message. Nothing fancy, but it works to filter out other peoples esp-now stuff being sent in my area.

  • @mrj2848
    @mrj2848 2 роки тому

    espnow is short range....not longer that the esp in AP mode. Don't get fooled into all these videos claiming long range.

    • @MrDIYca
      @MrDIYca  2 роки тому

      True. I see videos calming KMs of range. I am lucky if I get coverage in the basement.

  • @innomkr
    @innomkr Рік тому

    Great video! You deserve way more subscribers!

  • @Jim_One-wl4ke
    @Jim_One-wl4ke 7 місяців тому

    Thank you for sharing ❤

  • @tagalogelectronics6615
    @tagalogelectronics6615 2 роки тому

    nice....😄

  • @murraymadness4674
    @murraymadness4674 7 місяців тому

    Thanks. Do you know how I can change the channels? I have yet to see an example where anyone does this, every video just uses the example code.
    I need to make sure I have different channels. thanks