The Sapir-Whorf hypothesis, but for projects

Recently, this urban legend was posted on Hacker News. It’s one of those stories where a grunt on the factory floor came up with a better, cheaper solution than a large bureaucracy.

Surprisingly, my comment there got a lot of upvotes:

I think another take-away from the story is that the domain you work in will dictate the solution you come up with.

If you are a high-level exec, the domain you have, the levers and pulleys available to you, are asking your direct reports to investigate the issue and come up with a report on the problem and generate potential solutions, which will then be discussed and evaluated in meetings–at a very high level. To somebody on the ground level, the domain of the problem is “what do I have around me to save time? oh, I have a fan, let me use that. Done.”

I think your point about incentivizing workers is part of it. This story reminds me of the This American Life piece about the NUMMI plant where Toyota worked with GM to teach them the Toyota way of assembling cars. [1] Part of the Toyota Way is to empower the individuals at the ground level to own the process and to improve it. The interviews are surprisingly emotional for something that’s “just work”, but I think it shows how empowering people to own and improve their everyday gives them agency.

[1] https://www.thisamericanlife.org/561/nummi-2015

Similar to Conway’s Law, the solution you come up with is dictated by the process or tools used to come up with it. Taking this further, it’s like the idea in linguistics that the structure of the language you use shapes your world view.

To me, what this all tells me is if you want to come up with better solutions, or see the world in new ways, or just be more creative, you really do need to expose yourself to new ideas and modes of thinking. If anything, modes of thinking that are completely foreign to you, or are hard for your brain to grok, are the very ones you should be focusing on if you wish to expand your thinking.

Introducing Draw Me Something

I’m happy to announce my new drawing website: Draw Me Something aka Drommy Sommy.

Draw Me Something lets you request drawings from other people or answer requests for drawings from others. It’s that simple. My idea is for it to be a fun little place to doodle things for others.

It’s still a work in progress, so please check it out and leave feedback here.


(The above drawn with Draw Me Something.)

Hey, let’s build a retro synth music player! (Part 2)

To make a music synthesizer, we need to understand how audio works. It’s a complicated subject and my goal isn’t to explain it fully here. I’ve provided links to better resources. We just need a minimal of understanding to build our synthesizer.

Audio is made by vibrations. Your computer’s speaker vibrates, causing the air around it to vibrate, and that air’s vibration is picked up by your ears.

A musical note is generated by vibrations (waves) at specific frequencies (the note’s pitch). A vibration at 440 Hz (i.e. having your speaker vibrate back and forth 440 times in one second) is heard as an A note. (Hz is short for Hertz and is a unit of frequency that just means “cycles per second”.) Notes on a musical scale each vibrate at specific frequencies and loudness. The higher the frequency, the higher the pitch of the note. Scales are a complicated subject, so I won’t go into too much more detail. The loudness of a note is dictated by the amplitude of the wave.

Our music synthesizer is going to emulate how retro game systems and consoles from the ’80s worked. These generated sounds by playing tones with specific shapes, aka “waveforms”, that were easy to easy to produce by these chips. These were typically square waves, triangle waves, or “noise” (randomness).

Watch this visualization of the Legend of Zelda theme to see what I mean. Each quadrant is playing an instrument, and you can clearly see the shape of each one. The bass tones are in the lower left and the snare drum effect is in the bottom right.

Listen to how each shape sounds and notice how the higher pitch sounds make a wave with more peaks and troughs in the same amount of space (or time). See how bass in the lower left has fewer peaks and troughs since it’s playing at a lower frequency than the square waves in the top two quadrants? Pay attention to the amplitude of the waves as well. Towards the end of the song, you can see them gradually decrease until they go silent.

Look at how the snare drum sound is achieved with a really noisy looking wave. That’s because it’s a noise wave, which looks like random peaks and troughs. Noise waves were typically used in old game systems for explosion sounds, crowd noise, ocean waves, and snare drums.

There’s one last thing to note in the video: there are only ever four instruments playing at any one time! Old game systems and computers were often limited in the number of instruments they could play at once. Our synthesizer will limit itself to a fixed number of instruments as well just to make it authentic.

Finally, watch the video below by The 8-Bit Guy for a really good summary of how old game systems played audio. This is how we’re going to do things too!

Okay, that’s enough for today. Next time we’ll talk about ADSR envelopes.

For a way deeper article on musical synthesis, see this article.