NES Musical Masterpieces

This article requires some knowledge of oscillation for producing sound. I’ll also confess that determining what chiptune sounds good requires an appreciation for them.

In my opinion, the Nintendo Entertainment System is the first video game console to feature games that have gameplay that still holds up to today. People still play NES for their playbility rather than solely their nostalgia factor. Older consoles like the Atari 2600 featured very simplistic games that gamers only play today for nostalgic reasons. Those who didn’t grow up with the Atari console don’t find any meaning in them.

I’m not sure if I mentioned this before on my blog, but I have an incredibly soft spot for chiptunes. There’s a charm to pushing these chips that can only make simple sounds to their limits to create a beautiful piece of music. I enjoy melodic music and what other than video games have solid and consistent melodies? There are some composers that I consider magicians because they make songs so deep that you’d put it in a club.

The NES APU, the sound chip in the NES, is what generates the simple tones to create music and sound through the console. Quality was lukewarm with the original Famicom and NES that outputed sound and video through a single coaxial cable. Eventually, a composite output was added providing a purer sound, though it was mono only despite many artists writing stereophonic music. Certain enthusiasts build mods to extract both channels.

There was five channels on the APU. Two pulse-wave (square) channels with four pulse-width settings in addition to a triangle channel. A random noise generator. Finally, a PCM for playing samples, although low-quality due to memory limitations.

I’ll give a basic explanation of how most games used these channels though some artists were more creative with their use. The two pulse channels supported the main melody, one was the main one and the other supported it (say with a slightly different pitch). The triangle channel was used to add bass. Finally, the noise channel was used for percussion.

Additional sound chips were used in cartridges that added extra channels or FM synthesis. I will talk about a few of these later but won’t cover all of them since there’s quite a few. I’ll go through some games that use them. Unfortunately, the sound chips could only be used on the Japanese Famicom since the NES didn’t have the sound passthrough through the cartridge slot. American ports of these games had to make shift with use of the available 5 channels and often the game sounded more muddled in comparison to their Japanese counterparts.

I want to take a dive into a few a games that have music that I consider ‘masterpieces’. There’s no real criteria other than my subjective tastes. Many won’t agree with me but I’m sure it will be appreciated by those who love ‘old things’. I hope you enjoy a few tunes and the order is set by my preference.

Super Mario Bros.

The overworld theme in Super Mario Brothers isn’t something I would consider a masterpiece. However, it’s such a classic that I felt that I had to include it here. There’s not much to comment about, it uses channels in the same way that most games do. Virtually everyone has heard some version of this song and I would consider it the prime example of chiptune.

Super Mario Bros. (World) (HVC-SM)_001.png
Super Mario Bros. (World) (HVC-SM)_003.png

Some noticed that parts of the music would be interrupted while jumping. It’s because all five channels were used for the music and nothing was left for sound. The sound effect would take place of one of the square wave channels so that it could play.

Mega Man 2

I would best describe Mega Man 2’s music as the ‘traditional’ sound of the NES. No special techniques are used for production, no intense melodies; just music that perfectly fits the atmosphere and theme of the level or the situation.

Mega Man 2 (USA)_001.png
Mega Man 2 (USA)_004.png

The boss of the stage, Quick Man, uses electricity as his weapon therefore the music has an electric sound to it. The music also plays at a faster tempo because of Quick Man was quicker than other bosses in the battle.

Mega Man 2 is an excellent example that simple music can still sound pleasant without the input of a master who knows every limitation of the chip and instead used it traditionally. Mega Man 2 uses the typical channel setup that was mentioned above for producing melody and beat.

One interesting fact about the composer’s goal was to create very simple melodies only composed of a few notes. The idea was to make catchy songs that were almost as simple as a pop song with a similar structure.

Silver Surfer

Tim Follin is probably the composer with the worst luck. He pushed soundchips to their limits making some amazing pieces except there was one caveat, the games he was contracted for were absolutely terrible.

Silver Surfer was torn apart more than a decade ago by The Angry Video Game Nerd. It sent him into a fit of endless cursing and swearing. However, he oddly didn’t comment on the amazing music in the game. Maybe he was too distracted by the awful gameplay.

The insanely fast paced music almost sounded something that would come out of the SID Chip on the Commodore 64. It was demoscene quality to be honest. He even managed to produce a convincing electric guitar sound.

Silver Surfer (USA)_001.png
Silver Surfer (USA)_002.png

The kick sound isn’t created with the usual DPCM sample like done in most games. Instead the triangle channel is with a pitch change is used to create a quick thump. He uses the same channel for the kick but what really showed that Tim Follin was a master at his art is that the two never played at the same time. It required quite a bit of creative production to never have them clash.

I really want to highlight how bad his luck is. Imagine being the composer for a Pictionary game, I’m sure you’d write something atmospheric and melow. Instead, Follin decided to compose something that would fit an Action-Adventure game where you’d be saving the galaxy from mutant aliens.

This is unusually intense for a board game but perhaps this was to make up for the boring nature of the game. I wonder what kind of music we’d end up with if he was composing for Chess Master.

Admittedly, Tim Follin confesses that he often didn’t compose music to follow the theme of the game but rather see what he could do with the limitations of the sound chip. That might explain the situation with Pictionary.

Pictionary - The Game of Video Quick Draw (USA)_001.png
Pictionary - The Game of Video Quick Draw (USA)_002.png

Journey to Silius

If any game completely broke the rules on the traditional method of using channels, it’s Journey to Silius. The artists did an amazing job of creating something that sounded so much fuller than the average NES game. The bass was stronger, the melodies more engaging and a beat that sounded completely different.

The two pulse channels were still used for the melody but instead of using the noise channel for the drums only, they combined the noise and triangle channels to create a very realistic sounding drum. This was because attack was done with the noise channel and decay using the triangle channel. However, the stroke of genius was using the traditionally unused DPCM sample channel for the bass. The samples used for the bass are pretty high quality and provide for that deep sound we crave when listening to music.

Journey to Silius (USA)_005.png

Castlevania 3

The music between the American and Japanese Castlevania sound completely different. This is due to the use of a chip VRC6 which adds two square wave channels (pulse) and one sawtooth channel. It’s not secret that having additional channels creates for a deeper sound and this is definitely the case for Akumajou Densetsu. There’s not much to comment other than to listen.

Akumajou Densetsu (Japan) (Virtual Console)_002.png

It’s quite obvious that the American version sounds much more dull. The artists didn’t really use any creative techniques to make up for the missing VRC6 chip. Instead, they used the typical arrangement using channels to generate beat and melody. It’s a bit disappointing.

Lagrange Point

Lagrange Point doesn’t sound like any NES game in existence. Rather than primitive sounds, we hear a pleasant and smooth track being played. This is due to the use of a special chip, the VRC7, which adds 6 channels of FM Synthesis. The sound produced ends up reaching 16-bit territory.

I won’t go into detail of what FM Synthesis is because I’m leaving that for another blog post. However, it can be noted that the VRC7 is used exclusively for the music while all other sounds effects are still done with the NES APU. The contrast between the two sounds is a bit jarring in my opinion and generates a disjumbled mess of 8-bit and 16-bit sound. I have to admit it’s quite strange to see 8-bit graphics with 16-bit sound, it doesn’t feel right.

Lagrange Point (Japan)_001.png

Gimmick!

Gimmick! (Japan)_002.png

This company is playing its magic tricks again. If anyone could make the 8-bit NES sound and look 16-bit, it would be Sunsoft. Wikipedia lists some of the amazing techniques to generate such beautiful graphics using mostly graphics tiling optimizations.

My favourite track is an unused one, Strange Memories of Death. It has all the elements of a good song, catchiness, good production, a rich sound and oddly a dark undertone which flows really smoothly.

Gimmick was the only game to use the Sunsoft FME-7 chip which contained the Sunsoft 5B. It contained extra channels which the game used mostly to produce more bass (similar to Journey to Silius). Interestingly, the game didn’t make use of all the channels of the chip neither were all the features such as noise. It’s also the only game that uses the chip.

I put Gimmick! last on this list because it’s my favourite soundtrack on the NES. It spans multiple genres and sounds like a mix of different video game music styles. Apparently, this is what the artist intended. It has a rich deep sound unparalleled by any other NES game and I bet the bass would sound nice on a decent set of speakers or headphones.

Conclusion

This was just a small sampler of some of the good music that is on the NES. I haven’t played that many NES games and had to find other ways to discover interesting music. There’s a lot to listen to on grad1u52’s YouTube channel though unfortunately they add a reverb effect to the music which puts it further away from the original.

Chiptunes are an acquired taste for most people who are used to pop but I consider those to be simple music as well. I have shared with peers these songs and they have found them interesting but it didn’t light them up. It was just something that sounded different to them.

My next writing adventure will be about FM Synthesis which is my favourite way of generating sound. Most focus will be on the Yamaha YM2612 in the Sega Genesis and perhaps the OPL2 from the AdLib PC sound card.

If you have your favourites on the console, feel free to share them. Other kinds of chiptunes are welcome in the comments section below.

Ottawa Computing Group

I’ve just founded a meetup group in Ottawa, ON for programmers and hackers to work together or alone on whatever projects they’re endavouring in.

From the meetup description:

“Writing the next hot Android App or making a mundane Web App? Bring your laptop and hack away at your next computing project. Everything is welcome whether is traditional software development or administrating your personal website server. If you can do it on a laptop, than you're welcome to join.

You can both hide in your corner quietly typing away or sit in a group with your portable rigs on table and discuss your next big computing adventure.

This group has no focus on the type of technology being worked on, whether it's a basic web project or artificial intelligence or machine learning. Bring your ideas with you and share them with the group.

Non-hackers are welcome to join if they want to be thought how to code, we're all open for learning opportunities. Just ask anyone if they're willing to teach you new skills. If you're stuck on some tricky part of your project, ask your peers for help.

We will be meeting weekly in various coffee shops in the downtown area. If we get big enough, we can have groups in the suburbias of Ottawa.

Feel free to be late to the party or come in a bit earlier. Leave whenever you're tired at staring at your screen or have a more important date coming up.”

Hoping to meet you exciting people and see projects beyond my comfort zone!

Procedural Music in 256 bytes.

If there is one type of music that I have an incredibly strong taste for, it’s chiptune music, ones played by electronic circuits and chips rather than actual instruments. Classic games are a great source of these tracks and some of my most memorable melodies come from them.

During the Oldskool 4K Intro competition at Revision 2017, the Swedish hacker Linus Åkesson, manages destroy the 4K intro limit, with a tiny program in 256 bytes for the Commodore 64, a 1/128 factor reduction of the maximum. It is not a surprise that it won first place in the competition.

My day job involves me working with bloated runtimes and gigantic libraries that some span in the order of several gigabytes. Powerful machines with several cores and gigabytes of RAM are required to run these applications.

I am humbled by classic video game designers who had to work with tiny amounts of RAM and pathetic processors found in calculators like the Motorola 68000 and still manage to have colourful experiences with wonderful sound running at 60 frames per second.

The goal of these developers wasn’t some philosophy like maintainability or a certain idioms or design patterns, but rather extracting the most out of the hardware and provide the most impressive gaming experience.

When the Revision 2017 demo competition was over, I start looking at the winners, and nothing touched me more than the “A Mind is Born” demo. His technical description barely fits in my head and makes me feel like a novice programmer in my first programming course.

The actual executable is 256 bytes, and there was room to spare with the first instruction being a no-op (NOP). Ironically, the SID tune is larger at 325 bytes and encoding to MP3 would make a file larger than 2 MB. Encoding this blog post in UTF-8 is more than 256 bytes!

The music is generated by the program itself rather than having a score embedded in the program. The conductor isn’t the programmer, but the program. This is the procedural aspect of it. It sounds like a chaotic psytrance piece building up to a strong climax at 1:42 morphing into a real pseudo-orchestra.

This chilling piece of music shows what the mind of true geniuses can produce. If you don’t get goosebumps listening to this, you have no appreciation of true technical art. I recommend a listen with a good set of headphones to enjoy the incredibly deep bassline.

How to Drift a Bus

This is another satire...

I traveled to Japan last year and got a chance to meet the Drift King himself. I was doing a track day and drifting culture is hot in Tokyo. I got a chance to speak to Mr. Tsuchiya and he told me a funny story about drifting something you wouldn't expect:

Hi, my name is Keiichi Tsuchiya, and I am the Drift King. I call this maneuver the "Omenibussu Duriftu" and it cost me my job and sent me into abject poverty.

I started doing this on rainy days tired from my 8 hour shift of hauling passengers around, I needed to relax and have a bit of fun. I would move the bus side to side and then turn hard and the bus would drift. Passengers screamed and complained as I counter-steered the slide. The complaints lead to me being fired ending my career as a bus driver.

If you want to try this yourself and risk your losing your wage, just do the following mods and follow these instructions.

Make sure you inflate the rear tires of the bus as much as you can and deflate the front ones. This will make the bus prone to oversteer. I convinced the maintenance workers to install nitrous on the bus telling them that the bosses ordered us to test out this new ethanol reduction system. I even convinced them to weld the rear differential as it would help getting out of sticky situations in snow.

I recommend you do this with 40 footer bus as an accordion bus may lead to fish-tailing. Use a track with plenty of run of area to prevent accidents or the rapid-transit road if you're brave enough. You'll need a rear-engined, rear-wheel drive bus for this technique (a bit like the Porsche 911).

First, accelerate to 60 kph, and then swing the bus left and right until you reach the corner. While you swing, keep accelerating until 100 kph. Then once it reaches the turn, accelerate hard and let the bus slide without adding steering input. Half-way through the slide, counter steer and reduce throttle. It will work every time, at least for someone skilled like me.

The simulation was possible thanks to BeamNG.drive

The Million Dollar App Idea

If you're a mobile developer, this almost certainly happened to you. A friend or relative makes you swear to secrecy about what he's going to tell you next. His secret idea will change the world and make millions. He comes up with the idea (usually like Uber but for X) and you do all the development work, split share 50/50.

Most people think that coming with an idea is hard, but it isn't. Everyone has a ton of ideas all day long, many of them ridiculous and some few genius. However, execution is the difficult part: development, marketing, building a company and so on. That sucks in every available time slot in your day as you try to make your idea into reality.

What's worse however is most of these ideas fail. Startups get a ton of investment money that is sunk into nothing. People quit their jobs hoping their new business will let them retire early. None of this really happens.

People are mesmerized by what they see in the media. A teenager who made a soundboard app makes millions and buys a mansion at age 17. Another makes thousands of dollars in ads from his YouTube videos or Twitch streams. However, all of this is a form of survivorship bias.

How many Twitch streams are watched by virtually nobody compared to the few famous ones. Pennies are made from most YouTubers who put ads up. The reality is that these successful people are the exception not the norm, they can almost attribute their success to luck.

I've seen people with no fame make excellent content and vice-versa. Producing good work isn't guaranteeing success. Not the best product is always the one that makes it to market. If we can call it that, fate, results in success.

However, to succeed, one must play the lottery game and hope to make it there. You can't beat the odds if you don't try. But don't approach the idea with naivety, but actually study what people want. Notice how informercials sell mundane things you never thought of and they sometimes make great success even if their products are garbage.

Think of a problem that you actually experience day to day. Something that bothers you and perhaps others. Maybe finding a solution to that would increase your success. Don't just imitate another streamer or blogger, because they succeeded out luck mostly. You need to do something novel that no one has ever thought of yet, and maybe, just maybe, you'll be making a few bucks.

When working on a project, your goal shouldn't be fame or money, but rather passion and learning. That growth is so much more valuable as the new skills you learn can be put into use somewhere else, maybe in a job that actually makes money.