• Blog
  • Parts Sources
  • Form Test
VccGnd

Designing 7-segment symbols with a Text Editor

7/27/2012

0 Comments

 
7-segment LED symbols may be quickly designed with a Text Editor using the characters ' ' (space), '|' (vertical bar, the bitwise OR operator in C), and '_' (underscore).  On the first line we use one underscore (preceded by a space) for segment A.  One the 2nd line we use one vertical bar, one underscore, and another vertical bar for segments F, G, and B, respectively.  On the 3rd line we once again have one vertical bar, one underscore, and another vertical bar, but this time for segments E, D, and C, respectively.  We then replace segments that should be disabled with the space character.

Here we have all segments A-G enabled:
 _
|_|
|_|

Some numbers:
    _  _   
  | _| _||_|
  ||_  _|  |

and some letters:
    _     _ 
|_|| ||  |_|
| ||_||_ | |

It works well if you're only interested in a limited number of symbols.
0 Comments

Overview: 7-segment LEDs

7/23/2012

1 Comment

 
I'm adding a series of "Overviews" for readers who may not be coming from a hardware background.

What's the big deal with 7-segment LED displays?  Well, it's not a big deal, but it's not completely trivial either.

Suppose you have a single-digit 7-segment LED display.  One digit can display 0-9 decimal, or 0x0 to 0xF hexadecimal.  Suppose you are only interested in displaying 0 or 1.  The interface is not a single input pin that you set to either GND for 0 or VCC for 1, with all other pins set to GND.  Instead, 7-segment displays have an interface as follows:
Picture
There are 7 input pins, named A-G, each of which controls one segment.  There is usually also a pin controlling the decimal point, typically named DP, but we'll ignore this for simplicity.  To display a 0, you'll need to enable pins A,B,C,D,E,F, but disable pin G.  To display a 1, you'll need to enable pins B and C while disabling all other pins.  There's some logic or lookup involved.  It gets more involved as you expand your display capability from 0..1 to 0..9 or 0x0..0xF.

For four digit 7-segment LED displays, the A-G pins (and DP as well) are shared among the four digits, and 4 more pins indicate which digit the current A-G pins' values should be "sent to."  It's simpler, if at any given time, only one of the four digit selection pins is enabled, with 3 disabled.  You'd have to rotate among the four (like software concept of "round robin") pins.  Now there is not just logic or lookup but state as well.  Furthermore, these 4 "selector-pins" with shared A-G configuration can be in the form of "common anode" or "common cathode."  More details at Wikipedia.
1 Comment

MSP430 and TI LaunchPad

7/23/2012

2 Comments

 
In my previous post, I used the MSP430 LaunchPad Value Line Development kit.

The MSP430 is a 16-bit microcontroller from Texas Instruments.  Code Composer, a C Compiler and Eclipse-based IDE is available from TI; the code-size limited version is free.

The development board is available for as low as $4.30 from TI.  At this very moment, it looks to be out of stock at TI, but it is also available from DigiKey or Mouser.

Nice way to experiment with microcontrollers without breaking the bank!
2 Comments

Blinking LED and "Hello, World"

7/20/2012

2 Comments

 
In the software world, it's customary to write a program that prints out "Hello, World" when trying out a new language.  With microcontrollers, the rough equivalent seems to be a blinking LED, as many development boards come with such a sample app.

As a warm-up exercise to getting back into hardware, I thought I'd combine these two ideas, and have a 4-digit 7-segment LED blink "Hola" (conveniently 4 characters long).

Hola by VccGnd
For now, there is some visible flickering.  The 'A' in "Hola" is also partially hidden due to messy wiring.

Parts:
  1. TI Launchpad MSP430 Development Board
  2. 4-digit LED
  3. Small Breadboard
  4. Ribbon cable with female ends
  5. 3-pin cable (2 wires used for Vcc/Gnd, 1 unused)
  6. Male headers
2 Comments

Shopaholic, and PARTS SOURCES link in upper-right corner

7/17/2012

0 Comments

 
I've always appreciated the wide availability of logic analyzers (2:1 student-to-instrument ratio) in the 6.111 Lab.  I also really liked that we used PALs, which I told my friends was God's gift to humanity.  What I had failed to realize until recently though was how useful it was that the "Nerd-kit" had a box of parts in the bottom, and that there was a parts supply counter next to the lab.  Just about every part I needed was in that box.  For special parts, I could walk to the parts counter and ask the Lab Tech for the special part.

Recently, as I tried to design circuits, the process would inevitably morph itself into a shopping exercise.  I'd be missing this or that IC, this or that resistor, this or that tool, etc. and end up shopping (which tires me out!) for parts instead of designing circuits.  If I find the part, I'd then have to order it and wait for it to arrive.  I'd usually try to order a few other parts I anticipate I'd need in the future in order to amortize shipping costs.  Not quite like software, where if you can find some Open Source (preferably public domain or Apache / BSD / MIT Licensed, and not GPL) code you need, you just download it and start using it almost immediately.  If you can't find such code, just fire up the IDE and start writing it yourself.

After spending a big chunk of time upfront shopping for parts and tools, I think my home mini-lab is now sufficiently stocked that I can focus on building circuits.  Next post should be about real circuits.

For readers' convenience, I've set up a page called PARTS SOURCES, with a link in the upper-right corner of this blog.  At the moment it's just a list of links, but I'll try to add some notes on each supplier over time.
0 Comments

Welcome

7/15/2012

0 Comments

 
20+ years have passed since I last used a logic analyzer and wrote ABEL code to program PALs, but I'm playing with hardware again.  As a software developer, I will tend to approach hardware with a software twist ("To a hammer, everything looks like a nail").  I shall blog here about my adventure...
0 Comments

    VccGnd

    Hardware with a software twist.

    Archives

    February 2014
    January 2014
    September 2012
    August 2012
    July 2012

    Categories

    All
    7LED
    Android
    Ascii
    Crystal Free USB
    Crystal-Free USB
    Dev Boards
    MSP430
    Overviews
    PCB
    PIC8
    Sourcing

    RSS Feed

Powered by Create your own unique website with customizable templates.