From a programming logic perspective, you wouldn't see much difference between commercial software and open source - if anything, commercial software tends to lag behind, for reasons like legacy, life cycle management, reliability / liability and / or bureaucracy - I am sure the list goes on.
The biggest differences between the two lie in two or three categories:
1) general architecture: many pieces of hobbyist software are written to perform a specific task, with little thought of what has been done before it and what will be done after it. So they look like hacks rather than modules that can fit into a bigger piece.
I can give you a highly simplistic example. Writing to a spi transmission is quite simple on most mcus: you simply load your data into a transmission register or a buffer and the spi hardware does its magic. That's how most hobbyist spi routines are done: line after line of loading data into the spi registers.
You will rarely see that in a commercial software. What you are likely see are generic functional calls to a spi transmission routine that does some parametric check and then load up the transmission register. At first glance, this may look high inefficient and even redundant. But in a corporate environment, it is far more efficient and / or reliable: the actual spi transmission routines likely come from a proven library that has passed QC; it will be maintained on different mcus that the library supports; .... Once you load the spi library, you know with high degree of confidence that it will work; and if it doesn't, you know precisely where to fix the issues.
Approaches like that allow for fast debugging, low development cost and fast development cycles.
So something that looks highly inefficient / redundant may actually turn out to be highly efficient.
2) documentation: most decent shops do a good job insisting on documentation so the next person handling your code knows how you did it and why you did what you did. and if additional features are to be added, how it can be done efficient.
3) incrementalism vs. grand vision: hobbyist projects tend to start with a grand goal that is too big for anyone person, let alone an underskilled person, to tackle. Commercial projects tend to start small: with a limited set of features and functionality and frequent reuse of early modules / code base. and additional features are built on to it gradually. The emphasis on code modularity and reusing of older pieces is generally not present in a hobbyist project.
4) utilitarian vs. fancy code: you will notice that many hobbyists spend hours trying to make their code go faster, often at the cost of readability, or reliability. Coding in assembly in obscure fashions for example is proudly proclaimed as the status symbol. Those guys are either experts coding for NASA or DoD, or they have never taken on a project slightly more complicated than blinking one led.
As my driving coach told me, the difference between a pro-driver and a street racer is that the pro driver knows when to drive slow in order to drive fast.