1 year, 11 months ago.

mbed resource organization

Hey,

What is the problem why mbed resources are so poorly organized? That's just my opinion, but I want to work and use mbed not only in it's ecosystem with online compilers, git interface wrappers etc. Also, to be able to see source code and have a full control of it. I am not a long term user of mbed now and I noticed that there was a significant migration to mbed OS 5. Unfortunately, almost every library I want to use, I get yellow notification box which say that that library is only compatible with mbed OS 2. Documentation is also not updated, ALWAYS redirecting to main mbed OS 5 handbook root, sources cannot be found.

For example, I need networking sockets on my project. I can get some info from https://os.mbed.com/docs/v5.6/reference/network-socket.html, but I cannot get sources from there. While navigating places or by google, I can also get to old, deprecated documentation pages which are useless or misleading.

Even mbed_official libraries are not updated https://os.mbed.com/users/mbed_official/code/Socket/shortlog/ Refering to some pages https://docs.mbed.com/docs/mbed-os-api-reference/en/latest/APIs/communication/network_sockets/ that cannot be accessed from anywhere else and which does not say anything about it's version or update date.

Github repositories are also messy. There is one main mbed repo, which would be totally enough, but now there are repos, which look like containing same modules by their names, but totally different in content. As for example "Sockets". Now I do not know what to use.

Online compiler libraries are differnt than in github, mbed_official publish resources that are hard to understand. Like why there are mbed and mbed-rtos and mbed-src in separate packages?? Which one to use?

When creating project in online IDE, it does not compile until you add tones of related dependencies. And adding the only by guessing, because there is no automatic import or up-to-date documentation as mentioned earlier. Lucky IF it compiles finally. Example. Seriously??

Wouldn't it be more useful for all users if documentation would be easy to understand and well organized in one place, not in 5 different locations without proper version tracking system?

I do not what to bee rude or just say shit. I am experienced developer, but still getting lost here.

How to distinguish mbed OS2 and OS5 packages? Or I can mix and match? Where can I get official libraries with sources? Where is the latest and greatest documentation and how to get it? What git repositories are proper to use and how online IDE and github interwork in the back-end?

Sorry for long post, hoping somebody can help answer these concerns and questions. Mbed official maybe? :)

Thank you in advance

Comment on this question

1 Answer

1 year, 11 months ago.

I will try to answer all of your questions, let me know if I miss something.

Quote:

I can get some info from https://os.mbed.com/docs/v5.6/reference/network-socket.html, but I cannot get sources from there.

From that link, I can navigate to Ethernet - https://os.mbed.com/docs/v5.6/reference/ethernet.html. From there, I can click the Ethernet class reference - https://os.mbed.com/docs/v5.6/mbed-os-api-doxy/class_eth_interface.html. From there, it tells me the file which generated the Doxy - mbed-os/features/netsocket/EthInterface.h. I can click the link to view the file directly on the mbed website - https://os.mbed.com/docs/v5.6/mbed-os-api-doxy/_eth_interface_8h_source.html

Quote:

Even mbed_official libraries are not updated

These mbed_official libraries are Mbed 2 and they should not be referenced in any recent documentation. You are right that they are not under active development, but that is because we are focusing most of our energy on developing Mbed OS, where sockets are included in the RTOS.

Quote:

Github repositories are also messy. There is one main mbed repo, which would be totally enough, but now there are repos, which look like containing same modules by their names, but totally different in content. As for example "Sockets". Now I do not know what to use

Without a specific example, I am going to assume you're talking about something like this - https://os.mbed.com/teams/mbed-os-examples. These are example repositories which contain application code built on top of the Mbed OS library.

Quote:

Online compiler libraries are differnt than in github, mbed_official publish resources that are hard to understand. Like why there are mbed and mbed-rtos and mbed-src in separate packages?? Which one to use?

Between mbed and mbed-src, mbed is released as a static library, while mbed-src will contain all the source code. mbed-rtos is a library to be used in tandem with mbed library to provide RTOS functionlity. mbed + mbed-rtos has been superceded by one library, mbed OS 5 - https://github.com/ARMmbed/mbed-os

Quote:

When creating project in online IDE, it does not compile until you add tones of related dependencies. And adding the only by guessing, because there is no automatic import or up-to-date documentation as mentioned earlier. Lucky IF it compiles finally. Example. Seriously??

All examples in the most recent documentation - https://os.mbed.com/docs/v5.6 - should compile. Can you please link to examples that do not compile?

Quote:

Wouldn't it be more useful for all users if documentation would be easy to understand and well organized in one place, not in 5 different locations without proper version tracking system?

This is the official entry point for all docs - https://os.mbed.com/docs/v5.6

Quote:

How to distinguish mbed OS2 and OS5 packages? Or I can mix and match?

I mean, the main way to tell is that the mbed 2 library has the name "mbed" and mbed OS is called "mbed-os". They also have different revision histories if you were to view their histories with a version control tool. Their directory structure looks essentially the same, but Mbed OS obviously has some code to provide the RTOS. All of the official team mbed code samples will have a "warning" that should let you know if a project is outdated (IE mbed 2 or 3). But, the big marker for me personally is the .bld file extension on the mbed library. Maybe you prefer to look at the naming scheme. This is a nice blog post about about the introduction of mbed OS - https://os.mbed.com/blog/entry/Introducing-mbed-OS-5/.

Quote:

Where can I get official libraries with sources? Where is the latest and greatest documentation and how to get it?

Anything linked here can be considered official - https://os.mbed.com/docs/v5.6

Quote:

What git repositories are proper to use and how online IDE and github interwork in the back-end?

This is the main git repository - https://github.com/armmbed/mbed-os. Any repositories linked here - https://os.mbed.com/docs/v5.6 - will use the mbed OS repository and those examples should be considered "proper." How the online IDE works might best be described in this doc - https://os.mbed.com/docs/v5.6/tools/index.html

Thank you for your advanced answer.

What are the main differences between mbed OS 2 and OS 5?

Most importantly of all questions, I want to figure out if mbed OS 5 https://github.com/ARMmbed/mbed-os is a complete by itself, provides all core functionality and it does not need other libraries to be included separately. Like Sockets, uVisor, queues, USB and etc? I now assume, that Mbed OS 2 is being used in a modular way, where you have to put all things together by yourself: get RTOS, get network, get USB... All those packages like this one https://os.mbed.com/users/mbed_official/code/USBDevice/ are made for mbed OS 2 ONLY, true? Please correct these assumptions of mine.

Are sources like this https://os.mbed.com/docs/v5.6/mbed-os-api-doxy/_eth_interface_8h_source.html directly from https://github.com/ARMmbed/mbed-os repo?

Where can I get sources for mbed OS 2 if https://github.com/ARMmbed/mbed-os is only for mdeb OS 5?

This https://os.mbed.com/users/mbed_official/code/mbed/ is mbed OS2 and not OS5. True?

Is docs.mbed.com (https://docs.mbed.com/docs/mbed-os-api-reference/en/latest/APIs/communication/network_sockets/) up to date or it is old material?

What is mbed-dev? To which OS version it belongs?

For example, to which OS version library like this https://github.com/ARMmbed/mbed-coap or this https://github.com/ARMmbed/mbed-hal can be applied? Naming is like OS2, but it's documentation doesn't describe.

Or like this one https://github.com/ARMmbed/mbedtls. Is this the same as found in here https://github.com/ARMmbed/mbed-os/tree/master/features/mbedtls?

Also, tho which OS version does these apply https://os.mbed.com/teams/mbed-os-examples/ ?

When useing online IDE or mbed-CLI, how should I suppose to import mbed OS version 5, since I can only choose form mbed, mbed-rtos, mbed-dev and mbed-src?

Maybe I am doing something wrong, but create a blank project, import only "mbed" by mbed_official. It doesn't compile. Error: Undefined symbol $Super$$main

When I did mention github repos organization in my original post I meant Github, not mbed site git interface. What I meant there is, for example, again, those same sockets. https://github.com/ARMmbed/sockets . For which version (2 or 5) does this apply? I got myself to ask what to use: this, mbed-os sources, exported from online IDE, found on various docs sites...

See, all those questions should not bother users in my opinion, this is the basic information.. believe that mbed is strong in it's background, core sources look very professional and I like it! But when it comes to user experience and managing stuff around, these simple things cannot be answered without forum post. Despite professional mbed core I would consider if new product should be based on mbed or not. Like other ARM sites, mbed is no exception — old material is mixed with current and is not clear. I hope you can also get some ideas form these thought of mine.

posted by Karolis Milieska 30 Nov 2017

Your assumptions about mbed OS vs mbed 2 are correct. Though, I want to make one thing clear about that - mbed 2 was NOT an OS. OS functionality could be added with mbed-rtos.

Yes, those sources are directly from the mbed OS repository. You can follow the listed path (mbed-os/features/netsocket/EthInterface.h) inside the mbed OS repo.

Sources for mbed 2 are from mbed-dev.

Yes, mbed_official is for mbed 2.

That link for netsocket is a little out of date - as it looks like the old docs site. Here is the latest docs site - https://os.mbed.com/docs/v5.6/reference/network-socket.htm.

mbed-dev is the sources of Mbed 2. Again, Mbed 2 is not an OS.

I believe mbed-hal and mbed-coap are from Mbed 2 or 3. Where did you see those linked?

mbed-os-examples are for mbed OS. Anything that you see that says mbed-os is for Mbed OS 5, most likely. I realize now that this might be some confusion about Mbed 2 being an OS. It is not.

Quote:

When useing online IDE or mbed-CLI, how should I suppose to import mbed OS version 5, since I can only choose form mbed, mbed-rtos, mbed-dev and mbed-src?

You can use the import from URL option and import from - https://github.com/ARMmbed/mbed-os

So, the undefined symbol for main means that you have not made a main.cpp and defined a main function. You need to do that to compile. I would suggest importing an example.

That sockets library is mbed 2. Sockets are included in Mbed OS.

Thank you for the valuable feedback. We are working on making the distinction between Mbed 2 and Mbed OS clearer to uses.

posted by Sarah Marsh 30 Nov 2017

You need to log in to post a question