Copyright © 2004
Oregon State University
School of Electrical Engineering &
Computer Science
This document is the property of Oregon State University and the School of EECS.
Limited use is allowed according to the following criteria: materials are free to use
except for cost of reproduction but must bear this statement. Materials created using
this information may not be labeled as TekBots materials without the prior written
consent of Oregon State University and the School of EECS.
ECE 375 Lab Book ii
Table of Contents
Table of Contents.................................................................................................................................. ii
How to use this manual ..................................................................................................................... v
Important Symbols ............................................................................................................................ v
Lab Structure..................................................................................................................................... v
Lab 1.....................................................................................................................................................7
Introduction to AVR Development Tools ...............................................................................................7
Objectives..........................................................................................................................................8
Prelab................................................................................................................................................8
Procedure..........................................................................................................................................8
Wiring Your TekBot........................................................................................................................8
Looking at some AVR Source Code ..............................................................................................9
Write Up ..........................................................................................................................................11
Additional Questions .......................................................................................................................12
Challenge ........................................................................................................................................12
Lab 2...................................................................................................................................................13
C Assembler Machine Code TekBot .....................................................................................13
Objectives........................................................................................................................................14
Prelab..............................................................................................................................................14
Procedure........................................................................................................................................14
Looking at C Code and the CodeVision Studio............................................................................14
Compiling C Code and Downloading ...........................................................................................17
Your Own Code ...........................................................................................................................18
Write Up ..........................................................................................................................................18
Additional Questions .......................................................................................................................18
Challenge ........................................................................................................................................19
Lab 3...................................................................................................................................................21
Data Manipulation and the LCD Display .............................................................................................21
Objectives........................................................................................................................................22
Prelab..............................................................................................................................................22
Introduction......................................................................................................................................22
Initialization......................................................................................................................................22
LCD Driver User Manual .................................................................................................................23
LCDInit.........................................................................................................................................23
LCDWrite .....................................................................................................................................23
LCDWrLn1 ...................................................................................................................................24
LCDWrLn2 ...................................................................................................................................24
LCDClear .....................................................................................................................................24
LCDClrLn1 ...................................................................................................................................24
LCDClrLn2 ...................................................................................................................................24
LCDWriteByte ..............................................................................................................................25
Bin2ASCII ....................................................................................................................................25
Data Manipulation............................................................................................................................26
Writing Your Name ..........................................................................................................................28
Write Up...........................................................................................................................................28
Additional Questions........................................................................................................................28
Challenge ........................................................................................................................................29
Lab 4 ...................................................................................................................................................30
Large Number Arithmetic ....................................................................................................................30
Objectives........................................................................................................................................31
Prelab ..............................................................................................................................................31
Procedure ........................................................................................................................................31
Assignment......................................................................................................................................33
Write Up...........................................................................................................................................34
Additional Questions........................................................................................................................34
Challenge ........................................................................................................................................34
Lab 5 ...................................................................................................................................................37
Simple Interrupts .................................................................................................................................37
Objectives........................................................................................................................................38
Prelab ..............................................................................................................................................38
Introduction......................................................................................................................................39
Interrupting a TekBot .......................................................................................................................39
Write Up...........................................................................................................................................40
Additional Questions........................................................................................................................40
Challenge ........................................................................................................................................41
Lab 6 ...................................................................................................................................................43
Extremely Simple Computer (ESC).....................................................................................................43
Objectives........................................................................................................................................44
Comments .......................................................................................................................................44
Prelab ..............................................................................................................................................44
Specifications ..................................................................................................................................44
Data .............................................................................................................................................45
Registers......................................................................................................................................45
Memory ........................................................................................................................................46
Data Memory............................................................................................................................47
ECE 375 Lab Book iv
Program Memory .....................................................................................................................47
Instructions...............................................................................................................................48
Assignment......................................................................................................................................49
Test Program Description ............................................................................................................49
Write Up ..........................................................................................................................................49
Challenge ........................................................................................................................................49
Lab 7...................................................................................................................................................51
Remotely Operated Vehicle v2.0 ........................................................................................................51
Objectives........................................................................................................................................52
Prelab..............................................................................................................................................52
Problem ...........................................................................................................................................52
Specifications ..................................................................................................................................52
Write Up ..........................................................................................................................................54
Challenge: Freeze Tag....................................................................................................................54
Appendix A:.........................................................................................................................................56
Parts Lists ...........................................................................................................................................56
Parts List......................................................................................................................................57
Appendix B:.........................................................................................................................................58
Schematics .........................................................................................................................................58
mega128.2 ......................................................................................................................................59
avr-isp..............................................................................................................................................60
Appendix C: ........................................................................................................................................62
Suppliers.............................................................................................................................................62
How to use this manual
During this course, you will work with components and circuits that you will use in your own
engineering careers. The objective is to show the non-electrical engineer how electronics is important
to other engineering fields. You will be designing sensors and sensor circuits to measure real
phenomena—not just arbitrary circuits.
Everything learned in lecture has relevance and is useful in later courses and future careers. As
various tasks are performed in these labs, pay attention to how lecture material relates to the tasks.
Understanding how the lecture material is used and applied will greatly improve understanding of the
topics.
Important Symbols
This symbol indicates an important note that should be remembered. Paying
attention to notes like these will make tasks easier and more efficient.
This symbol designates information that must be followed. If caution is ignored the
task may appear impossible. Ignored caution symbols can lead to damaged
systems.
This symbol represents something that should not be forgotten. Reminder
symbols are used to make sure an important step has been completed before
continuing.
The innovation symbol indicates an opportunity to advance beyond what is
required. These sections will give more insight into the what, why, and how of a
certain topic. Use these to learn more or get ideas for nifty innovations.
Lab Structure
Section
Overview The section overview will describe briefly what will be learned in the section and
what will be done.
Procedure The procedure portion of each section contains all of the tasks to be completed. All
tasks are related to lecture. Keeping this in mind will help in better understanding
the lecture and lab material.
1 / 63 100%
La catégorie de ce document est-elle correcte?
Merci pour votre participation!

Faire une suggestion

Avez-vous trouvé des erreurs dans linterface ou les textes ? Ou savez-vous comment améliorer linterface utilisateur de StudyLib ? Nhésitez pas à envoyer vos suggestions. Cest très important pour nous !