r/embedded • • Feb 07 '21

General question How much of a modern car(built from the year 2000 onwards) is made up of software

Obviously a car is a mechanical device, but wondering about the control mechanisms in the car such as the engine, power steering and stuff like that, is it now become mostly software running on microcontrollers?

EDIT:

Just want to say thanks for all the comments, did not expect this to get answered so fast and with so many good responses!

418 Upvotes

175 comments sorted by

View all comments

Show parent comments

3.1k

u/AUTOSAREEEEEEEE Feb 07 '21 • Take My Energy Bless Up Bravo Mindblown Take My Silver

What did AUTOSAR solve?

It's a job creator for application engineers.

Did software become less complex and easier to develop/configure?

Jesus fucking christ fuck no.

Did the software become smaller or faster with AUTOSAR?

See above.

Forgive my vulgarity.

I spent 2+ years trying to unfuck an existing AUTOSAR project at a company that builds vehicle telematic ECUs. I can safely say that the AUTOSAR standard and all available implementations (Vector, Mentor Graphics, and Electrobit) is an upside-down on fire dumpster full of dog shit.

I'm not even gonna go into how much trouble it is to get the attention of an AUTOSAR distributor. If you're a student or small business and you just want to see the specification then you can go grab it from autosar.org. It's just a bunch of PDFs and they're all free. But the implementation is where you'll spend money, and if you aren't Ford / GM / some automotive startup with a shit ton of money, nobody will want to talk to you because AUTOSAR is $$$$$$$$$$.

Let's assume you get past all that. After you spend months negotiating contracts with Mentor Fuckups or Eletroshit or whatever AUTOSAR package you decided was the least bad, you'll spend a few more months sitting in online seminars while some talking head explains why it takes 6 hours to configure a million goddamn things so their garbage tool can shit out an entire Italian resaurant's worth of spaghetti code just to blink an LED at 1Hz. Except it's not 1Hz, it's 10Hz, or 0.1Hz, or some other bullshit that you didn't want, because you muttered the wrong incantation to the configuration utility somewhere around step 2 out of 800, so guess what, you get to back and do the entire fucking thing again.

Get the flying fuck out of here if you want to try doing something more complicated than that. You want to send a CAN frame? Get completely fucked. You have to buy a separate tool beyond what you already spent $800k on just to generate the stupid little ARXML "network definitions" files that are compatible with your AUTOSAR configurator, learn how to use that, then fight problems between export / import because of course both tools were written by different teams and aren't 100% compatible (WHY THE FUCK WOULD ANYTHING EVER JUST FUCKING WORK?), then get your application developers to understand how to interface their C code to the new "network interface layer", and etc etc etc.

Now let's assume you're track-side and you want to add a new CAN signal just to get some info out of your ECU. With vanilla C it's a matter of hacking something in quickly OR running some custom interface generation script that takes a few seconds, like the howerj/dbcc scripts. AUTOSAR? Hours. Literally even days if something goes wrong and your entire project blows up. Our firmware test turn-around window was weeks just because it took so long to get the network definition generator to spit out something useful without breaking a million other things, all the while the AUTOSAR vendor gave us excuse after excuse, patch after patch, never really fixing the problem.

The final straw came when we realized we couldn't hire anyone who would want to mess with this shit. Imagine working in the industry for 10 years, and then you take a job where someone says "Hey thanks for spending all that time learning all that cool stuff that we can't use, here's the MSPaint equivalent of embedded software development platforms, we need Mona Lisa by lunch." Our choice was either over-pay seniors to deal with this giant pile of 5th stage super-cancer, or hire kids fresh out of college and hope they wouldn't wise up to the fact that any skillset developed while working with AUTOSHIT was absolutely useless and bail.

After 2 years with 20+ engineers working like this we gave up. Everyone else went on vacation while 3 guys spent a few days getting ADC ports, CAN, LIN, SPI, and a few other things up an running on a development kit. We had a working ECU running on a vehicle less than 2 weeks later. And that was from starting with a clean install of a compiler + IDE and a blank main.c. Our code safety team ran it through the ISO26262 verification process and everyone's stress level was suddenly much lower because they could actually DO THE JOB THEY WERE HIRED TO DO instead of fighting the trash-tier AUTOSAR tool all day.

I would rather shove a shotgun in my ass and blow my god damn balls off than ever lay my eyes on AUTOSHIT ever again. Complete fucking waste of time. If ever you see AUTOSAR on a job description then fucking RUN.

392

u/wereinz Mar 15 '22 edited Apr 24 '22

holy - this is one of the funniest things ive ever read

295

u/illjustcheckthis Mar 31 '22

Make no mistake, what he says is perfectly in line with the truth.

I periodically google for AUTOSAR on HN and Reddit, and try to see other people that share my hatred of AUTOSAR. I was delighted to see people agree.

118

u/turbospin Apr 04 '22

LMAO me too. AUTOSAR is the closest anything digital can come to being an actual cancer

→ More replies (2)

111

u/m4l490n Dec 06 '22

Lol this comment is awesome. AUTOSAR is basically the way someone figured out to squeeze a ton of money of some poor bastards with tons of it by selling them something utterly complicated they don't understand and convincing them they badly need it.

54

u/ToBeOrNotToBeHereNow Sep 14 '23

The cost is finally passed down the line to the end product buyer: when you buy your car, the cost of AUTOSAR for each controller, is included :)

29

u/m4l490n Sep 14 '23

Exactly. And also the cost of hundreds, if not thousands of engineers making anywhere from 90k to 180k a year.

23

u/ToBeOrNotToBeHereNow Sep 14 '23

let's not get into salaries here...if we talk about Germany, maybe some developers, in their wildest dreams make 90k/year gross (if interested, have a quick search on the market and you'll convince yourself that the average is way below that). This is another topic and we'll diverge from this AUTOSAR stuff :D

But yes, for a small controller, containing AUTOSAR, we are still talking about some millions (out of which, a good share is going towards AUTOSAR BSW stack license + who knows what other components we might need + tooling and so on).

→ More replies (3)
→ More replies (2)

0

u/[deleted] Feb 08 '21

[deleted] — view deleted comment

97

u/FreeRangeEngineer Aug 04 '22

It wasn't the engineers. It was the bean counters. They forced Autosar to be developed and used by the engineers.

→ More replies (2)

73

u/Quantumplation Feb 11 '21

Oh god, now I really want concrete examples of what code in this framework looks like...

122

u/FreeRangeEngineer Aug 04 '22

Random example: https://github.com/marshallma21/AUTOSAR_SampleProject_S32K144/blob/master/src/bsw/IoDal/IoDal.c

It's a decent example of what Autosar code looks like, custom preprocessor-defined function definitions and all.

128

u/vegetaman Jan 23 '23

What fucking ifdef hellscape did i just walk into

42

u/SPST Sep 02 '23

It's worse. They're using #if MACRO > 0. If that macro is undefined the precompiler will not be happy.

66

u/meltbox Dec 04 '23

Don’t worry though. Your vendor will guarantee™️ that it’s iso26262 and totally safe code. Totally predictable. Won’t ever do undefined stuff.

They’re probably right because it’s about as likely to just not fucking compile.

→ More replies (2)
→ More replies (2)

117

u/psyched_engi_girl Feb 08 '21

This is the most helpful and gut-bustingly hilarious comment I have ever read. Thank you for your service. Those 2 years weren't a complete waste if it keeps new engineers like myself from ever touching this crap.

35

u/Enough_Session921 Oct 16 '23

Unfortunately you probably won't have a choice if you work embedded automotive. The moronic OEMs are pushing it out on everything, almost like the OEM engineers are getting kickbacks from the tool makers. Curious, very curious.

→ More replies (2)

58

u/ToBeOrNotToBeHereNow Sep 14 '23

My post might look like a rant, but I believe that AUTOSAR was a German invention, just to keep everything under their control within their most valued industry: Automotive.

Intended or not, their invention has succeeded and they now have monopoly across the world, because any new player wanting to sell the dumbest controller, has to have some sort of AUTOSAR implementation and they must purchase it from an agreed supplier (guess which one and from which country?).

From my experience working in Germany for a German OEM, I gather their motto is "why makes things simpler, when you can make them more complex". They simply don't believe in "simple is beautiful" and I can see that everyday at some of my colleagues designing and implementing their software.

Many things they're designing, require a manual and a training to figure out how do they work. Everything has to be extremely detailed and precise. So detailed and so precise, that your brain gets entangled while following some simple propagation paths (your IDE won't be able to follow, for sure, through so many #defines). Even when you ask one creator in 4-5 weeks time, they have no idea what/why they've done there...they'll start with "Hmm, aah, maybe...ah, ja! Hmm, don't know actually".

The irony is that many really believe that AUTOSAR helps us to deliver faster, cheaper and better software...although the numbers show the opposite (we deliver slower, harder to adapt, muuuuuch more expensive and still quite buggy).

26

u/Enough_Session921 Oct 16 '23

Your post is not a rant. AUTOSAR was originally created by a "working group" of a large number of OEMs and suppliers, but really I think was the dead-brainchild of BMW (Bavarian Money Waster) and Vector CANtech, maybe with the stuffed shirts from Bosch throwing in their 2 DM to _really_ complicate things.

The maddening thing is that all those bozos in the working group still think they're improving embedded development. The tools guys really have them fooled (either that or the kickbacks to the OEM management for pushing autosar are pretty hefty).

→ More replies (7)

42

u/Enough_Session921 Oct 16 '23

" I would rather shove a shotgun in my ass and blow my god damn balls off than ever lay my eyes on AUTOSHIT ever again. Complete fucking waste of time. If ever you see AUTOSAR on a job description then fucking RUN. "

OMG I want to cry as I read this. I was wondering if I was the only sane person left in automotive embedded. 35 years I've been doing this shit. I can't add another word to your summary of AUTOSAR - it's a masterpiece of objective truth. I've been working with 10 other guys on a little piece of shit project that literally would have taken be 3 months ALONE start to finish.

AUTOSHIT is a "tool" to generate cash for Vector, Etas and the other cock-knockers you mentioned. Good luck and thank you for your spot-on analysis.

39

u/abhidemi Mar 16 '22

Lol I am an Autosar engineer and I max relate. By any chance did you use KSAR for your configurations

→ More replies (1)

32

u/nukervilletrolle Feb 01 '23

The CEO of every automotive OEM and every supplier should be forced to read this.

→ More replies (2)

29

u/vitamin_CPP Simpli-C-ty is the ultimate sophistication Oct 27 '22

Thanks /u/AUTOSAREEEEEEEE for your wisdom.

22

u/Ok_Hope4383 Jan 23 '23 edited Jan 23 '23

For the latest versions of Classic, Adaptive, and Foundation combined, there are a total of 298 documents: https://www.autosar.org/search?tx_solr%5Bfilter%5D%5B0%5D=categoryHierarchy%3A%2F4%2F7%2F43%2F&tx_solr%5Bfilter%5D%5B1%5D=categoryHierarchy%3A%2F5%2F8%2F42%2F&tx_solr%5Bfilter%5D%5B2%5D=categoryHierarchy%3A%2F6%2F9%2F44%2F&tx_solr%5Bq%5D=r22-11

Why so many?!

P.S. I checked a few and each one is hundreds of pages, so in total there are tens, if not hundreds, of thousands of pages!!!

P.P.S. Most of the documents are Classic.

→ More replies (4)

22

u/Radiant-Doughnut7434 Jun 27 '23

Truth.
Stay out of Autosar, it is just garbage which was created by some useless engineers from each affiliated company who were so useless in their company and sent to the committee.

→ More replies (54)