Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Inquiries about Coding for ESP Thread Border Router (TZ-1457) #118

Closed
3 tasks done
Robbie981 opened this issue Jan 8, 2025 · 3 comments
Closed
3 tasks done

Inquiries about Coding for ESP Thread Border Router (TZ-1457) #118

Robbie981 opened this issue Jan 8, 2025 · 3 comments

Comments

@Robbie981
Copy link

Checklist

  • Checked the issue tracker for similar issues to ensure this is not a duplicate.
  • Provided a clear description of your suggestion.
  • Included any relevant context or examples.

Issue or Suggestion Description

Hi Espressif Team,

I'm working a project to build a thread based sensor network a have a few unanswered questions after going through the ESP Thread BR documentation:

  1. My understanding is that the built RCP image will be automatically packed into the border router firmware. If I am creating my own rcp firmware (for the esp32-h2) how do I ensure that my new rcp firmware is being flashed? In other words, when I'm flashing the host SoC, how does it know which rcp firmware to flash?

  2. This thread network demo video is really interesting (https://www.youtube.com/watch?v=0WXcu_r_lvQ&t=65s&ab_channel=EspressifSystems), however is there source code available for this? Or something similar perhaps if I am trying to recreate this?

Thank you!

@github-actions github-actions bot changed the title Inquiries about Coding for ESP Thread Border Router Inquiries about Coding for ESP Thread Border Router (TZ-1457) Jan 8, 2025
@zwx1995esp
Copy link
Collaborator

Hi, @Robbie981 welcome to ESP Thread Border Router!

For your question1, the answer is:

Our RCP_UPDATE logic/mechanism is totally open-src, which you can find the related code in our esp-thread-br repo, and the code is under components/esp_rcp_update. There is a configuration RCP_SRC_DIR which can be configured to the folder of the user's RCP firmware. And we use the Cmake function add_custom_command to call a python script to convert the RCP firmware to another which will be flashed on the BR.

For your question 2, the answer is:

Yes, all the source code metioned in the video is avaliable on github, you can find the related links under the video:
image

@Robbie981
Copy link
Author

Hi, @zwx1995esp thank you for the response! A bit of an open-ended follow up question...

My understanding is that the 3 main sections of code relevant to the border router are in these directories: esp-thread-br/examples/common/thread_border_router, esp-thread-br/examples/common/thread_border_router, and esp-idf/examples/openthread/ot_rcp.

Practically speaking if I am working towards implementing a thread network where the border router is relaying CoAP/UDP messages between a host computer and thread end devices, where in the 3 directories I previous mentioned would I focus on for my intended implementation? I am asking this as I am not quite sure what the functional purposes of those directories are and how they work together.

It would be great if you could give me some guidance for this, thank you so much!

@zwx1995esp
Copy link
Collaborator

Hi, @Robbie981 For relaying CoAP/UDP messages between a host computer and thread end devices, this feature has been supported at all. There might be nothing additionally you need to do for using this feature. We support IP layer forwarding, refer to bi-directional-ipv6-connectivity. UDP and CoAP is upper layer based IP layer. You can have a try.

Here are some links for you which might be useful:
Why can’t I access the host from the BR device using the ping command?
UDP command: udpsockclient and udpsockserver
For the CoAP, we did not support any LwIP layer console command, you can refer to our CoAP components and try to implement it on OT device.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants