1
0
mirror of https://github.com/TomHarte/CLK.git synced 2025-04-04 13:31:26 +00:00
This commit is contained in:
Thomas Harte 2024-03-26 12:27:37 -04:00
parent 342d90c929
commit 3ba12630ab
2 changed files with 6 additions and 4 deletions

View File

@ -51,10 +51,10 @@ void Bus::set_clock_data(bool clock_pulled, bool data_pulled) {
if(prior_data != data_) {
if(data_) {
logger.info().append("S");
// logger.info().append("S");
signal(Event::Start);
} else {
logger.info().append("P");
// logger.info().append("P");
signal(Event::Stop);
}
} else {
@ -64,10 +64,10 @@ void Bus::set_clock_data(bool clock_pulled, bool data_pulled) {
}
if(data_) {
logger.info().append("0");
// logger.info().append("0");
signal(Event::Zero);
} else {
logger.info().append("1");
// logger.info().append("1");
signal(Event::One);
}
}

View File

@ -25,6 +25,8 @@ struct CMOSRAM: public I2C::Peripheral {
if(expecting_address_) {
address_ = value;
} else {
printf("Write to %d\n", address_);
++address_;
// TODO: write to RAM.
}
}