nes/src/Controller.cpp
Selim Mustafaev 796828fa01 Adding controller.
Adding logging.
Fixing lots of bugs.
2023-09-18 00:10:41 +03:00

18 lines
258 B
C++

//
// Created by selim on 9/17/23.
//
#include "Controller.h"
namespace nes {
Controller::Controller(): _data{} {
}
uint8_t Controller::read() {
uint8_t result = (_data & 0x80) > 0;
_data <<= 1;
return result;
}
}