Firmware is developed that creates the desired functionality of the end product. I use a disciplined approach using an architecture I've developed over the years that works very well for 95% of the firmware applications I've done. I believe very strongly in producing high-quality code. This reduces your cost in the future when the occasion arises to modify or enhance the code, whether by me or by someone else!