(C)stachan 08.02.2024

Task :: Fibonacci v2

fibonacci

  • Das Programm soll die Fibonacci-Folge in Intervallen von T1=60000 endlos ausgeben. Sobald die Zahl 89 erreicht ist, soll die Folge in umgekehrter Reihenfolge wieder Richtung 0 ausgegeben werden.
  • Während die Zahlen ausgegeben werden, leuchtet die grüne LED dauerhaft.
  • Wird der rote Knopf gedrückt, wird die Richtung umgekehrt und der Text “Richtungswechsel” ausgegeben.
  • Die grüne LED wird ausgeschaltet und die rote LED leuchtet für 1T. Nutzen Sie HIGH und LOW statt TOGGLE.

  • The programme should output the Fibonacci sequence endlessly at intervals of T1=60000. As soon as the number 89 is reached, the sequence is to be output again in reverse order towards 0.
  • While the numbers are being output, the green LED lights up continuously.
  • If the red button is pressed, the direction is changed and the text ‘Change direction’ is output.
  • The green LED is switched off and the red LED lights up for 1T. Use HIGH and LOW instead of TOGGLE.