-
Notifications
You must be signed in to change notification settings - Fork 6.8k
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
Discussion: Supporting the Arduino ecosystem #22247
Comments
To continue the discussion, I think there's a few areas to discuss:
|
Hi, @beriberikix, and all. Thank you for introduce my project.
From my point of view, there are no serious problem.
AVR has separate register that GPIO in/out configuration and intterupt setting (DDRx and EICRx).
Arduino source is build by My package is seem well worked, but need more effort to reduce maintain cost. # The difference of build system between Arduino and Zephyr is based on their fundamental of design. # Most significant difference with commonly make system and 'arduino-builder' is searching include path by brute force.
It is difficult problem. Config file is frequentry need to create in Zephyr development, But not considered in Arduino IDE. Provide GUI or Provide preset configuration are good help for this problem, but not perfect solution. I think, it is two task is exists to provide Zephyr based Arduino environment. Already I wrote, there is not so difficult problem to implementing APIs. In my opinion, providing API implement as a Zephyr Module is prefered approach. Because it is naturally fit to Zephyr. We can use every tools such as If Arduino APIs is implemented in Zephyr, to make Arduino IDE supports Zephyr is become a not complex (but not easy) problem. That is generate a configuration and just kick a Zephyr's build process. # Even if Arduino IDE runs many things until kick a build process, that is different problem. And it is partially solved in my experimental project. I guess "monolithic" project is prefere way. Some already existed Zephyr Module are contains proprietaly licence code. (Like a vendor specific HAL codes.) In my opinion, Firstly provide Arduino API as zephyr module and concurrently improve Arduino IDE support is good way to proceed this task. |
It is unfortunate Arduino chose to go down the Mbed path. IMO, Zephyr has done an excellent job of simplifying the build environment. It is as easy building an app in Zephyr as it is in the Arduino IDE. If you need to customize your Arduino build environment in any way, it gets very complicated quickly. The Arduino IDE is a great improvement on make. Perhaps Zephyr has evolved beyond the Arduino IDE. I would recommend adding Microsoft's VSCode to the list of environments. I work in that environment when doing Arduino or Zephyr projects. If you haven't tried it yet, you probably should give it a whirl. There are a few quirks but overall it is pretty good. |
Huge fan of VS Code, for just about every form of development (including via Platformio.) I'm really enjoying #21119! I use to be the product manager for Particle's Workbench and can attest to how much developers love VSC. The reason I think it is valuable to have an Arduino API layer and Arduino IDE story is less about the people currently using Zephyr but to enable those who are not. That way, through the Arduino ecosystem, developers who are ready to take their skills to the next level, can do so through an incremental step rather than having to learn about the commandline, CMake, threads, etc. to start. I believe it would only add to the Zephyr community and bring in more users. Once they start digging into the docs, learn about the tools, I'm sure they'll also want to "upgrade" to the more capable APIs, |
Agreed! I read an article by Limor Fried over on Adafruit's blog that said a similar thing ... it's all about getting more developers and doing that involves making the underlying technology invisible. Zephyr is getting close to being a huge thing. I think it will have a profound impact in the embedded world. There are still a few rough edges but overall, it is quite impressive. When using VSCode with Zephyr, the development environment is like Arduino on steroids. |
I recently discovered https://github.com/arduino/ArduinoCore-mbed, which might be a good template for creating an adaptation layer for Arduino. Thoughts? |
I am uncertain that helps much. Maybe as a template of what needs to be done. I think we need a new "core" ... ArduinoCore-zephyr |
Agreed, but it could a similar pattern of adopting https://github.com/arduino/ArduinoCore-API, implement the |
Just has a look at the ArduinoCore API repo. That looks quite interesting, I was unaware they were doing that. Could be very helpful. |
This issue has been marked as stale because it has been open (more than) 60 days with no activity. Remove the stale label or add a comment saying that you would like to have the label removed otherwise this issue will automatically be closed in 14 days. Note, that you can always re-open a closed issue at any time. |
@jhedberg would it be possible to convert this issue to a Discussion topic? I recall seeing the feature in the launch but I don't know if it is available in the Beta. Otherwise I'd be happy to start a new discussion. |
Sure, no objections. FWIW, I don't have much personal stake or opinion here. IIRC I added then question label when I was release manager for 2.2 and we were triaging open issues. |
Ah, sorry about that! I just saw you were the only maintainer on the thread :) I assume only members can migrate an issue into a discussion (if that's even possible!) |
This issue has been marked as stale because it has been open (more than) 60 days with no activity. Remove the stale label or add a comment saying that you would like to have the label removed otherwise this issue will automatically be closed in 14 days. Note, that you can always re-open a closed issue at any time. |
I completely understand the benefits to the community of this project, however I am still unclear on how exactly we should proceed with this. Fundamental question I have is that zephyr is a contantly evolving RTOS Project. However after having a look at https://github.com/arduino/ArduinoCore-nRF528x-mbedos they seem to have archived, which in my understanding means they have dropped further development. Means in future if there is any additions to mbed OS, they will not be reflected in the Arduino IDE framework? I wonder if this will be counter productive if we were to do something similar for zephyr as zephyr is a very active project. Someone will have to constantly maintain this new "ArduinoCore-zephyr" which imo seems difficult for the life of this project. We should find a way to somehow have the entire zephyrproject as a sort of git submodule in the project such that a simple fetch from upstream should bring the latest zephyr features to the user. I however am not too sure if this is even possible as code refactoring or changing of function names/ APIs can break things entirely. After going through arduino on zephyr perhaps if we could automate the steps mentioned there in the README, we could achieve something similar to an arduino IDE style code as it seems to have been done here: https://github.com/soburi/zephyr/blob/arduino-api-example/samples/arduino-api/arduino_blinky/src/main.cpp |
That is incorrect. As is mentioned in the readme, it was archived in favor of another Mbed OS based Arduino core that has a broader scope. That project is very actively developed and maintained and continues to update to new versions of Mbed OS: |
I guess I missed that. It does seem to be actively maintained, and we could definitely take some inspiration from their structure. |
I’d like to start a discussion about how to support the Arduino ecosystem. The target audience are hobbyists who want access to different hardware than Arduino supports, room to grow with more capable APIs (ex. mixing Arduino methods with Zephyr) or need to access specific libraries that aren't easily implemented in baremetal (ex. BLE, OpenThread.) Arduino themselves have been going down this path by using Mbed OS as the base of their newer devices. Note that since Mbed OS is maintained by Arm, it is unlikely to support the variety of architectures supported by Zephyr.
@soburi developed a proof-of-concept trying to make it simple to import Zephyr as a library in the Arduino IDE. See https://github.com/soburi/arduino-on-zephyr. It proved to create a lot of maintenance overhead (as currently implemented), but shows it is possible. We’ve been discussing possible alternative approaches here.
I’d love to get feedback from those interested in Arduino support / have ideas on how to approach the effort / interested in contributing.
The text was updated successfully, but these errors were encountered: