This article contains some reference data relevant to the holiday electronics projects.
Our microcontroller is the Atmel ATtiny2313; you can find the details on Atmel’s site.
This is a simplified drawing of the microcontroller pinouts, showing the pins as they are configured for the two holiday electronics project. All of the lines shown, except power, ground, and reset, are configured as general purpose outputs, and are capable of sourcing plenty of current to drive LEDs.
For the menorah, the external configuration of the nine LEDs is particularly simple: The cathodes of the nine LEDs connect to pins 2-10, and the anodes to pins 11-19. Be aware that the LED in the middle acts like the “lighter” candle.
The alphanumeric LED display that we are using for the micro-readerboard ornament is the Kingbright PSA08-11HWA. You can find the detailed datasheet for the display here. I’ve excerpted the most important part, which is how the pins map to the segments of the display:
In our assembled ornament, the microcontroller sits on the back side of the LED display such that most of the ATtiny2313 output pins go to inputs of the LED display. The microcontroller has 20 pins while the display only has 18, so microcontroller pins 1 and 20 do not directly line up with any pins on the display.
Pin 2 of the ATtiny2313 goes to pin 18 of the display,
pin 11 of the ATtiny2313 goes to pin 9 of the display,
and pin 19 of the ATtiny2313 goes to pin 1 of the display.
For each letter that might be displayed on the ornament, we determined which segments should be lit up. Those segments to be lit are marked by a binary #1, and those to be dark are marked with a binary #0. The sixteen binary digits that determine the state of the sixteen segments comprise two bytes worth of data, the order of the bits in the two bytes is determined by the physical location of the pins on the microcontroller and the pins on the LED display. For example, segment ‘a’ of the display is controlled by pin 1 of the display. Pin 1 of the display touches pin 19 of the microcontroller, which is output B7. Following similar logic, the format of the two bytes is as follows:
|Byte High||Byte Low|
With this definition of the two data bytes, it was possible to construct the data table, with its 16-bit binary representation of each letter. The decimal value (unsigned integer) corresponding to the binary number is also given; these are the ‘practical’ values that were used in the C code.
Note that since the PSA08-11HWA is a common-anode device, its pins are actually driven by negative logic: a logical ‘0’ on a given pin of the display turns on one of the segments. The data table with its binary and decimal digits is entirely in “positive” logic (which is generally easier to work with), so a bitwise NOT is applied to each output data byte that goes to the outputs. If you code a version of the ornament (or something else) that uses the common-cathode version of this display (the PSC08 series), you should be able to adapt to it by removing the bitwise NOT from the existing code.
|Character||ASCII #d||Segments Lit||Byte High||Byte Low||Decimal Val.|
3 thoughts on “Holiday Electronics Projects: Technical details and Reference data”
Is this possible?
My dad and I want emsl menorahs we can wear as lapel pins!
[sorry an additional extraneous idea here: i like everything the menorah now does, but additionally itd be swell if a lapel pin version could also set the LEDs to alternately display
1) the animation through the 8 set-ups, and
2) either the current night of hanuka, or if worn before that, the first night.
it would either switch to or hesitate on the selected appropriately numbered night, then either blink a sec or not then strobe again. dream on!]
but first,on point, is there any reason i cant set up/hotglue a pinback on the little menorah itself, a pinback on the battery casing, and cut the [compared to the rest of it] ugly wire between em, with some sorta sockety thing [are there such? what is it called?] so it clicks back together after stringing it through a lapel hole?
seriously. my dad and i need em.
on groundhog’s day he turned 80, so he needs his first.
is there any way i can paypal you the capital to get one for him?
ps yet 2 more serious questions: do you like/tolerate/sometimes use suggestions? hope so. =D hate my notes? need to know can i can do right by you
im MAD about your inventions and IN LOVE with watching the EMSL vision beautifully corrupt minds. mwahahahahaha
We’ll be making a new version of that kit this year; be patient.
Windell H. Oskay
i am trying to adjust fonts-adding numbers to font list. all i get out is nonsense.
this is what came up for fonts:
anyone tried with numbers before?
Comments are closed.