Motorola Axiom CMD11E1 Guía de usuario Pagina 48

  • Descarga
  • Añadir a mis manuales
  • Imprimir
  • Pagina
    / 101
  • Tabla de contenidos
  • MARCADORES
  • Valorado. / 5. Basado en revisión del cliente
Vista de pagina 47
48 CHAPTER 3. FUNCTIONS AND BIT MANIPULATIONS
2. Connect the input circuit as shown in figure 3.2.
3.10.2 Controlling the LED
Use memory modify, MM $1000, command to modify PORTA. Change the value
in the location to 00, 10, 20, and 30. (Note: When you communicate directly
with the HC11 using BUFFALO commands, you do not type the $.) After each
change, look at the state of the light emitting diodes and write down what you
see. Provide a brief explanation of what you see.
Using the methods you learnt in earlier labs, write a program that will read
the keyboard and depending on what the user types, perform the following:
Key Action
Q or q Turn on the LEFT led. The state of other led should not change.
Z or Z Turn off the LEFT led. The state of other led should not change.
E or e Turn on the RIGHT led. The state of other led should not change.
C or c Turn off the RIGHT led. The state of other led should not change.
3.10.3 Reading an external switch
Use memory dump to see the contents of $1000. Close the input switch and dump
the contents of location $1000. Repeat the experiment with the switch open.
Write down what you see and provide a brief explanation of your observation.
Write a program that will, in an infinite loop, print either CLOSED or OPEN,
depending on the state of the switch. The program should continually monitor
the state of the switch, and print CLOSED is the switch is closed. Or else it should
print OPEN.
Vista de pagina 47
1 2 ... 43 44 45 46 47 48 49 50 51 52 53 ... 100 101

Comentarios a estos manuales

Sin comentarios