24
Input Devices

Input Devices - Milwaukee School of Engineering › ... › EE4980 › files4980 › input_devices.… · Input Devices •Keypad PT0 PT1 PT2 PT3 PT4 PT5 PT6 PT7 Port[0:3] = Inputs

  • Upload
    others

  • View
    4

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Input Devices - Milwaukee School of Engineering › ... › EE4980 › files4980 › input_devices.… · Input Devices •Keypad PT0 PT1 PT2 PT3 PT4 PT5 PT6 PT7 Port[0:3] = Inputs

Input Devices

Page 2: Input Devices - Milwaukee School of Engineering › ... › EE4980 › files4980 › input_devices.… · Input Devices •Keypad PT0 PT1 PT2 PT3 PT4 PT5 PT6 PT7 Port[0:3] = Inputs

2 © tjEE 4980 – MES

Input Devices

• Keypad

Page 3: Input Devices - Milwaukee School of Engineering › ... › EE4980 › files4980 › input_devices.… · Input Devices •Keypad PT0 PT1 PT2 PT3 PT4 PT5 PT6 PT7 Port[0:3] = Inputs

3 © tjEE 4980 – MES

Input Devices

• Keypad

PT0 PT1 PT2 PT3

PT4

PT5

PT6

PT7

Port[0:3] = InputsVdd

Port[7:4] = OutputsPull one of

PT4, PT5, PT6, PT7 low

If a key is pressedThe associated PT[3:0] inputwill be pulled low

Scanning:Cycle through the outputs, check the inputs

Page 4: Input Devices - Milwaukee School of Engineering › ... › EE4980 › files4980 › input_devices.… · Input Devices •Keypad PT0 PT1 PT2 PT3 PT4 PT5 PT6 PT7 Port[0:3] = Inputs

4 © tjEE 4980 – MES

Input Devices

• Keypad

PT0 PT1 PT2 PT3

PT4

PT5

PT6

PT7

Port[0:3] = Inputs with pull-up turned on

Port[7:4] = OutputsPull one of

PT4, PT5, PT6, PT7 low

If a key is pressedThe associated PT[3:0] inputwill be pulled low

Scanning:Cycle through the outputs, check the inputs

Page 7: Input Devices - Milwaukee School of Engineering › ... › EE4980 › files4980 › input_devices.… · Input Devices •Keypad PT0 PT1 PT2 PT3 PT4 PT5 PT6 PT7 Port[0:3] = Inputs

7 © tjEE 4980 – MES

Input Devices

• Keyboard

• Mechanical Switches

Page 8: Input Devices - Milwaukee School of Engineering › ... › EE4980 › files4980 › input_devices.… · Input Devices •Keypad PT0 PT1 PT2 PT3 PT4 PT5 PT6 PT7 Port[0:3] = Inputs

8 © tjEE 4980 – MES

Input Devices

• Keyboard

• Mechanical Switches

Page 10: Input Devices - Milwaukee School of Engineering › ... › EE4980 › files4980 › input_devices.… · Input Devices •Keypad PT0 PT1 PT2 PT3 PT4 PT5 PT6 PT7 Port[0:3] = Inputs

10 © tjEE 4980 – MES

Input Devices

• Keyboard• Controller

Page 11: Input Devices - Milwaukee School of Engineering › ... › EE4980 › files4980 › input_devices.… · Input Devices •Keypad PT0 PT1 PT2 PT3 PT4 PT5 PT6 PT7 Port[0:3] = Inputs

11 © tjEE 4980 – MES

Input Devices

• Keyboard

• Controller

• Performs debounce – 1-5ms typical

• Polling rate - < 200Hz

• Interface – USB, wireless, SPI, TWI

Page 12: Input Devices - Milwaukee School of Engineering › ... › EE4980 › files4980 › input_devices.… · Input Devices •Keypad PT0 PT1 PT2 PT3 PT4 PT5 PT6 PT7 Port[0:3] = Inputs

12 © tjEE 4980 – MES

Input Devices

• Mouse

• Opto-Mechanical

Page 13: Input Devices - Milwaukee School of Engineering › ... › EE4980 › files4980 › input_devices.… · Input Devices •Keypad PT0 PT1 PT2 PT3 PT4 PT5 PT6 PT7 Port[0:3] = Inputs

13 © tjEE 4980 – MES

Input Devices

• Mouse

• Opto-Mechanical

Page 14: Input Devices - Milwaukee School of Engineering › ... › EE4980 › files4980 › input_devices.… · Input Devices •Keypad PT0 PT1 PT2 PT3 PT4 PT5 PT6 PT7 Port[0:3] = Inputs

14 © tjEE 4980 – MES

Input Devices

• Mouse

• Opto-Mechanical

Page 15: Input Devices - Milwaukee School of Engineering › ... › EE4980 › files4980 › input_devices.… · Input Devices •Keypad PT0 PT1 PT2 PT3 PT4 PT5 PT6 PT7 Port[0:3] = Inputs

15 © tjEE 4980 – MES

Input Devices

• Mouse

• Opto-Mechanical

Page 16: Input Devices - Milwaukee School of Engineering › ... › EE4980 › files4980 › input_devices.… · Input Devices •Keypad PT0 PT1 PT2 PT3 PT4 PT5 PT6 PT7 Port[0:3] = Inputs

16 © tjEE 4980 – MES

Input Devices

• Mouse

• Optical Mouse

Page 17: Input Devices - Milwaukee School of Engineering › ... › EE4980 › files4980 › input_devices.… · Input Devices •Keypad PT0 PT1 PT2 PT3 PT4 PT5 PT6 PT7 Port[0:3] = Inputs

17 © tjEE 4980 – MES

Input Devices

• Mouse

• Optical Mouse

Page 18: Input Devices - Milwaukee School of Engineering › ... › EE4980 › files4980 › input_devices.… · Input Devices •Keypad PT0 PT1 PT2 PT3 PT4 PT5 PT6 PT7 Port[0:3] = Inputs

18 © tjEE 4980 – MES

Input Devices

• Mouse

• Optical Mouse Sensor

• By comparing images – direction and distance can be calculated

Page 19: Input Devices - Milwaukee School of Engineering › ... › EE4980 › files4980 › input_devices.… · Input Devices •Keypad PT0 PT1 PT2 PT3 PT4 PT5 PT6 PT7 Port[0:3] = Inputs

19 © tjEE 4980 – MES

Input Devices

• Mouse

Page 20: Input Devices - Milwaukee School of Engineering › ... › EE4980 › files4980 › input_devices.… · Input Devices •Keypad PT0 PT1 PT2 PT3 PT4 PT5 PT6 PT7 Port[0:3] = Inputs

20 © tjEE 4980 – MES

Input Devices

• Mouse

Page 21: Input Devices - Milwaukee School of Engineering › ... › EE4980 › files4980 › input_devices.… · Input Devices •Keypad PT0 PT1 PT2 PT3 PT4 PT5 PT6 PT7 Port[0:3] = Inputs

21 © tjEE 4980 – MES

Input Devices

• Mouse

Page 22: Input Devices - Milwaukee School of Engineering › ... › EE4980 › files4980 › input_devices.… · Input Devices •Keypad PT0 PT1 PT2 PT3 PT4 PT5 PT6 PT7 Port[0:3] = Inputs

22 © tjEE 4980 – MES

Input Devices

• Mouse

• Optical Mouse Sensor

• Output is a quadrature signal - just like a mechanical mouse

Page 23: Input Devices - Milwaukee School of Engineering › ... › EE4980 › files4980 › input_devices.… · Input Devices •Keypad PT0 PT1 PT2 PT3 PT4 PT5 PT6 PT7 Port[0:3] = Inputs

23 © tjEE 4980 – MES

Input Devices

• Mouse

• Optical Mouse Sensor

• Frame Rate: 1500 frames/sec

• Typical resolution: 400-800 cpi (counts/inch)

• Speed: 14ips (inches per second)

• Typical sensor dimension: 16x16 to 32x32

• Typical Path error: 0.5%

Page 24: Input Devices - Milwaukee School of Engineering › ... › EE4980 › files4980 › input_devices.… · Input Devices •Keypad PT0 PT1 PT2 PT3 PT4 PT5 PT6 PT7 Port[0:3] = Inputs

24 © tjEE 4980 – MES

Input Devices

• Mouse

• Optical Mouse Sensor

• Limited focal range