Description
This CircuitPython script is designed to display a visual Fibonacci sequence-based clock on an Adafruit-compatible display. Using the board, displayio, and RTC libraries, it draws colored rectangles on the screen, which represent Fibonacci numbers. The clock updates its display every minute, with the color of the rectangles changing based on the current time (hours and minutes).
Display Logic
- Fibonacci squares of sizes: 1, 1, 2, 3, and 5 are drawn.
- The squares are positioned to fit on the screen with a 1-pixel border.
- The clock represents hours and minutes through color-coded squares:
- Red: Hours (decomposed into Fibonacci numbers).
- Green: Minutes (in multiples of 5).
- Blue: If both hours and minutes are represented by the same Fibonacci number.
Example Output
Rectangles will be filled based on the current time:
- 1×1, 1×1, 2×2, 3×3, and 5×5 Fibonacci squares on the screen.
- These squares will change color every minute to reflect the current time.
cPYTHON fibonacci.txt