Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
numitron_tubes [2012/09/21 13:06]
127.0.0.1 external edit
numitron_tubes [2018/03/06 08:59] (current)
Line 1: Line 1:
 +~~NOTOC~~
  
 +====== Numitron Tubes ======
 +
 +We consider this one of our most important projects, mostly because it's so badly documented. In order to do this, we grabbed bits and pieces from all over the web, and mashed them together into the semblance of a project. I guess I should explain what numitron tubes actually //are//, since I see I haven'​t said anything on the subject. [[http://​en.wikipedia.org/​wiki/​Seven-segment_display#​Implementations | Numitron Tubes]] (as seen below) are old (~70s) vacuum incandescent 7-segment display tubes. They are beautiful little displays, all glass and messy wires, with the incandescence adding a very steampunk feel to them. Anyways.
 +
 +{{numitron1.jpg?​500 }}
 +
 + We are going to give you all of the shortcuts, so you won't actually //have// to learn any coding, but if you don't you suck. Everything taken from this project can be taken and applied to something else. Wiring the tubes will be difficult, so pay attention to that section. Enough blabbing, here we go. Here's a picture and a video for inspiration. There are two main aspects to this project: code and wiring.
 +
 +
 +===== Aquiring The Essentials ​ =====
 +
 +{{ youtube>​rbdZhKMbBP4?​medium}}
 +
 +  * [[http://​www.ebay.com/​itm/​ws/​eBayISAPI.dll?​ViewItem&​item=290572158172&​ssPageName=ADME:​L:​OC:​US:​1123 | The Tubes Themselves]] : these are hard to come by, and there are many sales on ebay that appear to be numitron tubes, but are actually VFD tubes instead, which is a whole '​nother ballpark, as they say.
 +  * [[http://​processors.wiki.ti.com/​index.php/​Download_CCS | CCS]] : Download the newest offline version. If you have not registered already for purchase of the MSP 430 and the Launchpad, you'll have to for this. Why the super crazy security? In case terrorists use the chip to guide missiles, //​obviously//​. Just answer "​student"​ for most things, and you should be fine.
 +  * [[https://​estore.ti.com/​MSP-EXP430G2-MSP430-LaunchPad-Value-Line-Development-kit-P2031.aspx | MSP 430 & Launchpad]] : an absolutely wonderful deal from TI. Especially amazing if you compare it to other boards, such as the Arduino.
 +  * Breadboard : Radioshack typically has some, pricey though.
 +  * Wire : 22 gauge.
 +  * Wire Strippers : good ones, you'll use these plus the wire to make jumpers, unless you want to buy your own.
 +  * Everything from the [[general electronics]] page (This page doesn'​t actually exist yet, but for the time being: assorted capacitors, resistors, diodes, a multimeter, and the like.)
 +
 +===== Starting your First CCS Project =====
 +
 +Very easy, but if you screw up (which you probably will), the MSP won't work and you won't be able to figure out why and your code seems right and nothing works and agghhahg. But that's just you, we were fine.
 +
 +  - Install CCS
 +    - make sure you select the MSP stuff in all of the menus. You want the USB interface, not the serial. Do not choose the free version when it asks for license, choose the limited MSP version. Workspace is unimportant,​ just be consistent.
 +  - Start CCS
 +  - Project > New Project
 +  - Name your project, ex: Numitron
 +  - Leave everything default except for the Device section.
 +    * Family: MSP430
 +    * Variant: we use the MSP430G2553,​ but yours might be different. Look at the top of the chip.
 +    * Connection: USB1
 +  - Done
 +
 +
 +
 +===== Wiring =====
 +
 +First of all, you might want the [[http://​www.ti.com/​lit/​ds/​symlink/​msp430g2553.pdf | datasheet]] for the MSP430g2553. That is the exact model we used, so if you are using it there won't be any problems. Any others, however, you will likely have to modify the code and possible the wiring to make it work. 
 +
 +Each number below corresponds to a certain pin output on the MSP, as seen in the table below. For the initial part of the numitron project, we are going to drive one numitron directly from the MSP. It is possible to drive two through transistors,​ but that will be covered later.
 +
 +<box 30% left | Pin Layout> {{dia3.png?​200 ​ }} </​box>​
 +
 +Your numitron might have different leads, different nc (not connected) leads, and a whole slew of other differences. If that is the case, use this diagram to find out how yours should be wired. ​
 +
 +<box 20% right | Elements>​ {{dia2.png?​125 ​ }} </​box>​
 +
 +  - Find your common ground (CG) : this will be the pin that goes to the baseplate (generally from the front).
 +  - Connect common ground to ground, and insert the rest of the pins in the breadboard. Have an input voltage of around 3V, either from USB via the Launchpad, or from a DC adaptor, with some voltage regulators thrown in (see Wiring, below). ​
 +  - Test each of the leads independently,​ using a jumper to touch each of the leads with the 3V. They should light up.
 +
 +^Numitron # ^MSP Pin ^ 
 +| 0         | P1.0   |
 +| 1         | P1.1   |
 +| 2         | P1.2   |
 +| 3         | P1.3   |
 +| 4         | P1.4   ​| ​
 +| 5         | P1.5   |
 +| 6         | P1.6   |
 +| CG        | GND    |
 +
 +Use this table to connect pins on the MSP to the numitron.
 +
 +===== Coding =====
 +
 +Assuming you got the wiring correct, and you have the MSP 430g2553, this simple counting code should work. 
 + 
 +<file c main.c>
 +// Copyright 2012 Matthew Hiles
 +#include <​msp430g2553.h>​
 +#define pause for (i=0; i < 100; i++) wait(10000)
 +
 +
 +void wait(int ticks)
 +{
 +        TAR=0;
 +        while(TAR < ticks) _NOP();
 +}
 +
 +void main(void)
 +{
 +        int i = 0;
 +        WDTCTL = WDTPW + WDTHOLD; // stop watchdog
 +
 +        TACTL = TASSEL_2 | MC_2;
 +
 +        // setup TXD and RXD
 +        P1SEL =  0;   // all ports GPIO
 +        P1DIR = 0xFF; // all is output
 +
 +        while(1)
 +        {
 +                // display a 0
 +                P1OUT = (BIT0 + BIT1 + BIT2 + BIT3 + BIT5 + BIT6);
 +                pause;
 +
 +                // display 1
 +                P1OUT = (BIT0 + BIT1);
 +                pause;
 +
 +                // display 2
 +                P1OUT = (BIT0 + BIT2 + BIT4 + BIT5  + BIT6);
 +                pause;
 +
 +                // display 3
 +                P1OUT = (BIT0 + BIT1 + BIT2 + BIT4 + BIT5);
 +                pause;
 +
 +                // display 4
 +                P1OUT = (BIT0 + BIT1 + BIT3 + BIT4);
 +                pause;
 +
 +                //display 5
 +                P1OUT = (BIT1 + BIT2 + BIT3 + BIT4 + BIT5);
 +                pause;
 +
 +                //display 6
 +                P1OUT = (BIT1 + BIT2 + BIT3 + BIT4 + BIT5 + BIT6);
 +                pause;
 +
 +                //display 7
 +                P1OUT = (BIT0 + BIT1 + BIT2);
 +                pause;
 +
 +                //display 8
 +                P1OUT = 0xFF;
 +                pause;
 +
 +                //display 9
 +                P1OUT = 0xFF - BIT6;
 +                pause;
 +        }
 +}
 +</​file>​
numitron_tubes.txt ยท Last modified: 2018/03/06 08:59 (external edit)
Driven by DokuWiki Recent changes RSS feed Valid CSS Valid XHTML 1.0