I have managed to build this "PENTA" device. What is it?
PENTA is a Five Letter Word. Currently it only speaks Italian. I could not get anywhere near to what our Ray Weisling did with his piece of art, the original FLW (Four Letter Word).
(I have finally assembled the FLW kit. FLW and PENTA now face each other on a shelf, uttering their words, one english one italian. They seem to get along pretty well together).
I chose to adopt the 5 letter design for several reasons:
- main challenge was to drive, in a multiplexed way, as many Varisymbol alphanumeric displays (Telefunken ZM1350, Ask Jan first!) as I could, using "only" a PIC16F628. The word-display feature was added because alphanumeric displays should also show... alphabetic symbols, after all!
- there are more interesting five than four letter words in italian
- the most (in)famous "four letter words" are five-letter-words in italian...
The schematics is available here:
The Microcontroller Unit (MCU) and the Display-Driving-Unit
Here is a picture of the prototype board.
Credit goes to several people, mostly members of the Yahoo group NEONIXIE-L, for many interesting solutions that have been implemented in this design. There are comments on this in the .asm file. For those interested in the code, I would like to make it available.
I would appreciate your comments on this design, and, if anyone will ever build one, on how it works.
The code is almost entirely original, except for Gary Blead's basic idea of the 50 Hz/interrupt driven clock routine. Time is in the format hh:mm.
Two underscores (possible with the ZM1350) blink with seconds below the units-of-hour and tens-of-minutes digits. Since the time requires 4 digits and PENTA has five, time visualization toggles between left-aligned and right-aligned (all digits are thus kept in use). Time can be adjusted, when it is shown, by using the minutes and hours switches.
The word bank is stored in a 24C512 (65536 bytes) serial I2C EEPROM.
The italian word bank was generated using a very nice free program called VERBATRON, written by Giovanni Resta (www.imc.pi.cnr.it/~resta/) to whom goes my credit. The program can be used to generate word banks in other languages.
Words are chosen randomly from the bank and displayed for a few seconds.
Current time shows up for some twenty seconds, then another random five-letter word.
Word choice has nothing to do with the complex system of Ray's FLW. It is not based on linguistic schemes or rules for generating meaningful words, nor it makes use of compression routines. Words are plainly stored in the EEPROM and only picked up at random from the bank via standard I2C read routines.
A random number is needed to get a word from a preset word bank. Randomness is obtained with a hardware random number
generator (see schematics), for which I credit: Aaron Logue
Some testing of randomness was carried out using a test board that sends random bytes via RS232 to a PC. Random files tested OK with the program ENT from: www.fourmilab.ch (John Walker).
The degree of indeterminacy in the choice of the word is apparently high, but more tests are in progress after the HRNG unit was enclosed in the PENTA device.
ASCII characters can be sent to the unit, which will display them for a few seconds, then it will go back to the standard cycle "clock/5LW".
Characters received after the fifth will make previously received text scroll to the left. As the leftmost character is pushed out, it is sent via RS232, making it possible for another PENTA unit to pick it up and display it. Many untis can be "daisy-chained" to display longer messages. This is the set of characters that can be displayed.
If a "carriage return" is sent, the display is "freezed" until another character is received. To exit this mode quickly, send an "ESC" character.
"Carriage return" and "Escape" characters are sent to RS232 as received, thus other units will receive them as well. RS232 format is 9600 baud no parity, 2 stop bits.
Multiplexing is obtained with only 3 4094 (8 bit shift registers). Two of them are wired to 16 cathode-driving MPSA42. The other 4094 drives the
anodes, it could handle up to 8 digits but here it drives 5.
A total of 21 MPSA42 and 5 MPSA92 is needed, together with the proper number of resistors.
The trade-off for the reduction in the number of components is in the increase in software complexity, but not much, after all.
What is original in this design, as far as I know, is the way data are sent serially to the Display Driving Unit (DDU, see sheet 2) to multiplex the 5 nixie alphanumeric displays.
There is one 4094 8 bit shift register (U1) that accepts data concerning which of the 5 displays should be turned on, by applying high voltage to its anode. Here only 5 bits are needed.
There are two 4094 8 bit shift registers (U2, U3) that receive a total of 16 bits coding for the segments to be turned on, by pulling the corresponding cathodes to ground through the proper cathode-associated drivers.
The DATA line of the "anode section" 4094 and the DATA line of the first 4094 of the "cathode section" are connected together and to RA0.
By software, a stream of 16 bits coding for the character to be displayed (for the segments to be turned on) on the first digit, is sent by the PIC to the DATA line, properly clocked on the CLOCK line (which is common to all 4094's).
The 16 bits will shift into U2 and U3 and align properly. They will also shift into U1 however, U1 will not store the cathode bits because a STROBE-CATHODES signal will only be applied to the strobe lines of U2 and U3 connected in parallel and to RA1.
Immediately after this, a 8 bit stream is sent, carrying the information on which display has to be turned ON, suppose leftmost digit. This stream of bits will end up in U1, and also in U2, but they will only be strobed into U1 because a pulse is applied to the STROBE-ANODES line, which is only connected to U1 and to RA2.
The sequence for each digit is:
send 16 cathode bits, then a strobe-cathodes pulse
send 8 anode bits, then a strobe anode pulse
delay for the ON state
send 8 anode bits, all zero, then a strobe anode
delay for the OFF state
start all over again for next digit.
In the ON and OFF delay routines are enclosed the routines for all other functions, mostly based on polling.
Underneath all this a call to the interrupt service routine is generated every second, to update the clock.
Display is refreshed at approx 90 Hz rate. During the entire cycle of 5 digits a given digit is ON for approx 15.7% of the time. This is for the BRIGHT state. In the DIM state, a digit is on for 3.6% of the time.
In the current code version (v. 1.40) display is bright from 8:00 to 20:59, and dim from 21:00 to 7:59 (obviously, this preset can be changed in the code).
At startup, the word PENTA is displayed, then the current time, then a five letter word. The way the five letter word shows up has 3 different modes:
|Mode 1 (default at startup): no hangman mode, direct visualization.|
Mode 2: "fast stick-hangman", the segments destined to compose the
current word are turned on in a relatively rapid but smooth sequence.
The lighting order for segments is random, and changes from word to word.
(This is the mode I prefer).
Mode 3: "true" stick-hangman. Same as Mode 2, except that it takes several
seconds for the word to complete. You can play hangman and guess the word.
How to change mode? MODE cycles when the MODE switch is depressed at a transition
between time visualization and five-letter-word visualization.
Less than 70% of the program memory area is used in the current version. There is still room for implementing other functions.
No external crystal required, it uses the internal 4MHz clock, that never failed in properly timing the USART (tested with Windows' Hyperteminal).
This compressed archive contains three files:
The source code, version 1.40
An alphabetic list of 3185 five-letter words (italian) (it only works with version 1.40)
The assembled hex file.
There is also a compressed archive for the 60 Hz version (v. 1.40C).