Einfache Uhr: Unterschied zwischen den Versionen

Aus Ethersex_Wiki
Wechseln zu: Navigation, Suche
(Die Seite wurde neu angelegt: <pre> THREAD(mainloop) dnl Update the time ... TTY_SELECT(clock) TTY_HOME() TTY_WRITE_TIME() WAIT(1) THREAD_END(mainloop) ON S...)
 
 
(2 dazwischenliegende Versionen desselben Benutzers werden nicht angezeigt)
Zeile 1: Zeile 1:
 
<pre>
 
<pre>
 +
CONTROL_START
 +
 
THREAD(mainloop)
 
THREAD(mainloop)
 
         dnl Update the time ...
 
         dnl Update the time ...
Zeile 20: Zeile 22:
 
         THREAD_START(mainloop)
 
         THREAD_START(mainloop)
 
END
 
END
 +
 +
CONTROL_END
 
</pre>
 
</pre>
 +
 +
Solltet ihr beim kompilieren eine Fehlermeldung erhalten, dann versucht mal eine Zeile "CLOCK_USED()" vor dem CONTROL_START einzufügen.
  
 
[[Category:Control6 Examples]]
 
[[Category:Control6 Examples]]

Aktuelle Version vom 31. Juli 2011, 16:16 Uhr

CONTROL_START

THREAD(mainloop)
        dnl Update the time ...
        TTY_SELECT(clock)
        TTY_HOME()
        TTY_WRITE_TIME()

        WAIT(1)
THREAD_END(mainloop)

ON STARTUP DO
        dnl Initialize display and write out greeting
        TTY_CLEAR()
        TTY_GOTO(1,0)
        TTY_WRITE("Hallo stesie\n")

        dnl Create sub-window to display a clock at the upper right-hand side
        TTY_CREATE_WINDOW(clock, 1, 8, 0, COLS - 8)

        THREAD_START(mainloop)
END

CONTROL_END

Solltet ihr beim kompilieren eine Fehlermeldung erhalten, dann versucht mal eine Zeile "CLOCK_USED()" vor dem CONTROL_START einzufügen.