|1930 - meetup|
|1900 BRMCW - vyuka telegrafie|
The rear wall of the main brmlab room faces the street around the building. There is a row of 23 square glass blocks at the top of the wall that are translucent and visible from the outside.
We would like to make a 23×1 pixel RGB display out of these glass blocks, showing cool animations and funky patterns 'round the clock, possibly also indicating open/closed brmlab status. It could be controlled by custom programs, over the net or interactively using e.g. a hacked music keyboard!
We have a row of 23 LEDs hooked up and working, connected to the sargon computer, where Python control software (rainbow or audio spectrum) runs in a dedicated screen.
Our current plan is to switch to smaller control boards with better LED interconnect, and build a second ledbar row so that we can finally move the current one to the ceiling. As of June 2014, it was set in motion again. (All these changes should be hardware-only, firmware + software compatible.)
Each glass block is illuminated by a single RGB LED node; 23 nodes are chained together with possibility of individual control.
Each node consists of three LEDs (R, G, B) with sufficient luminiscence. Each LED is hooked to PWM-capable control for smooth brightness control. The node needs to hold the LEDs in stable position and direct most of the light at the glass block, also dispersing it evenly.
The node chain needs to be hooked up to a microcontroller. The LEDs might require non-trivial current, so intermediate transistors are required. We need to PWM-control 23*3 = 69 individual outputs.
The microcontroller is connected to a computer (e.g. sargon) and simple control software.
Version 2 is based on TLC59116 constant-current sink LED driver with I2C interface. TLC59116F could be also used, but circuit must be slightly modified (PNP → NPN + base pull-up resistors). TLC59116 allows up to 15 boards on one I2C bus.
In v2.0 (deployed), power distribution design is not ideal, current combination (RJ-45 + UTP cable) is not designed for high-current (up to 5 A) applications.
In v2.2 (in progress), more appropriate cables and connectors are used, and PCBs have lower form factor.
Schematics and boards are to be found in Git repository.
Current row, to be moved to the ceiling:
New row that will point inside the room:
|part||# per board||url|
|resistor 10k SMD 1206||6||http://www.gme.cz/r1206-10k-1-p900-179|
|resistor 2k7 SMD 1206||1||http://www.gme.cz/r1206-2k7-1-p900-182|
|resistor 4k7 SMD 1206||1||http://www.gme.cz/r1206-4k7-1-p900-248|
|resistor 220R SMD 1206||1||http://www.gme.cz/r1206-220r-1-p900-295|
|SMD LED 1206||1||http://www.gme.cz/led-1206-green-42-120-p960-285|
|pin header 2×4||1||http://www.gme.cz/oboustranny-kolik-xinya-s1g40-2-54mm-p832-021|
|ceramic capacitor 100n SMD 1206||1||http://www.gme.cz/cks1206-100n-50v-x7r-yag-10-p905-081|
|ceramic capacitor 1u SMD 1206||1||http://www.gme.cz/cks1206-1u-16v-x7r-yag-10-p905-136|
|electrolytic capacitor 22u E2.5-5||1||http://www.gme.cz/ce-22u-25v-jam-sk-5x11-rm2-bulk-p123-069|
|4-pin molex connector + cable||5|| http://www.gme.cz/kontakt-xinya-pff02-01fg-p800-162 +
Total: cca 220 CZK per board + shipping
The software is in Git: http://github.com/brmlab/ledbar
Two versions of firmware are available; standalone firmware with some builtin animations, and controlled firmware accepting raw RGB pixel value blocks on the serial.
The control software can either just show pixels on the display, or when given a device name (/dev/ttyUSB0), it will also send pixel values to the Arduino.
Later, we can extend the display also to the storage room (extra 9-pixel row, and half of the second row visible too).
We might also try to split a single glass block to 2×2 pixel matrix, maybe cooperating with MoodyLight.
But let's start simple!
We need to get 24 LEDs (23 + 1 spare). The money required is CZK 150 per LED - it is a bit expensive, but it covers an extremely bright RGB LED, well visible through the glass even in bright daylight and from reliable origin. A bit of extra change is welcome to cover the supporting electronics (transistors alone cost 300CZK).
The LEDs you donated will have your nick written on the back of their boxes, to keep eternal memory of your contribution!
Total LEDs sponsored: 24
LEDs to go: 0
Sargon donated brmduino + FTDI.
Sargon arranged TI samples of TLC5940. These are fancy serial-controllable, daisy-chainable LED drivers, each has 16 PWM current sink outputs. Each output is hooked up to the base of a PNP power transistor (part TODO), with LED cathode on the emitor. TLC current is limited to less than 10mA per channel using a 2k7 resistor on the current control pin. 100nF bypass capacitor per chip.
We need five TLCs to drive 23 RGB LEDs; we have a bunch, slightly less than we need. They are very fragile if too much current is drawn or there is bad connection where there shouldn't be, so we need to monitor them carefully anytime a change in circuit is made. During development (probably mostly due to low-quality breadboard), we destroyed about six pieces.
We already had all five TLCs set up on a breadboard, daisy chaining set up and working transistor drive.
Connectors: We use RJ45 connectors and ethernet cables for all interconnects. Should handle the currents fine and it is robust, easy to get and quick to crimp.
ledbar brmduino shield v2: Eagle files
Current is now sourced in ATX supply. We consider replacing it with: http://www.djoro.cz/store/goods-G583---.html
69 I/O pins is a lot. We will need to separate the outputs to segments (“cycles”) and also have one pin per cycle to switch between them. And rely on persistence of vision; we need to have at least 50hz frame-rate (i.e. all cycles finishing in 1/50s).
Classic charlieplexing probably will not work well with PWM at all. But with just five cycle control PINs required, something simpler could work nicely:
PWM0 o-*--(LED)----. | | `--(LED)--. | (LED) is | | transistor PWM1 o-*--(LED)--+-* plus LED | | | `--(LED)--* | | | C0 o-----------|< | GND | C1 o-------------|< GND
Microcontrollers generally do not have interestingly large number of hardware PWMs, but since we will be doing little else than driving the LEDs in our software, we can simply do the PWMs in software with more than enough resolution (8-bit ideally, but 5-bit would be probably already fine). E.g. ArduinoMega2560 has 54 output PINs, so just two cycles per frame would do, with some spare time to receive pixmap updates.
Price for seeeduino mega: ~900CZK. Plus: Not much soldering required. Single board = easy debugging. Minus: Relies on POV (can flicker slightly and such). Limited time to receive pixmap updates. *Huge* amount of *very long* wires, operating at high frequencies = hard debugging. High price.
Each few pixels will be controlled by a separate microcontroller. All LEDs will be lit at once. The microcontrollers will share just a data bus (e.g. TWI).
The cheapest we can go is probably ATTiny26L, single microcontroller can operate three pixels (12 outputs). One uC would operate just two pixels = spare pins + time for serial-TWI interface.
In this case, it would be probably worth it having a PCB fabbed too.
Price for 7 microcontrollers: ~210CZK. Plus: Low price. Few wires = easy debugging. No POV reliance. Much less sensitive to pixel reprogramming interference. Minus: A lot more soldering. Many boards = hard debugging.
Like many uCs, but instead of microcontrollers with software PWM, use I2C-controlled digital-analog converters.
do it compatible with leading protocols in lighting control ..DMX and ARTnet
TODO: So how it works?