class Chip8::Keyboard

Included Modules

Defined in:

devices/keyboard.cr

Constant Summary

KEY_MAP = {1_u8 => SF::Keyboard::Num1, 2_u8 => SF::Keyboard::Num2, 3_u8 => SF::Keyboard::Num3, 12_u8 => SF::Keyboard::Num4, 4_u8 => SF::Keyboard::Q, 5_u8 => SF::Keyboard::W, 6_u8 => SF::Keyboard::E, 13_u8 => SF::Keyboard::R, 7_u8 => SF::Keyboard::A, 8_u8 => SF::Keyboard::S, 9_u8 => SF::Keyboard::D, 14_u8 => SF::Keyboard::F, 10_u8 => SF::Keyboard::Z, 0_u8 => SF::Keyboard::X, 11_u8 => SF::Keyboard::C, 15_u8 => SF::Keyboard::V}

1 2 3 C 4 5 6 D 7 8 9 E A 0 B F

Instance Method Summary

Instance methods inherited from module Chip8::KeyboardProtocol

get_pressed_key : UInt8 | Nil get_pressed_key, is_key_pressed(key : UInt8) : Bool is_key_pressed

Instance Method Detail

def get_pressed_key : UInt8 | Nil #

[View source]
def is_key_pressed(key : UInt8) : Bool #

[View source]