Conway’s game of life on arduino
Upcoming SlideShare
Loading in...5
×
 

Conway’s game of life on arduino

on

  • 2,379 views

Project with Arduino Mega and 3 led boards.

Project with Arduino Mega and 3 led boards.

Statistics

Views

Total Views
2,379
Views on SlideShare
2,379
Embed Views
0

Actions

Likes
0
Downloads
9
Comments
0

0 Embeds 0

No embeds

Accessibility

Categories

Upload Details

Uploaded via as Microsoft PowerPoint

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

Conway’s game of life on arduino Conway’s game of life on arduino Presentation Transcript

  • Conway’s game of life on Arduino
    A 48x32 led matrix controlled by an Arduino able to project output from arbitrary sources (e.g. game of life)
  • Goal
    To make a led matrix on which Conway’s game of life can run
    And enable it to display other stuff, like
    Ticker tape
    Clock
    Temperature
    Menu navigation?
  • Conway’s game of life
    World is a grid(x, y)
    Each cell is alive or dead
    Each iteration for each cell = grid(x, y):
    If cell is alive,
    It dies from loneliness if it has < 3 alive neighbors
    It dies from food shortage if it has > 4 alive neighbors
    It stays alive if it has 3 alive neighbors
    If cell is dead,
    It reincarnates if it has exactly 3 alive neighbors
  • Setup
    Arduino
    3 Led matrices (3 x 4x2(8x8), incl 2 controllers)
    Breadboard
    Wires, some resistors, leds and buttons
    For fun
    Thermometer
    Clock
  • Arduino specs
  • ARDUINO SPECS
    Microcontroller: ATmega2560
    Flash memory: 256 kB
    (of which 8 kB is used by bootloader)
    SRAM: 8 kB
    EEPROM: 4 kB
    Clock speed: 16 MHz
  • Arduino specs
    54 digital input/output pins
    16 analog inputs
    4 UARTs (serial ports)
    16 MHz crystal oscillator
    USB connection
    ICSP header
    Reset button
  • Arduino specs
    54 digital input/output pins
    16 analog inputs
    4 UARTs (hardware serial ports)
    16 MHz crystal oscillator
    USB connection
    ICSP header
    Reset button
  • Arduino specs
    54 digital input/output pins
    16 analog inputs
    4 UARTs (hardware serial ports)
    16 MHz crystal oscillator
    USB connection
    ICSP header
    Reset button
  • Arduino specs
    54 digital input/output pins
    16 analog inputs
    4 UARTs (hardware serial ports)
    16 MHz crystal oscillator
    USB connection
    ICSP header
    Reset button
  • Arduino specs
    54 digital input/output pins
    16 analog inputs
    4 UARTs (hardware serial ports)
    16 MHz crystal oscillator
    USB connection
    ICSP header
    Reset button
  • Arduino specs
    54 digital input/output pins
    16 analog inputs
    4 UARTs (hardware serial ports)
    16 MHz crystal oscillator
    USB connection
    ICSP header
    Reset button
  • Arduino specs
    54 digital input/output pins
    16 analog inputs
    4 UARTs (hardware serial ports)
    16 MHz crystal oscillator
    USB connection
    ICSP header
    Reset button
  • Arduino specs
    54 digital input/output pins
    16 analog inputs
    4 UARTs (hardware serial ports)
    16 MHz crystal oscillator
    USB connection
    ICSP header
    Reset button
  • Arduino specs
    54 digital input/output pins
    16 analog inputs
    4 UARTs (hardware serial ports)
    16 MHz crystal oscillator
    USB connection
    ICSP header
    Reset button
  • Wiring the system
    Solder?
  • Wiring the system
    Solder?
  • Wiring the system
    Breadboard!
  • Wiring the system
    Breadboard!
  • Wiring the system
    Breadboard!
  • Buttons
    Initialize game of life world
  • Buttons
    Initialize game of life world
  • LED boards
  • LED boards
    ?
  • LED boards
    No memory on controller board
    Consequence: fast refresh rate needed
    External power supply (5V)
    16 pin connector
  • LED BOARDS
  • LED BOARDS
  • LED BOARD PROTOCOL
    Serial data transfer
    Devided into 2 halves (UDAT, LDAT)
    Clock and A[2..0] to control the leds
    No state-memory
  • LED BOARD PROTOCOL
  • LED BOARD PROTOCOL example
    Psuedo-code for controlling the LED-board
  • THERMOMETER
    Component: DS1820
  • Clock (RTC)
    Solder time!
  • Programming arduino
    Download SDK from Arduino website.
    Based on Processing SDK
    Write program:
    void Setup() {}
    void Loop() {}
    Upload to Arduino (USB) and run
    Monitor by serial data transfer (USB)
  • Programming arduino
    Problem #1:
    Memory too small to hold 2xLED matrix array representationAND a 3x5 font map
    Problem #2:
    Arduinotoo slow to fluently display Game of Life
  • DEMO
  • More info
    Conway’s Game of Life
    http://www.edesign.nl/2010/04/22/the-game-of-office-decoration/
    Arduino Mega
    http://arduino.cc/en/Main/ArduinoBoardMega2560