My largest MCU project I developed alone was finally approx. 25k lines (on Cortex-M7; binary is 85k) and developed actively for some 9 months (half of which approximately full-time with no other tasks related to the project) and less actively maintained for another 9 months; this was a project involving several controls such as
* BLDC FOC motor control
* Inertial measurement (gyro, accelerometer, compass) collection from several sensors,
* Wheel odometry + IMU sensor fusion thing with simple motion planning ("go to coordinates x,y")
* Control for custom 3D time of flight camera system, imaging of ten(!) 3DTOF CCD sensors,
* Image processing for lens flare compensation, and finally, dealiasing and depth map calculation based on phase shift images
* Some autonomous logic like "detect the optical marker and drive to charging station" or "obstacle on the way, stop before hitting", later of which also involves sensor fusion for point cloud generation
* Software-defined DC/DC control for a 500W two-phase synchronous buck converter aka battery charger
* Communication and a lot of auxiliary functions like audio beeping, battery management, each simple and small on their own but add up
(The reason I listed what it does is to kind of prove those 25klines are needed. Yes, maybe it could be squeezed into 15klines but the point is, this amount of code is not due to boilerplate or spaghetti copypasta typical to beginners like myself 20 years earlier.)
25klines over 9 months is 92 lines per day or approx. 15 LOC/h. And yes, this is too much. This code base didn't end up total disaster, and it's totally workable, but it's not nearly as good as I wanted it to be. For robust and responsible development, halve that rate; and get enough engineers to share the tasks so that one can focus on the firmware, another in higher-level software, yet another in UI...
For each line of code in the final product, you could say approximately 16 lines are originally written by the programmer:
* 8 (50%) deleted by simply hitting delete and backspace while you try to think what to write before even testing the code
* 4 (50%) deleted during test & verification even before committing into version control
* 2 (50%) deleted by later commits
* 1 (50%) deleted when finally doing a rewrite or refactor of some parts. Here the granularity is larger; maybe a complete "module set" of 10k lines disappears, but another 10k lines unit is kept as-is.