Sunday 19 April 2020

What are Embedded Systems


Whenever you hear about embedded systems, what comes to your mind? I guess a lot of electronic chips, wires, PCBs etc. So how did these embedded systems came into existence and how did it evolve and how it become such a integral part of our lives? In todays world, we are surrounded by embedded systems. Mobile phones, laptops, television, radio, refrigerators, ovens and even home automation equipment – All are embedded systems.
     If you think about it, these are in fact control systems. Control system means a system intelligent enough to control some variable parameters depending on inputs. So there are inputs and outputs. Depending on inputs, the control systems control the output. To achieve this, a system which has its own intelligence capable of analysing the input and producing the output is needed. So these system are nothing but embedded systems. So Embedded systems are brain of a control system.
     So lets define embedded system now. The systems embedded in control system which implements the logic are called embedded systems.


     These embedded systems are electronic in nature and consists transistors in each of its chip, be it for memory or processor or any other controller chips. As per Moore’s law, the number of transistors per unit area doubles every year. And hence the power of embedded chips increased drastically over the years and it took a major role in our lives.
     This logic needed for a control system works based on inputs and embedded system since they are electronic in nature, can only understand input parameters as voltage (or current). So various sensors were invented. These sensors convert physical parameters of interest like sount or light intensity or pressure etc into electric voltage which can then be digitised and fed into embedded system for processing. One example of sensor is microphone which converts the volume of sound to electric pulses. The embedded controller processes the input and applies the logic and forms the output which is also in form of voltage. But this has to be converted into the physical form which is what matters for the outer world. So for that we have actuators. An actuator converts the voltage to a intended physical parameter like sound or light etc. An example for actuator would be speaker which converts the voltage into sound. If the embedded system logic takes feedback of output to make some adjustments then its called closed loop control system else its called open loop control systems. They are seen pictorially like below.


Closed Loop Control System


Open Loop Control System


So, till now we learnt that embedded systems are integral part of control systems and they are the brain which implements the logic of control system. Depending on the way this logic is implemented, the embedded systems are classified into 2 categories
Ø ASIC (Application Specific Integrated Chips) where the logic is hardwired in the hardware itself.
Ø GPC (General Purpose Controllers) where the logic is programmed into the hardware by means of software.

ASICs are very specific to the application and they cannot be used for any other purpose. The logic is completely implemented in the hardware and hence the resources are very tailormade and specific to the application and none of the resources are unused. CAN controllers are an example for ASICs as the can protocol is hardwired in the chip. Many automotive companies use ASICs in their ECUs mainly for regulators and power-stages. The VLSI companies design the layout and manufacture these ASICs which are custom made for their purpose and specifications. In case of ASICs usually there is no software involved.
On the other hand, GPC are the microprocessors and microcontrollers which has some basic and generic resources which can be enabled or disabled and used by an embedded application to realise the purpose. These general purpose controllers can be programmed to behave as any desired chip within the limit of its resources. There are various microcontroller manufacturers which manufacture various microcontrollers with varied range of power and resources and sell it in the market. These range from microcontrollers for low-end applications to high end applications too. These microcontrollers can be taken and programmed to perform any logic needed for the control system. When I say programmed, it means writing the logic in a high level language(like c, C++ python etc) or controller specific low level language(Assembly codes) and compile them (Using Compilation stages) to get the machine readable binary files and using a tool flash this file into embedded system and hence converting the GPC into the embedded brain performing the logic needed for the control system.
These GPCs now a days are more famous and used compared to ASICs. Because ASICs are custom made for a particular application and once manufactured, these cannot be made to perform any other logic than what they were originally designed for. On the other hand the GPCs can be modified to perform any logic just by changing the code and re-flashing different logics again and again. Since its very easy to modify the software and impossible to modify the hardware, GPCs gained a lot of importance.

the below video explains these concepts beautifully:


No comments:

Post a Comment