The Rusty Spike

A Railroad Fan's Website

By

Chasing Lights (74HC595 Register + TI Launchpad)

Okay ladies and gents, here’s a Chasing Light project using a single Shift Register (74HC595) and a TI Launchpad. (I’m currently following a line of research using the Shift Registers, but there is an easier way to do this with just a Launchpad alone.) It can be easily adapted for many uses. Examples include, but not limited to:

  • Theatre Signs
  • Airport Landing Strip
  • Eat At Dave’s Signs

This particular Launchpad project uses an external device called a Shift Register. Simply put, it’s a device that remembers the 1 or 0 you just put into. If you put another 1 or 0 into it, it shifts all the existing saved 1’s and 0’s over one slot and adds your newest value in. It can hold 8 values, hence the term 8-bits.

Here’s what it looks like when its all put together on a breadboard:

Chasing Lights v1.0 from claymore1977 on Vimeo.

Read More

By

TI: Yet More Free Samples

In between orders of Texas Instruments Launchpads evaluation boards from Mouser or Newark, Free Samples from TIdon’t forget that TI has a free sample program that can get you a couple free MSP430 chips of varying models. Combine the raw chips with the ability to power and run MSP430’s off the red Launchpad board, and you can have quite the small army of animation and automation circtuis deployed on your layout in no time and very low cost!

Just please remember to keep TI interested in manufacturing the MSP430 processors by actually buying a few now and then. I think that if the hobby of model railroading can provide a significant enough demand for the MSP430 line of microprocessors, then we could help keep the prices low and increase the online support for the Launchpad based chips. Currently, there far more resources for the Arduino. Some of which can be ported to the Launchpad, some cannot.

By

Pushbutton ‘Bouncing’ and How to Fix It

I recently ran across an article on the TI Wiki that does a great job explaining the strange behavior of a pushbutton when attached as an input to a Launchpad. I was getting very erratic pin HI LO readings when a pushbutton was pressed or released. I have re-posted some of the contents here on my blog for my own personal reference. The original author retains the copyright.

Bouncing occurs while a pushbutton is changing state and during the first few nanoseconds after state has stopped changing. It is a physical machine and the electrical contact is not perfect. We should not expect perfect electrical performance. Pushbutton Bouncing fixWhen controlling a light, LED, or motor directly, these bounce effects are so miniscule that they are often unnoticed. A microcontroller is extremely sensitive to electrical noise and pushbutton bounce is a bit of an issue.

Since bounce is simply unstable performance during state change, a capacitor can be used to smooth out performance. The picture shown depicts a pin (P1.3) attached to a pull up resistor and a pushbutton is used to ground the pin. Note the capacitor wired in parallel to the switch. Wired in this fashion, the capacitor acts as a ‘buffer’ to smooth out the poor electrical performance of the pushbutton.

Again, this information can be found in a bit more detail on TI’s information Wiki.

By

Basic Electricity 101: American Wire Gauge Chart

gauge Diameter Inches X-Section (in2) Diameter mm X-Section (mm2) Ohms per 1000 ft Ohms per km Maximum amps for chassis wiring Maximum amps for power transmission
OOOO 0.46 0.166196 11.684 107.222966 0.0490 0.16072 380 302
OOO 0.4096 0.131772 10.40384 85.014313 0.0618 0.20270 328 239
OO 0.3648 0.104524 9.26592 67.434449 0.0779 0.25551 283 190
0 0.3249 0.082909 8.25246 53.489874 0.0983 0.32242 245 150
1 0.2893 0.065736 7.34822 42.410073 0.1239 0.40639 211 119
2 0.2576 0.052119 6.54304 33.625122 0.1563 0.51266 181 94
3 0.2294 0.041332 5.82676 26.666068 0.197 0.64616 158 75
4 0.2043 0.032782 5.18922 21.149928 0.2485 0.81508 135 60
5 0.1819 0.025988 4.62026 16.766312 0.3133 1.02762 118 47
6 0.162 0.020613 4.1148 13.298485 0.3951 1.29593 101 37
7 0.1443 0.016355 3.66522 10.551272 0.4982 1.63410 89 30
8 0.1285 0.012969 3.2639 8.367166 0.6282 2.06050 73 24
9 0.1144 0.010279 2.90576 6.631690 0.7921 2.59809 64 19
10 0.1019 0.008156 2.58826 5.261633 0.9989 3.27639 55 15
11 0.0907 0.006461 2.30378 4.168566 1.26 4.1328 47 12
12 0.0808 0.005128 2.05232 3.308224 1.588 5.20864 41 9.3
13 0.072 0.004072 1.8288 2.626861 2.003 6.56984 35 7.4
14 0.0641 0.003227 1.62814 2.082036 2.525 8.282 32 5.9
15 0.0571 0.002561 1.45034 1.652131 3.184 10.44352 28 4.7
16 0.0508 0.002027 1.29032 1.307674 4.016 13.17248 22 3.7
17 0.0453 0.001612 1.15062 1.039845 5.064 16.60992 19 2.90
18 0.0403 0.001276 1.02362 0.822967 6.385 20.9428 16 2.3
19 0.0359 0.001012 0.91186 0.653072 8.051 26.40728 14 1.8
20 0.032 0.000804 0.8128 0.518886 10.15 33.292 11 1.5
21 0.0285 0.000638 0.7239 0.411587 12.8 41.984 9 1.2
22 0.0254 0.000507 0.64516 0.326919 16.14 52.9392 7 0.92
23 0.0226 0.000401 0.57404 0.258815 20.36 66.7808 4.7 0.729
24 0.0201 0.000317 0.51054 0.204722 25.67 84.1976 3.5 0.577
25 0.0179 0.000252 0.45466 0.162360 32.37 106.1736 2.7 0.457
26 0.0159 0.000199 0.40386 0.128105 40.81 133.8568 2.2 0.361
27 0.0142 0.000158 0.36068 0.102176 51.47 168.8216 1.70 0.288
28 0.0126 0.000125 0.32004 0.080448 64.9 212.872 1.4 0.226
29 0.0113 0.000100 0.28702 0.064704 81.83 268.4024 1.2 0.182
30 0.01 0.000079 0.254 0.050672 103.2 338.496 0.86 0.142
31 0.0089 0.000062 0.22606 0.040138 130.1 426.728 0.7 0.113
32 0.008 0.000050 0.2032 0.032430 164.1 538.248 0.53 0.091

By

Basic Electricity 101: Equation Reference

Ohms Law

OhmsLaw.png

 

I = E / R

Where E = Voltage(Volts), R = Resistance(Ω), and I = Current (Amps).

Ohm’s law can be re-written to solve for any of the parameters:

I = E / R     Solved for Current

R = E / I     Solved for Resistance

E = I * R     Solved for Voltage

 

DC Real Power

P = I * E     Used when you only have the Voltage and Current components

P = (E)2 / R     Used when you only have the Voltage and Resistance components

P = I2 * R     Used when you only have the Resistance and Current components