 Merci d'avoir regardé ce talk. Je vous présente Fabien Parent. Je suis Neil Armstrong et nous sommes tous les employés de Bay Libres. Nous faisons des firmes de software engineering. Nous faisons des firmes customes, stock support, product development. Nous parlons de nos histoires. Quand nous essayons d'utiliser la fierté, nous devons développer un device réel. Qu'est-ce qu'on parle de ? Tout d'abord, nous parlons de l'histoire de notre projet, pourquoi nous avons besoin d'artos. Il y a beaucoup d'artos là-bas. Nous parlons de pourquoi nous choisirons la fierté contre d'autres options. Puis nous introduirons rapidement la fierté pour les gens qui ne le connaissent pas. Toutes les works que nous avons faits, nous l'entraînons et l'abstremions. Pour la fierté, nous avons ajouté un nouveau soutien de plateformes. Et depuis que Neil et moi sont deux engineers de Linux, nous ferons quelques comparisions avec Linux, car nous avons un background de Linux. Finalement, nous conclons le talk. La histoire de ce talk est qu'une compagnie nous a demandé d'assurer qu'une fierté s'adresse à la fierté. Nous ne pouvons pas parler trop de ce produit parce qu'il ne s'est pas acheté, mais c'est... C'est un fierté qui va s'acheter cette année, donc nous pouvons donner le nom de ce produit quand il va s'acheter. Je ne sais pas, peut-être, que ce soit le premier produit qui va s'acheter avec la fierté. Je sais que c'est un projet appelé NeoPanda qui va s'acheter avec la fierté. Je ne pense pas qu'il va s'acheter, mais peut-être qu'il va être le premier, je pense. Donc... Globaly, c'est l'architecture du hardware sur lequel la fierté va s'acheter. C'est un devise available composée d'un... armes SOC, connecté à un STM32 L4 et entre les SPI bus. Et ces devises sont outplugables et sur le contexte M0 ou quelque chose, connecté à l'ASQC bus. Donc, nos besoins étaient pour cette partie, la main partie du STM32 L4 le grand MCU, c'était UART pour débugger l'ASQC Master sur des devises outplugables et un SPI Slave, parce que le grand SOC était le master SPI. Et pour avoir un code portable et king code, nous avons besoin d'une base OS future comme un bon scheduler, timers, freids, logs, etc. Donc, nous avons besoin de sélection d'artos, de nombreux artos qui ont besoin de l'assistance permissive, parce que le code a besoin de l'assistance permissive et il a besoin de quelque chose de frein, freins et freins en vue. Donc, les candidats réduits étaient nautiques, c'est un artos bien connu. Nous l'évaluons et nous avons éventuellement parlé de la designation donc la première option était l'OS. Donc, c'est une pause, c'est fun d'implier, c'est un bon moment pour s'éventiver et nous faisons tout ce que l'OS fait mais de notre manière nous serons shaped pour notre besoin, notre processus et nous allons comprendre tout le code base. Mais le drawback c'est qu'il n'y a pas de communauté, c'est difficile de maintenir et nous allons avoir des bugs avec les difficultés de fixer les bugs. La seconde option était l'OS. Pourquoi l'on considère que l'OS est que pour les deux dernières années j'ai travaillé sur le project ARRA, qui choisit l'OS. Donc, nous avons fait la bonne décision d'utiliser l'OS. Donc, le pro de l'OS c'est qu'on était familier avec l'OS. C'est un bon point. Mais aussi un bon point, c'est que c'est déjà soutenu par l'OS. Si on a écrit l'OS, on a trouvé un porte et l'autre, ce que nous considérons, n'a pas eu le support de l'OS. Donc, le grand porte est, le système de construction est incroyable. Donc, quand nous utilisons l'OS, basically, every time you change configuration you have to do make this clean because you cannot be sure that what you will flash will work. Just to explain why it doesn't work is that Nautics, so when you build it makes .o, then in their process they make .a files with all the .os that they found. So if you have some old .o file, it will be actually into the .a file and when you will link at the end the link will try to find the first symbol that it can find. So sometimes it will take a symbol that has nothing to do with what you want to compile. So this is completely broken and we had a lot of headache when our firmware was not working because we did not make this clean before doing another make. So another point that is really scary is that it's supposed to be 3 closed PSD license but inside the repository you can find a lot of code with other license like GPL or so when you want to make a product that will not be that will be proprietary having GPL code inside is scary even if you try to disable it in the configuration there is still the chance that you can include some GPL code so that's really scary. Also Nautix doesn't have a real community. It's mainly one guy that wrote everything so he wrote like 20,000 commits and the second person has just 100 commits et so this is not a real community and basically we don't trust a project with no community to make a real project like the ones that we are making. So here's a few example of commits from Nautix so you can see that there is absolutely no review for the code made by the main rotor so he commits things that doesn't compile he forget to add files and this is a few example. So the third option was Zephyr so at the time we evaluated the project Zephyr was announced like a few weeks before and we were the pros was really good because it was in a similar way really close to Linux in the coding style all the build system was really close, they kept the cac-config, the cable as is they kept to get maintainers get check patch synchronize with Linux they wanted, they still want a strong community, it's a goal for them and they have the same maintaining concept with subsystems and they want a great documentation they want everything to be documented this is a great point and the bad point at the time they didn't have the STM42L4 support on ZEDF1 which is a kind different older SOC and it was still young now and we were quite unsure of the majority of the project and there's still no real product using Zephyr in the current form we know the scheduling the OS code comes from Win River and it's used in products but the current form nobody uses it really for product only development purposes but we know Zephyr at this time because before Zephyr came in the round it was not simple as that but in the meantime we had knowledge of minut but we always started the project and the schedule was too tight to consider switching it to it but it's a really good alternative and we won't forget it for next project Zephyr Nutshell in the future what new project integrated a new lib integration designate for low memory usage for very small SOCs to very big chips like x86 everything highly configurable it's modular and documented and you have cooperative at no cost you don't need to buy RTOS to have this and they want security certification at one point which is a good point for the future so let's see the life cycle so for Zephyr 1.6 it's not the last release but 1.7 was released a few days ago but I didn't want to remake my slides so I'm talking about 1.6 so the release cycle was 3 4 months the merge window was 11 weeks and the stabilization was 3 weeks so to put it in comparison to Linux where the release cycle is 2 or 3 months merge window is 2 weeks and stabilization is 8 weeks so so it's 2 different things on one side the merge window is really long and stabilization quite short and on the other side there is a merge window quite short and stabilization that is quite long so the Linux side is optimized for a really large project with a large number of contribution while Zephyr is still for let's say a smaller project so right now it fits but if Zephyr becomes bigger I think it should maybe move to the way of Linux so the leadership of Zephyr is basically a TSC technical steering community basically to get into the TSC there is a payment bar ship level with different rights so there is Intel, NXP and others so this TSC can choose the direction to which the project will go and basically every time there is a meeting they send some meeting minutes on go drive but right now most of the meeting minutes require permission to access them by chance I tried it if you ask for to access this document they share it with you but maybe it can take 2 weeks to get them so if you call from TSC here please don't require permission to access these documents so also the mind trainers they don't need to come from the TSC members which is good anyone that try code can be eligible to become a mind trainer so everything for the decision is spread across and mailing list and also one of the the issue maybe it has been fixed so I don't know so I learned at last ELCE that basically on the website the blog post are controlled for a separate community which make it kind of hard to post a blog I mean blog post for the fear so I don't know if it has been fixed no ok so the development process for the fear is top-down development so in Linux where you have a merge window and people try to put what they want inside this merge window and if they don't put it the feature is not included inside the release so for the fear is completely different they are defining a set of features that will be included inside the next release and basically if there is some features that run late it can potentially delay the next release of the fear so one one question that I'm asking myself and I don't think I found any answer on the website or whatever is that what's the priority for contribution because there can be some contribution that are high priorities like the ones that are supposed to be in the next release and if I wrote myself some code that is not a high priority function I try to upstream it what will be merged first if I sent my contribution first will it be merged before or after the high priority contribution so in my opinion I think they should clarify the priority of contribution between the features that are planned for the next release and the other contribution from maintainers so our primary work was to add the support the SOC support to the fear so this time the only STM32 SOC that was supported was the F1 so the simple solution like everyone does you simply copy paste the files and re-implement the difference so hopefully the two SOCs were really close so it was quite simple and the porting was really fast we did the basic port in one day and a half and the complete tested the port in less than one week and because the rest was well architectured and really simple to use like clinics actually and most time was spent on debugging on a stupid register issue we didn't add in the code like every project so the API was really critical to the project we were developing as soon as we have the code we need to upstream it so first step read the F manual so the documentation is pretty good so when you read that basically you know everything that you have to do so you know the coding standard so first you clean up your patch to follow the coding standard you run check patch so upload your patch to Gerrit and then you wait for reviews and if there is no reviews try to ping the miner on IOS this is the most important point and you need to find your login and password to Gerrit I changed at least 3 times my password because I could not login so one advice upstream ASA because they feel still young actually the API is changing super fast so basically we made a bad choice of writing the code and then wait for 1 month before starting to upstream it and when we did the first rebase nothing was working everything was broken so as soon as you have some code that is clean try to upstream it for example the power management code I had to rewrite it at least 3 times in the 1.6 they added a unified kernel basically and it broke everything in my code so one advice merge everything otherwise you will have to rebase and everything will be broken and you will spend hours so we will talk about the committee difference between Linux first of all a great difference was when we pushed our STM32L4 initial support was fully rewritten in native code we didn't use any external include or anything and one of the first comments we had on our push was someone from a big company saying please stop your work because we want to push our own HL to the fear and after you will rebase on our port and you will reduce the work so you have the link and you can go and see it so this is a comparison between Linux this is a fresh reply from the DRM maintainer about the Linux position it's clear in Linux no HL only native code only maintainable code so there was some topic on the mailing list about should we use HL should we not are we going to use HL at the beginning and move to native code are we going to native code to HL so there was an input requested at the end of the topic there was no real reply given on the way to go and the result of that is that basically there is some vendor HL that are slowly replacing native drivers I mean at least for ST so also another point is that right now most of the maintainers are from SOC companies so basically on Linux they prefer to not have any vendor maintainers for the top level maintainers why they do that is because top level maintainers that are not from vendor are not pressure to include some things so they can say no I don't want this code I don't want this HL or whatever so personally I prefer to not have HL so I would love to have a definite answer from the maintainer about that of the way to go so now we will review the tools used by the fair so we have Garrett for review of patches and patch series so we have Jira for the feature and Ernstman request so this we place the AFC documentation and estimation on LKM and mailing list for development discussion question or whatever and I didn't include another one but there is IRC so I included a link about a great talk from GateKH that explains the tools that they are using for Linux why they are not using that tool or why they are using another tool so this is really great talk so I advise everyone to go watch it so in my opinion there is too much review tools because the discussions are spread over Garrett or Jira or mailing list and basically it's hard to follow you don't know where to look so Jira the pros are manager friendly it's easy to do graph stats cons I find it quite developer unfriendly it takes a lot of time to use the tools compared to mailing list or you just write an email etc so as I said before it's yet another communication tool that is overlapping with mailing list and Garrett and there is no real information on the wiki on how to use it if we should use it if we should open tickets all the time only for and if it's only for the bigger figures that will land in the next release or if community contributors should open tickets so usage is quite ambiguous for me so maybe it's something that should be addressed Garrett I like that software so the pro is easy to not forget patches the cons it's super slow really slow it's way more complicated than patches you can have issues all the time when pushing to understand with a weird error message while images work so one of the biggest defect of Garrett in my opinion is that you have to select the reviewers so at least Garrett is you can modify it so what they did for the fear is that they try to look at the maintenance of a file that you modified automatically but the fact that you have to add reviewers it means that basically the people that really review your patch are only the maintenance for open source project my opinion is that you should have as much eyeball on your patch as possible because it can only make the code beta and have more review so another subject is that there is no way concept of patch series the closest is to add topics to your patch series and it makes sending patch more complicated because if you sent a v2 that is quite different for your v1 you will have to do a lot of manual work in Garrett to draw up some patch or whatever another issue is that archive is really bad and one of the issues that I also have is that you cannot watch a patch at once you can only see the modification on one file at a time it's really useful to get a full view of a patch to review another issue for me is that basically it's a tool that is very visual so when you look to Garrett, the first thing you will see is that you have some incoming patch review to do and on the right you have a minus 1 to say that the patch was already reviewed by someone and it was not you have a plus 1 that the patch was reviewed by someone and it was act and you get p2 when the mightner accept the patch so this visual representation of whether your patch is or not for me it's really bothering because when someone put a minus 1 basically you can be sure that no one else will review your patch even if the minus 1 was for a not good reason so I think it's slower the patch reviews that kind of visual feedback if you compare to email basically you have no choice than read the 40 mail then read the response so it's more linear so once again I advise you to go to see the talk from great cache that I link in the previous slide finally mailing list it works so also everything if you use mailing list for everything everything is in the same place so it's easy to find what you want you just search and you get it like gira where you have to find in gira or maybe it's not in gira then you will find maybe your answer in gira or maybe no it's in the mailing list so if everything is in the mailing list it's easy and it works cons I didn't find any so let's conclude so for us the pros for Zephyr it was really similar to Linux we're coming from Linux patch 1 so basically it was super easy to move to Zephyr the API are simple and well documented I mean it's one of the first projects where basically when I want to use something basically in most projects I just look at the include look at the prototype of function and try to understand but the documentation is really great so basically you just look at the documentation and basically you can understand most part of the system the documentation exists the community of Zephyr exists and it's real and active which is really great so if you go to the gira you will see a lot of patch sent everyday so I think the design is good for low memory usage on small CPU compared to other Arthos like Nautix where it's using IP everywhere and it's using more memories than Zephyr the flows are really getting fixed quickly so so maybe six months ago the slides would be two times bigger with ten slides of flows that basically we had to remove because they all got fixed so for example it's an anecdote but when I first push patches to get it basically there is a bot that tries to validate and build your patches and basically you get before any review you get three emails from Garrett per patches so when I sent a series of ten patches I got 40 emails in the two hours following my submission in my mailbox which was quite annoying also one other issue on Garrett there was some false build failure report from Jenkins so it got fixed also so that's a good thing and one of the issues that I had with Zephyr was for example for driver there was after driver static configuration but on the growth that is working on devices that should remove all this code to another file and basically I think it will make Zephyr really great when it will be implemented so there was a talk about that this morning so if you didn't see it I advise you to go see the video when it will be posted online so that's all for the pros now the cons so thanks for conclusion of our triad we really want a real plan for the HLs a real something which is within everywhere the maintainers, the TSC will position for the maintainability in the time so this is one point the tools for the review was really mega sad because we spent nearly one month to get our 10 really simple patches merged because it was only a copy of the existing F1 support we didn't add new frameworks no new config, we only copied one SOC to another in the same structure same way identical and we sent six versions of the patch set which is something I think one happen in Linux when the code is well written and based on something which is already working and accepted and the review was really discouraging because there was few very few return from the maintenance the the patches was reviewed by some random guys, we didn't know with counter-dictal reviews we didn't know which command we need to implement the maintainers never said ok now ignore this one take this one like we have in the next community when you send a patch set at the end the maintainers said ok let's do this and we didn't add this at any time because it was really discouraging for us but it's evolving so I think it will go in the right right way and the code is still very young and APIs are showing very very fast so we need to really look and test the code every release to see if it's still working but this morning in the previous talk there is a rumor of eventually switching to GitHub for instead of Garrett so maybe it will solve some problems, it's not perfect but it will be better than Garrett for sure so it's ok for me if you have some questions feel free to ask them no question ok thank you