Led Matrix: Unterschied zwischen den Versionen

aus Metalab Wiki, dem offenen Zentrum für meta-disziplinäre Magier und technisch-kreative Enthusiasten.
Zur Navigation springenZur Suche springen
K (+kat.)
 
(27 dazwischenliegende Versionen von 9 Benutzern werden nicht angezeigt)
Zeile 1: Zeile 1:
For the LED Matrix we want to build on the [[CCCamp2007]] we decided to design a GNU LEDMatrix Controller/Driver setup. It will consist of two parts the FPGA board and a several driver electronics boards.
+
=== WTF? ===
 +
 
 +
[[Bild:Matrix_frontside.jpeg|thumb|200px|hypnomatrix is hypnotizing]]
 +
[[Bild:Matrix_backside.jpeg|thumb|200px|all hail to the hypnomatrix]]
 +
 
 +
For the LED Matrix we wanted to build on the [[CCCamp2007]] we decided to design a GNU LEDMatrix Controller/Driver setup. It consists of two parts the FPGA board and a several driver electronics boards. Now almost one year later we're finally done!
 +
 
 +
''see also:'' [http://www.flickr.com/photos/1000points/2509802438/ metalab led matrix - demo "die ewigkeit schmerzt"](Video)
 +
 
 +
== Animations ==
 +
 
 +
Two Animations for the linuxwochen: [[Bild:Metalabanim.zip]]
 +
 
 +
 
 +
<div>
 +
<div style='float:left'>{{#ev:youtube|pHdAvMrkO0U}}</div>
 +
</div>
 +
<div style='clear:both'></div>
  
 
== Status ==
 
== Status ==
We have all the chips we need to build a first 8x8 driver board in the lab
+
Everything is soldered and it works. We can stream videos via the parallel interface of the via board to the matrix with 72fps :)
* TC446X
+
 
* shifting registers
+
* main svn: https://whatever.metalab.at/projects/FPGAMatrix/
* power Mosfets
+
* cliffords mplayer patch: http://svn.clifford.at/handicraft/2008/metaleds/
* altera fpga
+
 
 +
== Usage examples ==
 +
clifford/mplayer/mplayer-bin -vo metaleds:/dev/lp0 -framedrop -vf scale -zoom -x 72 -y 48 test.avi
 +
netcat -l -p 7000 > /dev/lp0
 +
 
 +
 
 +
 
 +
Format is: 72x48 bytes of pixeldata (ranging from 0x00 to 0x0F) followed by a single 0x80 (to flip framebuffers)
 +
 
 +
 
 +
== Real-time access ==
 +
 
 +
=== Raw protocol ===
 +
 
 +
72x48 = 3456 octets of pixel data followed by a terminating 0x80 octet.
 +
 
 +
Each pixel data octet represents one pixel's brightness, ranging from 0 (0x00, off) to 15 (0x0F, brightest).
 +
 
 +
The pixels start at the upper left corner and are numbered in [http://en.wikipedia.org/wiki/Row-major_order row-major order] (see the diagram below).
 +
 
 +
All output is double-buffered on the fpga, so you have to send a 0x80 after the pixel data to flip the frame buffers.
 +
<pre>
 +
________________________
 +
| 1  2  3 ...          72|
 +
|73 50 ...            144| 
 +
|.                      |
 +
|.                      |
 +
|...                3456|
 +
|________________________|
 +
</pre>
 +
 
 +
=== Using with C/C++ ===
 +
You can use the metalib library from here; it comes with a couple of demos:
 +
 
 +
https://whatever.metalab.at/projects/FPGAMatrix/client/
  
== LED Matrix Driver Boards ==
+
=== Using with Python ===
Our Matrix should have a resolution of 48x72 pixels. So there will be 48 rows and 72 columns. The basic building block of our ledmatrix will consist of an 8x8 pixel module (or 8x48 or 8x76 depending on the levels of grayscale steps you want).
+
You can use functions like getpixel, setpixel, submit with the python classes in https://whatever.metalab.at/projects/FPGAMatrix/python/
  
for our matrix we need 6x9 = 54 modules.
+
It supports the (now encouraged) way of using TCP. A example (Game of Life) is available.
  
So how is such  basic building block connected? The cathode (GND) pins of all LEDs in each of the 8 rows are connected to each other. Also all the annode (+) pins of all lesds in each column are connected. Sowe get 8 rows and 8 columns. each column intersects each row and the intersections are the leds. To lighten up one specific led we have to set the row the led is connected to to GND and the column to +5V (we also need a resistor to limit the current). TODO: das besser erklaeren rasteransteuerung etc.
+
== Specs ==
 +
72x48 pixels totals 3456 blue leds
 +
54 column driver modules (current source).
 +
1 row driver mudule (current sink)
  
 
The 8 rows are each connected to a powermosfet and are driven to ground one at a time (so the matrix is 8times multiplexed).
 
The 8 rows are each connected to a powermosfet and are driven to ground one at a time (so the matrix is 8times multiplexed).
For driving the mosfets we use 2x Quad-mosfetdriver which in turn are controlled by a 8bit shifting register.
+
For driving the mosfets we use two Quad-mosfetdriver which in turn are controlled by a 8bit shifting register.
  
For the columns we take almost the same components except that we don|t need the mosfets. the mosfet drivers (which consists of mosfets of course - in fact its a half bridge and so contains one pMOS and one nMOS FET) are strong enough to drive a high current led with a constant current of 0.5A and peak currents of 1.5A
+
For the columns we take almost the same components except that we have to source current. The mosfets can source up to 250mA but we limit it to about 20mA.
  
=== partlist ===
+
=== Used ICs ===
* link to spreadsheet (viewing only): http://spreadsheets.google.com/pub?key=pZBTqi6Tn2l3eL8mkHINYJQ&output=html&gid=0&single=true&widget=true
+
* [http://www.onsemi.com/PowerSolutions/product.do?id=NID5001N NID5001N] MOSFETS for the row driver
* link to spreadsheet(for editing): http://spreadsheets.google.com/ccc?key=pZBTqi6Tn2l3eL8mkHINYJQ&hl=en
+
* [http://www.microchip.com/stellent/idcplg?IdcService=SS_GET_PAGE&nodeId=1335&dDocName=en010678 TC4467] used as column driver
<websiteFrame>
+
* 74HC595 shifting registers
website=http://tinyurl.com/yuo36a
+
== New MiniITX Board ==
<!-- website=http://spreadsheets.google.com/pub?key=pZBTqi6Tn2l3eL8mkHINYJQ&output=html&gid=0&single=true&widget=true -->
+
VIA EPIA-M 1000G
height=300
 
width=800
 
</websiteFrame>
 
  
==== chips that might be usefull for a LED matrix in general ====
+
1 Ghz
* Texas Instruments
+
1 Gig RAM
** [http://focus.ti.com/docs/prod/folders/print/tpic6595.html TPIC6595] 8-Bit Power shifting register (250mA continious current per channel)
+
MPEG2 Decoderchipset
** [http://focus.ti.com/paramsearch/docs/parametricsearch.tsp?family=analog&familyId=356&uiTemplateId=NODE_STRY_PGE_T TPIC6C595, TPIC6B595, TPIC6A596] all simmilar to the above, ALL switch to ground
 
** [http://focus.ti.com/docs/prod/folders/print/tps1120.html TPS1120] Dual P-channel Enhancemenent-Mode MOSFET
 
* On Semi
 
** [http://www.onsemi.com/PowerSolutions/parametrics.do?id=836 Zero Delay Buffers] for distributing the clocks, data and latch to all the shifting registers in the rows (they all receive the same signal)
 
** [http://www.onsemi.com/PowerSolutions/parametrics.do?id=809 MOSFETs] I think we|ll use one of thes for the rows
 
** [http://www.onsemi.com/PowerSolutions/parametrics.do?id=557 Shifting Registers] cheap :)
 
  
== FPGA LED Matrix Controller ==
 
an FPGA producing the correct signals to drive the above driver module, or drive many modules in paralell :)  for each module we need 3pins
 
  
 
[[Kategorie:WhateverLab]]
 
[[Kategorie:WhateverLab]]
 
[[Kategorie:Projekte]]
 
[[Kategorie:Projekte]]

Aktuelle Version vom 19. April 2009, 22:12 Uhr

WTF?

hypnomatrix is hypnotizing
all hail to the hypnomatrix

For the LED Matrix we wanted to build on the CCCamp2007 we decided to design a GNU LEDMatrix Controller/Driver setup. It consists of two parts the FPGA board and a several driver electronics boards. Now almost one year later we're finally done!

see also: metalab led matrix - demo "die ewigkeit schmerzt"(Video)

Animations

Two Animations for the linuxwochen: Datei:Metalabanim.zip


Status

Everything is soldered and it works. We can stream videos via the parallel interface of the via board to the matrix with 72fps :)

Usage examples

clifford/mplayer/mplayer-bin -vo metaleds:/dev/lp0 -framedrop -vf scale -zoom -x 72 -y 48 test.avi
netcat -l -p 7000 > /dev/lp0


Format is: 72x48 bytes of pixeldata (ranging from 0x00 to 0x0F) followed by a single 0x80 (to flip framebuffers)


Real-time access

Raw protocol

72x48 = 3456 octets of pixel data followed by a terminating 0x80 octet.

Each pixel data octet represents one pixel's brightness, ranging from 0 (0x00, off) to 15 (0x0F, brightest).

The pixels start at the upper left corner and are numbered in row-major order (see the diagram below).

All output is double-buffered on the fpga, so you have to send a 0x80 after the pixel data to flip the frame buffers.

 ________________________
| 1  2  3 ...          72|
|73 50 ...            144|  
|.                       |
|.                       |
|...                 3456|
|________________________|

Using with C/C++

You can use the metalib library from here; it comes with a couple of demos:

https://whatever.metalab.at/projects/FPGAMatrix/client/

Using with Python

You can use functions like getpixel, setpixel, submit with the python classes in https://whatever.metalab.at/projects/FPGAMatrix/python/

It supports the (now encouraged) way of using TCP. A example (Game of Life) is available.

Specs

72x48 pixels totals 3456 blue leds 54 column driver modules (current source). 1 row driver mudule (current sink)

The 8 rows are each connected to a powermosfet and are driven to ground one at a time (so the matrix is 8times multiplexed). For driving the mosfets we use two Quad-mosfetdriver which in turn are controlled by a 8bit shifting register.

For the columns we take almost the same components except that we have to source current. The mosfets can source up to 250mA but we limit it to about 20mA.

Used ICs

  • NID5001N MOSFETS for the row driver
  • TC4467 used as column driver
  • 74HC595 shifting registers

New MiniITX Board

VIA EPIA-M 1000G

1 Ghz 1 Gig RAM MPEG2 Decoderchipset