ECET 340 (Devry) Flashcards
ECET 340 Entire Course Includes all I Labs and Homework
ECET 340 Week 1 HomeWork 1
ECET 340 Week 1 iLab 1
ECET 340 Week 2 HomeWork 2
ECET 340 Week 2 iLab 2
ECET 340 Week 3 HomeWork 3
ECET 340 Week 3 iLab 3
ECET 340 Week 4 HomeWork 4
ECET 340 Week 4 iLab 4
ECET 340 Week 5 HomeWork 5
ECET 340 Week 5 iLab 5
ECET 340 Week 6 HomeWork 6
ECET 340 Week 6 iLab 6
ECET 340 Week 7 HomeWork 7
ECET 340 Week 7 iLab 7
http://www.homeworktab.com/ecet-340-devry/ecet-340-complete-course
ECET 340 Week 1 HomeWork 1
- Give three examples each of internal and external peripheral devices as referenced to the HCS12 microcontroller and not an entire PC. (2 points)
- Given “the requirements of each signal’s destination must match the capabilities of the signal’s source,” name some of the electrical signal parameters that must be considered when designing an interface between two different hardware components. (2 points)
- Write down the instructions needed to program PORT A for pins PA7, PA4-PA0 as inputs and PA6-PA5 as outputs. Answer should be a valid C language statement. (2 points)
- Write an instruction sequence to output the value $35 to PORT P. Use the C language only when writing your answer; - no assembly language. (2 points)
http: //www.homeworktab.com/ecet-340-devry/ecet-340-week-1-homework-1
ECET 340 Week 1 iLab 1
OBJECTIVES:
To become familiar with Microcontroller MC9S12 parallel ports and how simple input and output devices are interfaced through them.
To learn how to program I/O instructions in C language.
To learn how to organize a program to read data from input ports, process the data, and display the result on a simple output device.
http://www.homeworktab.com/ecet-340-devry/ecet-340-week-1-ilab-1
ECET 340 Week 2 HomeWork 2
- Where does program control transfer to when an interrupt occurs? +2 points
- Which one of the following Interrupts has highest priority? +2 points
- RAM Vector table addresses $3E52 belongs to which interrupt? +2 points
- Before exiting an ISR, the programmer should use which command? +2 points
- In which one of the following sequences is the stack pulled by rti? +3 points
- Given the starting address for the TC0 Interrupt is to become $5000. Write the assembly instruction necessary to place this ISR address into the interrupt vector table and then unmask the interrupt (assembly only). +3 points
- Write the C statements needed to place the address of an interrupt service routine that is to be called PortJ_handler into the vector address for the Port J interrupt and then unmask the interrupt. +3 points
- Circle the interrupt below that will have highest priority after the statement ;is executed. +3 points
http: //www.homeworktab.com/ecet-340-devry/ecet-340-week-2-homework-2
ECET 340 Week 2 iLab 2
ECET 340 Week 2 iLab 2
http://www.homeworktab.com/ecet-340-devry/ecet-340-week-2-ilab-2
ECET 340 Week 3 HomeWork 3
- Sketch a circuit that can be used to debounce a pushbutton and explain how it works. (4 points max)
- In Figure 7.32 on page 339 of the Huang textbook, if the row has and the columnsare , which key is pressed? (2 points max)
- In Figure 7.32 on page 339 of the Huang textbook, explain why the 10kΩ resistors ties to VCC are required. (2 points max)
- Write down the lines of C code (interrupt service routine, ISR) that generates an interrupt when Port H pin 0 becomes a logic “1”. Within this ISR, disable interrupts, clear the interrupt flag, then enable interrupts, and return from routine. I also want the routine or lines of C code that initialize Port H pin 0 to be used as an interrupt (hint: think data direction register) (2 points max)
- Write down the C statements you would need to add to the main program of the keypad driver program given in lecture and lab in order to store the key characters to a buffer area of memory called keys_entered and exit the program as soon as either seven keypresses are entered or the the “D” key is entered. (Counts as two questions) (4 points max….you need to use arrays in C code)
- State the functions of pins RS, E and R/W in the LCD. (4 points max)
- Give the state of RS, E and R/W~, and the command code (in hex) for the 20th location, line 2 on the 40x2 LCD described in lecture. (2 points max)
http: //www.homeworktab.com/ecet-340-devry/ecet-340-week-3-homework-3
ECET 340 Week 3 iLab 3
OBJECTIVES:
To learn the basic operation of a keypad.
To understand how to interface a keypad to a microprocessor.
http://www.homeworktab.com/ecet-340-devry/ecet-340-week-3-ilab-3
ECET 340 Week 4 Homework 4
- Determine the conversion time for an ADC0804 (8-bit), where 66 clocks per bit are required, if its clock frequency is 50 kHz.
- If an 8-bit SAR has Vref = 10 V, what is the binary value for an input voltage of 7.28 V?
- What is the percent error for the binary answer found in Problem #2?
- Given an 24 MHz bus speed. Write down the line(s) of instruction which set the ATD1 unit for 2MHz conversion frequency, 10-bit resolution and 8 A-to-D clocks per sample time.
- A single 10-bit, left justified conversion of 3.75V is complete in ATD0. Assume and
i. Name the register(s) where the result of the conversion is found
http: //www.homeworktab.com/ecet-340-devry/ecet-340-week-4-homework-4
ECET 340 Week 4 iLab 4
OBJECTIVES:
To learn how to use A-to-D converters to digitize signals from analog input devices.
To learn how to write a C language program that samples the data from an analog device, digitizes it and formats it for output on an LCD.
http://www.homeworktab.com/ecet-340-devry/ecet-340-week-4-ilab-4
ECET 340 Week 5 HomeWork 5
- Explain, briefly, why an analog restoring filter is sometimes used at the output of a DAC.
- Given Iref = 2 mA for a DAC1408 IC, find Iout for the input 1110 1110
- Find the number of discrete voltages output by a 12-bit DAC. Show work.
- Use the internet to locate the data sheet for an MC1408 DAC. From it find, for the MC1408-7 version, the following:
a. The settling time
b. Accuracy at full scale output current (1.99 mA), 25ºC
http: //www.homeworktab.com/ecet-340-devry/ecet-340-week-5-homework-5
ECET 340 Week 5 iLab 5
Scenario/Summary
This week’s lab covers two areas, conversion of digital HCS12 signals to an analog format, and the use of a Serial Peripheral Interface (SPI) to transfer data, and commands between the HCS12, and the DAC peripheral. Deliverables For this lab, the deliverables include the cover sheet, filled-in sections of the lab report, photographs (online), or instructor sign-offs (onsite), and answers to the questions. The cover sheet must be completed in typed format.
http://www.homeworktab.com/ecet-340-devry/ecet-340-week-5-ilab-5
ECET 340 Week 6 HomeWork 6
- What are the four main functions of the HC12 Timer unit?
- Two input capture events occur at counts 0x1037 and 0xFF20 of the free-running counter. How many counts (in decimal) have transpired between these two events?
- What is the maximum time possible before the free-running counter overflows when the e MHz?
- Two input capture events occur at 0x1037 and 0x002A. If the prescaler bits PR[2:1:0] are set to 101 and the e clock is 24 MHz, how much time as transpired between the two events?
http: //www.homeworktab.com/ecet-340-devry/ecet-340-week-6-homework-6
ECET 340 Week 6 iLab 6
ECET 340 Week 6 iLab 6
http://www.homeworktab.com/ecet-340-devry/ecet-340-week-6-ilab-6
ECET 340 Week 7 HomeWork 7
- The movable part of the solenoid is the: +2 points
- Why is the 6N139 optoisolator used in the interfaces to devices such as large motors? +2 points
- Calculate the number of steps per revolution for a stepper motor with a step angle of 7.5°. +2 points
- How is stepper motor speed controlled? State any two ways a program can do this. +2 points
- For this problem, you should look at Figure 5A on the next page as a physical example of a stepper motor. It is an example of a stepper motor with four (4) magnetic windings which are connected via an interface circuit to the HCS12 Port T pins 4, 5, 6, & 7, with an armature (rotor) that has 12 poles (combined number of North and South magnetic poles). Notice how each step rotates the rotor 30 degrees, and notice the logic states on the Port T pins going from Step 1 to Step 2. To rotate the rotor 90 degrees, you would need three (3) steps (see figure 5A for explanation).
http: //www.homeworktab.com/ecet-340-devry/ecet-340-week-7-homework-7
ECET 340 Week 7 iLab 7
ECET 340 Week 7 iLab 7
http://www.homeworktab.com/ecet-340-devry/ecet-340-week-7-ilab-7