DCC-MB Throttles


SCHEMATIC DIAGRAM

Description

The schematic diagram shows a basic throttle, consisting of one potentiometer and one momentary normally-open pushbutton switch. The actions performed by these controls is determined entirely by the software, and can thus change in different contexts. For example, in normal operation I plan to use the potentiometer for speed control (nicer than increment/decrement buttons), and the switch will perform double-duty: When the train is moving, the switch will be an emergency brake; when the train is stopped, the switch will reverse the train's direction.

Important note about joystick cards
Some joystick cards only support one joystick (equivalent of two throttles.) You can probably find inexpensive dual joystick (four throttle) cards - check the ads in magazines such as Computer Shopper.

What size potentiometer should I use?
The joystick port measures the potentiometer's resistance by inserting it into a timing circuit, and then measuring the time for the circuit to respond. This measurement is made by the DCC_MB.COM software driver*, and results will vary depending on the speed of your computer. Furthermore, the values measured by the driver are limited to the range of 0 to 255, so there is a maximum resistance (which will also depend on the computer's speed) that can be measured.

To determine the size of your potentiometers, run the throttle test program, which displays the measured values for all four throttles. Experiment with different potentiometers until these two conditions are met:
The difference between minimum and maximum readings is at least 128
The maximum reading is less than 250

Faster computers need larger potentiometers. These values work for me: 10K for my 10MHz XT, 100K for my 25MHz 386.

* Note: Most 286-or-better computers include a BIOS routine to measure joystick values (function 84h of interrupt 15h). This routine returns 16-bit values, so potentiometer size is less important - 100K should work for most computers.

How about walk-around throttles?
This is not tested yet, but it is possible that the 10 wires from the joystick port (see diagram above) can be run as a bus around a layout. IF the port can work properly with this length of wire, then the software can determine when a throttle is disconnected (its value will be 255). It would then be trivial to make the software hold the respective speed constant until the throttle is reconnected at a different point.


Back to DCC-MB Home Page
Copyright (c) 1996 Michael Brandt / mobrandt@mailbox.syr.edu