To
design a programmed microcontroller that can be
embedded into a hardware, it is important to follow methodological design
processes. These processes can be laid down as follows:-
Step 1: Define the problem. State the problem in words
to explain the desired functionality of the device.
Step 2: Draw a functional diagram. Draw the block diagram to
for overall functional representation of the system.
Step 3: Identify I/O requirements. Identify the required I/O
ports, serial channels, required ADC, DAC converters, serial ports etc.
Step 4: Select appropriate microcontroller models. Based on the requirements
of the number of I/O, the expected amount of program and data memory select an
appropriate microcontroller, PIC etc. for the system (referring to the
manufacturer’s literature).
Step5: Identify necessary interface circuits. Layout the design of intermediate
circuitry to interface incorporating the input-output connections using pull-up
resistors, buffers, transistors, relays, and amplifiers where required. I/O
expansion in certain cases are also required which can be realized using shift
registers or through the programmable 82C55A chip which allows one I/O port to
switch access among several I/O ports and is user-configurable.
Step 6: Decide on a programming language. Choose the coding language
to program the microcontroller such as assembly language or in a high-level
language such as C or PicBasic Pro etc. Each of the languages have their own
benefits like, C being high level language is useful in writing codes for
complex systems, Assembly level language is very fast and should be used for
high speed applications with limited memory capacity.
Step 7: Draw the Schematic. Draw the final schematic
showing required components, I/O interface circuitry and all the wired
connections.
Step 8: Draw a program flowchart. Write down the flowchart
(algorithm) for the program. Flowchart is very important part of our software.
Proper representation of the looping(For…Next) and branching instructions should be made for each functional block.
Step 9: Write the code. Write down the code in the desired
language to implement the functionality defined in the above flowchart.
Step 10: Build and test the system. Finally to test the
system, compile the code and burn the hex file into the microcontroller (this
can be done using a programming device like the PicStart Plus serial programmer
etc. available from the manufacturer). After making the proper circuit in the
hardware and downloading the code into the microcontroller, run the system to
test for the proper functionality of the system. Any necessary augmented tests
should be performed on system and observe the output functionality.
-by Deep Shekhar
Comments
Post a Comment