Request instructionCounter in GodmodeState #160
Labels
arduino mocks
Compilation mocks for the Arduino library
duplicate
This issue or pull request already exists
enhancement
New feature or request
Sometimes we need to test not just the value of pins but the order in which they are set. For example, many devices (such as LiquidCrystal) have a "clock" pin that is used to inform the device that the other pins have now been populated with useful values (see LiquidCrystal.cpp:303).
At first it seems that this could be done by incrementing the microsecond clock with each instruction but this is unrealistic (it implies a 1MHz machine) and makes some other tests less practical (it is nice that Blink can test for exactly microseconds for a delay() call).
My suggestion is that each event also have an instruction counter so we could determine what pin values were set before the clock pulse. Or is there something that does this that I'm missing?
The text was updated successfully, but these errors were encountered: