fixed build error and warning

reduced QuadTari switch timer value
This commit is contained in:
Thomas Jentzsch 2020-09-02 13:19:04 +02:00
parent 0c02892265
commit 6c301621b3
3 changed files with 3 additions and 3 deletions

View File

@ -30,7 +30,7 @@ QuadTariWidget::QuadTariWidget(GuiObject* boss, const GUI::Font& font,
{
string label = (isLeftPort() ? "Left" : "Right") + string(" (QuadTari)");
StaticTextWidget* t = new StaticTextWidget(boss, font, x, y + 2, label);
QuadTari& qt = dynamic_cast<QuadTari&>(controller);
QuadTari& qt = (QuadTari&)controller;
x += font.getMaxCharWidth() * 2;
y = t->getBottom() + font.getFontHeight() * 1.25;

View File

@ -178,7 +178,7 @@ class Controller : public Serializable
Update the entire digital and analog pin state according to the
events currently set.
*/
virtual void update() { };
virtual void update() { }
/**
Returns the name of this controller.

View File

@ -61,7 +61,7 @@ bool QuadTari::read(DigitalPin pin)
// can switch the controller multiple times per frame
// (we can't just read 60 times per second in the ::update() method)
constexpr int MIN_CYCLES = 30 * 76; // minimal cycles required for stable input switch (TODO: define cycles)
constexpr int MIN_CYCLES = 20 * 76; // minimal cycles required for stable input switch (TODO: define cycles)
bool readFirst;
if(mySystem.tia().dumpPortsCycles() < MIN_CYCLES)