コード例 #1
0
ファイル: MyMenu.cpp プロジェクト: HarrierBR/lb-Arduino-Code
uint8_t MyMenu::getKeyPressed(void)
{
	signed char keyPadVal2;
	keyPadVal2 = pollKeypad();
	if (keyPadVal2 == NONE)
	return((byte)NONE);
	waitForKeyRelease();
	return((byte)keyPadVal2);
}
コード例 #2
0
ファイル: main.c プロジェクト: embs-be/ledTimer
void ledOff(void) {
    SWDTEN = 0; // Disable WDT
    GPIO = 0x30; //LED off

    if (keyPressed) {
        waitForKeyRelease();
    }

    handler = waitForKeyPress;
}
コード例 #3
0
ファイル: MyMenu.cpp プロジェクト: HarrierBR/lb-Arduino-Code
uint8_t MyMenu::waitKeyPressed(void)
{
	uint8_t keyPadVal3;
	do
	{
		keyPadVal3 = pollKeypad();
	}
	while (keyPadVal3 == NONE);
	delay(5);
	waitForKeyRelease();
	return((uint8_t)keyPadVal3);
}
コード例 #4
0
ファイル: clipboardmonitor.cpp プロジェクト: pmros/CopyQ
    void synchronize()
    {
        if (m_syncData == NULL || m_syncTimer.isActive())
            return;

        if (m_syncTo == QClipboard::Selection && waitForKeyRelease()) {
            m_syncTimer.start();
            return;
        }

        Q_ASSERT( isSynchronizing() );
        setClipboardData(m_syncData, m_syncTo);
        m_syncData = NULL;
    }
コード例 #5
0
ファイル: main.c プロジェクト: embs-be/ledTimer
void waitForKeyPress(void) {
    GPIO = 0; //LED on
    waitForKeyRelease();
    keyReleased();
}