Reverse-engineering a tiny 1980s chip that plays Christmas tunes
righto.com
righto.com
I decided to take a music class to learn a little more about music and thought that would help me with my project. The professor would play various classical pieces and lecture about them. Our homework was to go in a listening room and familiarize ourselves with the music. Everything was on vinyl so you would put a record on, listen, take notes etc.
When the first exam came, the professor would take out a record, and place it on a turntable and play a piece and you were supposed to identify it. I was amazed that all the other students seemed to be getting all of them and I was struggling. I went to the professor's office hours and I explained to him my project and what I was working on. He was very intrigued and suggested that I consider Bach especially Fugue's which has a lot of repetition and cycles (good advice I ended up using Bach Toccata Fugue in D minor, which is used a lot in old timey horror movies and I just loved it).
Later, after talking with other students, they showed me their "system" which was crib notes with things written on them like "Blue label with yellow text = Bethoven", things like that. In other words, they were cheating. They were making crib notes about the record labels in the listening room and paying no attention whatsoever to the music.
Since the professor was so nice to me, I decided to tell him about it. He listened to what I said, and he just said "I see", then asked me about my project. He asked if he could come when I presented my project and I was thrilled he was interested.
But he seemed to continue to use the records and the same method, until the final exam when he announced to the class he was going to use a new system, a Tape Deck! You could hear an audible gasp in the classroom. Needless to say, a lot of students did not do so well on the final. I got an A.
I also got an A on my capstone and the EE professors were all very impressed I had taken the time to research the music and my music professor got up and said a few words for me. It was a really cool experience in my life. I hope it is OK that I shared such a long boring story, but every time I see something about a music chip like the kind in greeting cards or whatever, it kind of reminds me a little of my project and how much I enjoyed that experience.
As for the technology of the chip Ken covered, it is of course, quite a bit more sophisticated than mine was, at least as memory serves me (pun intended).
Definitely okay. I found this story absolutely delightful. Thanks for sharing, and happy holidays!
And just a quick aside, Thanks to Ken for what he does, obviously I ravishly read everything he does!
Please have a wonderful Holiday!
If you don't mind me asking- What sort of things are you doing now? Are you able to do much R&D?
I still love music, especially Jazz and find inspiration from it at times.
Thank you for asking.
Happy Holiday !
Have a wonderful Holiday!
This makes me wonder if you put one of the other test pins on a scope, if you'd see a pattern representing the song or sequence, allowing quick verification of the chip. I think at 512x speed, even a more limited storage scope of the era of these chips could capture the full output on-screen. Each flavor of the chip probably had an expected pattern based on ROM which could be checked.
I'm imagining a technician sitting at a test bench, having to do verification work on these all day, thankful for having a test pin instead of having to listen to the same dang beeping song over and over :)
Have you decapped other sound-making devices? The greeting card chip makes me think of the ubiquitous "laser noise" chip from countless 80's kids toys. That or one of the many kid's keyboards or baby noise console devices, that have all of the function inside a single epoxy-blobbed die. It would be pretty fascinating to see a similar breakdown of which sections encode samples, note values, rhythm and sequences, control inputs, etc.
Edit: Not a decap, but this page [2] has links to the datasheet and other reference material that includes a block diagram, and even has circuit diagrams of the internal circuitry.
Edit 2: A video [3] demonstrating some of the possible sounds.
[1] https://en.wikipedia.org/wiki/Texas_Instruments_SN76477 [2] http://sandsoftwaresound.net/sn76477-complex-sound-generator... [3] https://www.youtube.com/watch?v=atH1MvXDYYE
Preferably Nikon, but my limited understanding is that the canon sensors are easier to debayer.
Eg Sony IMX455 61MP sensor in the $4k ASI6200: https://astronomy-imaging-camera.com/product/asi6200mm-pro-m...
The IMX455 is an incredible hi end sensor; there’s only about three medium format sensors that exist with higher resolution—forget getting one of those for “only” $5000—but the cost of entry to have one in a usable camera is pretty substantial.
How many transistors does it have in all?
They could have used an LFSR for the PC too. Would that have saved some area? If not, I wonder why they used them elsewhere.
Are the resets (on 10000...) synchronous? If not I wonder how they handled glitch safety.
Yes, the resets are synchronous.
I wonder if you could do a CMOS μC in 1500 transistors; my best ideas so far are barely under 3000. Of course to make music that way you need a much faster clock plus some code memory.
I got down about that low with a bit-serial design whose only arithmetic instruction was a subtract, but I haven't simulated it at even the RTL level, just done a gate-level design on paper and a couple of software instruction-level sims.
My parents had that card when I was a kid, it really was great.
https://www.youtube.com/watch?v=qcqGqpI4qBU
Merry Christmas!
For what it's worth, I've come across at least three variants of this particular chip that play slightly different versions of the Jingle Bells/Santa Claus is Coming to Town/We Wish You a Merry Christmas tune. In addition to the one in the video, there's one that holds a note for slightly too long during Jingle Bells ("oh what fun it is to ride" becomes "oh what fun it is - -", and another that repeats the first line of "We Wish You A Merry Christmas" a third time.
I wonder if they're knockoffs, and if so how they're constructed!
The earliest example of an LFSR I’ve seen is the Nintendo Entertainment System’s white noise generator, implemented in hardware. But many NES games used software LFSRs to generate random numbers for gameplay, so the trick was probably long-established and well-known at that time.
I have found that "River Raid" (1982) and "The Sentinel" (1986) were using it for game data. Apparently, the original "Elite" was supposed to use one, too, but they decided against it.
There are some 4-bit CPUs that use an LFSR as the program counter, so the ROM gets stored in pseudorandom order.
It's fun how the lowest tech chips and the highest tech chips both end up resorting to the same old techniques, isn't it? :)
What would be the reason for the pseudorandom ROM order? Just a side effect of the PC choice or deliberate?
sidenote: interesting that two sentences into your response I knew exactly what name I was going to see as the author. Thanks for the work you're doing and especially for documenting it. I've been reversing my old DSL-modem to pass time during lockdowns and since it's an obscure, asic based model it's highly educational to see you talk about figuring out things living on the hard/software boundary.
The pseudorandom ROM order is just a consequence of using an LFSR as a counter, since it counts in pseudorandom order.
I'm glad you enjoy what I'm doing! It's a lot of fun being able to work on a project like this, and I'm glad some of it is educational for other folks.
What!!?
https://kitronik.co.uk/products/2939-happy-birthday-melody-i...