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...)
 
Zeile 1: Zeile 1:
 
<pre>
 
<pre>
 +
CLOCK_USED()
 +
 +
CONTROL_START
 +
 
THREAD(mainloop)
 
THREAD(mainloop)
 
         dnl Update the time ...
 
         dnl Update the time ...
Zeile 20: Zeile 24:
 
         THREAD_START(mainloop)
 
         THREAD_START(mainloop)
 
END
 
END
 +
 +
CONTROL_END
 
</pre>
 
</pre>
  
 
[[Category:Control6 Examples]]
 
[[Category:Control6 Examples]]

Version vom 31. Juli 2011, 12:20 Uhr

CLOCK_USED()

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