Designing for electronics has always been regarded an art. While putting together a circuit or a board is itself a challenge, designing what is to be done requires a thinking that comes only easily to a talented few. Creating an embedded system is no different; with one added complication. You are not the only brain behind the design; the tiny guy sitting inside controlling everything, thinks for himself too.
This was the point highlighted by Siddharth Unny, director, TL Micro Automation, in an interview with EFY. Interestingly, his company is called TL Micro, which stands for ‘Think like a micro’. With tips from his experience in this domain, this articles takes us through the approach that is needed to create a successful embedded system. If you are a beginner in this field, there is no better place to start.
[stextbox id=”info”]”The challenge in designing products is to create a cost-effective and reliable system that is ready to sell in the market. For this to be successful, it is most important to do a detailed cost evaluation, right when you begin designing.”
[/stextbox]
Think like a micro….
The most important factor while designing for a microcontroller is to think right. While working with embedded systems, people tend to think of how a human would react to a situation, rather than how a controller or a processor would. What is required is to channelise our thought process to how a microcontroller would behave to an input, an interrupt or an instruction, and how it generates outputs. “These are the inputs coming in. This is the code I am going to execute. Oh no! There’s an interrupt and I am going to jump to this line of the code.” This reduces a lot of errors and reworking of our code, and helps us code better.
…What we get is decided by how well we choose what goes into it
Care needs to be taken while selecting the elements that make our system. Choosing the right hardware components and controllers best suited for that particular application, is key. While a platform independent approach might add complications in terms of learning how to work with a new tool or controller, it gives us the flexibility to optimise for our design and not compromise for the available feature set. It is for this reason that it becomes important to ensure that we are comfortable with what we use, or we learn to get comfortable with the set we work with. Learning the art of designing in its true sense automatically equips one with skills needed to adapt to a new design environment.
The bargain should be between cost and performance…
The main component of our system that decides how our system functions is, of course, the processor. The processor needs to be able to comprehend and work at the pace at which random events happen. Once the system to be designed is known, set out to figure out the specifications, and choose components accordingly. Regularly updating ourselves with the latest in our domain- be it components, vendor costs or a new technology itself -is highly necessary. A mix of these to arrive at a comprehensive design that works for our application and can be realised within our cost and performance constraints, is what is required. Designing for cost is the challenge.
…A detailed costing is as important as the product itself
We see a lot of start-ups that have a brilliant idea, invest a little, start working, but give-up mid-way due to escalating costs or lack of design feasibility. The simplest way to avoid this is to do a costing evaluation right at the start; a detailed one that includes not just basic costs, but end-of-product cost, including vendor charges, charges for tools, development charges and so on, at minimum order quantity (MOQ). Not only does this prepare us for what we can expect, but also helps us pitch correctly to the players we are dealing with and work out details viable to both parties.
Ready boards are useful start-up kits…
While setting out to start a system from scratch, boards like arduino turn out to be very useful. We are on the look-out for funding and cannot not get that without a prototype. These boards help us put together a design that works and can help us roughly demonstrate our ability to the customer.
But this would not work out for mass production and that is when we make our own custom boards. In electronics, the MOQ is roughly between 5000 and 10000. Below this mark, designing proprietary hardware might not work out.
While designing our own boards, it is important to keep in mind what software we intend to download into it. Software is developing at an unimaginable rate and newer versions are the order of the day. While upgrading the software to the latest version is good, it is important to check compatibility before we do so. Unless they match, we would end up corrupting the boot loader itself and will have to go back to chip-level programming to set it right. This does not come easy, especially with factory programmed boards where the chips are inaccessible.
…SoCs are a boon to low-end applications that do minimum things
A large part of embedded design is performed today using software. Simulation has given us a tool to test and verify the foundation of our design, even before setting out to buy the hardware. The power of this tool is unimaginable, and automation can be put to very good use to decide the kind of system we want to put together. While it is not difficult to create a system-on-a-chip (SoC) today, it is important to check if it is necessary. An SoC is perfectly suitable for a simple application that requires just a display of the temperature reading, say. But, if extensive data processing is involved, and there already is a microcontroller for the system-at-large, it is sensible to integrate this within the larger set-up.
Exploit the flexibility offered…
Coding has become versatile. From coding using pre-existant loops to isolating layers of the code, everything is possible. Isolating parts of the code, while it requires more manpower and costs more, works better from a design perspective. With sufficient checks and balances, isolation gives us the option to perfect portions of the code individually, ones that can be re-used at ease. It also makes the process of debugging a lot smoother.
Modern microcontrollers allow us to multiplex pins the way we want. From being hardwired, a simple software matrix can now help us program it. Adopting from the field-programmable gate array (FPGA) logic, the pins in the controller are just metal pins, until we assign ports. Also, dedicated units have moved into the controller.
….Customisation offers more then just letting us design the way we want
It is simpler, definitely easier, to stick to a readily available standard while designing. The effort behind building a foolproof, custom protocol is not a joke. But is the effort worth it? It certainly seems so. While allowing us to design stuff the way we want, custom designs allow us to optimise the same for battery life, usage and area of operation. We can avoid unnecessary wastage in cases where a standard demands extra bits that can be done without. Even more important becomes the fact that we are the proprietary owner of our solution and hacking into it is not easy.
Refurbishing is not a bad option…
Systems that demand heavy machinery hit us heavily in the pocket. One option is to rework old machines to suit our purpose. Today, importing such machines is easy, with the process even having its own online market. While the machine might be behind the times in terms of display panels, buttons or output systems, the quality and efficiency is found to be within three to four percent of the current trend, sometimes being more reliable. The difficulty in refurbishing is in understanding how the system works, with hardly any documentation to fall back on. Once the initial hurdle is crossed, retrofit them to give a brand new interface and we have a system, as good as new, at a lesser cost. The factors to keep in mind here are the end-of-line-testing and quality control aspects. How stringent we are in these processes decide how sturdy our system is going to be.
…It is worth investing in looks
As a designer, we tend to think of how best we can make our design function at all times and overlook the aspect of appearance. While this approach works for an industrial product that goes into a larger system, it is not the same for, say, the consumer market. People only buy what appeals to them and it is a market where good looks sell, and sell well at that. With quality of life improving and status playing a role, it is not just about how well stuff works today; it is also important that our product looks in place with the surrounding it is meant for.
Well, we have seen 10 aspects that are most necessary for making an embedded product that works well and sells well. In addition to these, there is also a small, but profound fact we need to keep in mind. With the Internet of Things swarming every field of electronics, software applications are the in-thing. As hardware people, it is upto us to convince people as to why our hardware set-up is required. Let us not forget that we are in an age where apps are replacing hardware systems.
Do you like this article? You may also like these Tech Focus articles.
Priya Ravindran is a Technical Journalist at EFY. This article is written with major contribution from Siddharth Unny, Director, TL Micro Automation.