Difference between revisions of "DX TM1638 Display"

From Tech
Jump to navigationJump to search
Line 1: Line 1:
  +
=Documents=
  +
* [http://dl.dropboxusercontent.com/u/8663580/TM1638en.pdf Datasheet]
  +
* DX order page
  +
  +
=Hamsterworks code=
 
I'm using the [http://hamsterworks.co.nz/mediawiki/index.php/Dx_display VHDL code from Hamster] on my papilio board, and it works. Thanks Hamsterworks!
 
I'm using the [http://hamsterworks.co.nz/mediawiki/index.php/Dx_display VHDL code from Hamster] on my papilio board, and it works. Thanks Hamsterworks!
   
Line 30: Line 35:
   
 
But other than that, Hamsters code works.
 
But other than that, Hamsters code works.
  +
  +
=== Commands ===
  +
{| border=1
  +
! bits !! Description
  +
|-
  +
| 010000000 || write data to display register, auto increment
  +
|-
  +
| 010000010 || read data from key scans, auto increment
  +
|-
  +
| 010000100 || write data to display register, single address
  +
|-
  +
| 010000010 || read data from key scans, single address
  +
|-
  +
| 1100aaaa dddddddd || At address aaaa write dddddddd - multiple bytes of data can be transferred
  +
|-
  +
| 1000abbb || Display control - a = active, bbb = brightness
  +
|}
  +
   
 
=See Also=
 
=See Also=

Revision as of 21:09, 26 April 2013

Documents

Hamsterworks code

I'm using the VHDL code from Hamster on my papilio board, and it works. Thanks Hamsterworks!

Looks like the pinning of the DX display cable as described by Hamster has changed (or was wrong). The silkscreen on my (ordered october 2011) DX display looks like this (this is the 'bottom view', the pins of the socket as seen from above are the mirror-image of this):

Gnd Vcc
DIO CLK
STB1 STB0
STB3 STB2
STB5 STB4

So it looks like hamster's pinning has DIO/Data and CLK swapped, and the even Strobes were off by 2. Also, it's Strobe0 that controls this board (not Strobe1), the other strobes pass through to the 'out' connector.

I notice that after I power cycle (powered by USB cable) my papilio board (and the TM1638), I have to send the .bit file several times to the board. Strange.

  • When setting d_clock to 32MHz/8/2, it always works the first time.
  • Setting d_clock to 32MHz/4/2, it will not work at all

I'm using this constraints.ucf file for my papilio board:

# Crystal Clock - use 32MHz onboard oscillator
NET "clk" LOC = "P89" | IOSTANDARD = LVCMOS25 | PERIOD = 31.25ns ;

NET "d_data"   LOC = "P86" | IOSTANDARD=LVCMOS33; 
NET "d_clk"    LOC = "P85" | IOSTANDARD=LVCMOS33; 
NET "d_strobe" LOC = "P84" | IOSTANDARD=LVCMOS33; 

But other than that, Hamsters code works.

Commands

bits Description
010000000 write data to display register, auto increment
010000010 read data from key scans, auto increment
010000100 write data to display register, single address
010000010 read data from key scans, single address
1100aaaa dddddddd At address aaaa write dddddddd - multiple bytes of data can be transferred
1000abbb Display control - a = active, bbb = brightness


See Also