Popa - Learn Hardware, Firmware and Software Design (2005).pdf

(6818 KB) Pobierz
LEARN HARDWARE FIRMWARE AND SOFTWARE DESIGN - ISBN 0-9735678-7-2
654213570.001.png
LEARN
HARDWARE FIRMWARE AND SOFTWARE
DESIGN
by
O G POPA
—————————
ISBN 0-9735678-7-2
Corollary Theorems Ltd.
http://www.corollarytheorems.com/
—————————
LEARN HARDWARE FIRMWARE AND SOFTWARE DESIGN ISBN 0-9735678-7-2 Copyright © O G POPA.
Edition compiled by O G POPA. All rights reserved.
No parts of this book may be reproduced in print or electronic format without written permission from O G POPA
Electrical Schematics presented in this book may not be used for production of more than one PCB board per rightful
buyer. The rightful buyer is the person who has paid the required price for this book to Corollary Theorems Ltd. The
rightful buyer has the right to store this book in two different electronic storage locations, and is allowed to print one
paper copy, only.
All firmware and software programs, or fragments of programs, presented in this book are for educational purpose
only, and they must not be included in any commercial product.
Restricted distribution rights of this book are granted only to Corollary Theorems Ltd.
No copies of this book in print or electronic format are allowed without prior written consent from O G POPA
No translations of this book are allowed without prior written consent from O G POPA
Copyrighted Materials and Trademarks Acknowledgements
We have made all efforts to clearly mark all Trademark names in this book by capitalization, and by inserting the
Registered Trademark, Trademark, or Servicemark symbols on the first occurrence. However, we cannot attest to the
accuracy of the information. This book should not be regarded as misinformation, or as an attempt to the validity of
any Registered Trademark, Trademark, or Service Mark. Should there be any unintentional omission on our part, we
will introduce corrections, upon notice, while it is reasonably possible.
No copyrighted materials from external sources were inserted in this book, and we have striven to make it compliant
with the Copyrights and Trademark Legislations.
Warning and Disclaimer
All information in this book is for educational purposes, only. The Author, O G POPA, and Corollary Theorems Ltd.
have made great efforts to make this book complete, accurate, and suitable for study, but this does not imply any
warranty or responsibility on our side.
Due to the special character hardware, firmware, and software design work have, accidents could happen. Under no
circumstance should the Author or Corollary Theorems Ltd. be held liable for any possible loss connected to the
information presented in this book.
For Library Use
This book may not leave the library, and it will not be lent in any way or form.
This book shall not be copied in any form.
The library reader is allowed to print or copy maximum five pages from this book per library session.
LEARN HARDWARE FIRMWARE AND SOFTWARE DESIGN ISBN 0-9735678-7-2 © O G POPA format
“Business Card” CDR first published May 02, 2005
Previously published in “Download eBook” format ISBN 0-9735678-5-6 © O G POPA, April 08, 2005 in
http://www.corollarytheorems.com/
Distributed by :
Corollary Theorems Ltd .
http://www.corollarytheorems.com/
#304 10420 148 th Street
Surrey, BC, V3R 3X4
Canada
1 604 581 9214
654213570.002.png
ABOUT THIS BOOK
Naturally, the first question is: “Is it possible to learn hardware, firmware, and software design
in a single, and not very thick book?”
My answer is “Yes” , plain and simple, and I will explain why. Both you and I know very well
it takes long years of hard study of each of the above design fields, and you need a lot of practice
and many supporting books to successfully accomplish those tasks. However, the first step is the
most important one; it needs to be in the right direction, and executed in the proper way. This
book is a practical design example—a good, working one!—and it covers fairly well title topics. It
represents that first, small, and the most important step.
Over the years I bought many books related to various programming languages or to hardware
design, and I always looked for the thickest ones, hoping they contain more precious knowledge.
Unfortunately, many times I was rather disappointed, and I considered myself quite lucky if two
dozens out of twelve hundred printed pages contained any useful, practical information. They are
piled now on shelves, and it is possible I will look for one or two lines of code in any of them,
during the next two or three years.
The tough reality today for writers and publishers is, the best place to find general knowledge
information is the Internet, due to the fact it allows for filtered, fast, computer search. In addition,
that information is totally free!
Now, wait a minute, Gino ,” you might say, if the Internet is the cheapest and the best place
to find information, why should I make the effort to buy your book?
Well, my friend, printed or electronic books you buy contain information that goes way beyond
general, basic, and free knowledge you will find on the Internet. Information was, it is, and it will
forever be the most expensive item in existence. If you are serious about learning, expect to invest
little time, efforts, and money for that, same as we all do.
Now, the problem with the available free information on the Internet comes to the readers’
advantage, because it forces Authors and Publishers to come up with competitive books that will
appeal more. Unfortunately, few books manage to do it, and that brings a bad reputation to the
trade. However, I have no doubts the readers will find this book different from any other. I am not
afraid of competition, and I believe this book I present is the best one ever in its domain. I base all
my reasons on the fact I know what is good or bad information, because I searched myself for
years, for good design books. Before being a writer, I am a voracious reader!
Learn Hardware Firmware and Software Design (LHFSD) is in fact a Design Project; an
example of how things work and are done professionally in the industry today. I will guide you
step by step through hardware, firmware, and software design, and we will build, together,
working, useful tools, with a large range of applications. In fact, this book builds a set of templates
LHFSD
ABOUT THIS BOOK
Page - 5 -
which you will reference throughout your future design career, in personal hobby development, or
when you will decide to start building your own commercial product!
To come back to the question of learning hardware, firmware, and software design in a single
book, that is perfectly possible with good Project Management skills. By some strange turns of
events, it happened I worked all my life with prototype projects and new technologies, and I had to
execute tasks that seemed, if not impossible, at least very difficult. After many years, the difficult
tasks of the impossible type fail to impress me anymore. This book is just another technical project
for me, and the only difficult aspect is, I have to finish it within deadlines—you cannot even
imagine how tight those deadlines are. However, you, the reader, have all good reasons to doubt
my words. Just bear with me throughout the book and you will be the one to decide if I
accomplished those tasks sufficiently well or not. Do not worry: I will know your decision.
The second important question which needs to be answered is: What is this book about
exactly?
Learn Hardware Firmware and Software Design is structured in three parts, and here
follows a brief summary of their content:
Part 1, Hardware Design , is a practical schematic design: we are going to build together the
LHFSD-HCK (Hardware Companion Kit). That piece of hardware has a fair degree of complexity,
and my intention is, it will be a useful hardware tool, or instrument, good enough to burn a
dsPIC30F4011—or dsPIC30F3011—microcontroller, to test additional hardware modules, and to
quickly implement new firmware and software test programs.
We will start from a plain, blank page, and we will design the LHFSD-HCK gradually, to
include the following hardware modules:
1. The ICD2 interface needed to program and debug the firmware code;
2. The RS232 interface needed to communicate serially with the software control
applications residing on your PC;
3. One Seven-Segments three figures led display. I used multiplexing to drive those three
figures, which is an interesting hardware and firmware application to learn. In addition, the
seven-segments display is an excellent debugging tool, because it can show the integers’
values inside the hard-to-reach routines—the MPLAB ® ICD2 In-Circuit Debugger cannot
see inside all pieces of firmware code, like macros and ISR (Interrupt Service Routines).
The seven-segments module is also an excellent example of working with standard logic
ICs of the “Shift Registers” family.
4. The SPI ® Bus (Serial to Peripheral Interface) connected to three devices: serialized
Inputs ( PISO ), serialized Outputs ( SIPO ), and to a programmable digital potentiometer
working as Digital to Analog Converter ( DAC );
Zgłoś jeśli naruszono regulamin