8 Bit Synth: MATLAB Bandlimited Wavetable Simulation and Aliasing

This is what the MATLAB script outputs. No aliasing here!

I’ve spent a lot of time in the development of the Rockit 8 Bit Synth dealing with aliasing.  I made a MATLAB simulation to get to the heart of the issue visually.  The script simulates the wavetable synthesis process by generating a sawtooth wavetable and playing back that wavetable to generate a 50% duty cycle square wave output. This output is plotted along with the Fast Fourier Transform (the frequency) of the signal  By adjusting some parameters, the amount of aliasing in the signal can be increased or decreased, providing a visual tool for understanding the factors that contribute to aliasing in wavetable synthesis.  Click through for a thorough explanation.

Continue reading

Hackme Rockit: 8 Bit Synth Update

I can see the end.  The hardware is pretty much locked down.  I’ve got to do one final layout revision, but the circuit values and everything are more or less decided.  I made an ugly layout mistake in the last revision that coupled a lot of the serial communication into the audio signal as noise.  Only a new layout will fix that.

On the software side, I’m wrapping up the oscillators trying to get creative to expand the sonic palette. I’ll be able to continue working on the software until the end though.  So, I’m going to be starting the new layout this week and next, ordering the final board and winding this design down.  I’m really excited to get to this point, but often wrapping up all the loose ends can be the most challenging part.  I really want this to be as perfect as I can get it to be.

I’m figuring out how the final product will be made available.  I’m looking at some licensing options because I know what it’s like manufacture something and that’s honestly the least fun part of the process.  It’d be nice to license the design to someone else to build and sell so that I can design the next thing.  I’ll still support the design and make software improvements, maybe even a second version with some capability expansion, but it’d be nice if someone else handled the business end of it.  I’ll do it if I have to and it might be my only option.  I’ll fill you in as I know more.

Cheers and happy designing!

New PCB is in!

Rockit PCB

I got in the new pcb today and it looks great.  I’ll build it up tonight.  I have to recommend imagineering, the company that built the pcb.  They have an excellent first time offer of $25 a board. They delivered early and I picked them up this afternoon. I am excited! Let’s make some noise!

8 Bit Synth: Audio Sample

A while back, I lamented my struggles with aliasing.  Well, I resolved them and found inner peace with digital signal processing.  Slowly it’s becoming second nature.  I’ve got about 90% of the original functions working.  The only major omission is MIDI at this point.  That shouldn’t be too hard.  To celebrate, I made this lo-fi recording using the audio in jack on my laptop.  Lock up  your dog and check it out. It’s just one key held down so the filter envelope isn’t involved.  The filter, both oscillators with only three waveshapes at this point, and both lfos are running.  I’m changing the pitch with a knob.  It starts out hissy from the input, gets going with a simple sin wave, demonstrates some pitch, moves into other wave shapes and some beating oscillators, then takes off with filter and lfo modulation.

Listen to the 8 Bit Synth sample

8 Bit Synth: It’s Alive!

Oh, I feel like a proud parent. I’ve given birth to a square wave roaring lion. I got through troubleshooting the pcb, finding a few traces that weren’t routed and a few connections that were incorrect. I haven’t dug into the details just yet, but the function is there. Fine tuning will follow. This step brings me much much closer to the day when I can offer it to you as a fun new toy or a shiny new weapon in your arsenal. The filter definitely works, which is sweet and probably the most important thing to be sure works. Filters make or break synths. I think you’ll like the way it sounds. Once I get a bit further, I’m going to post some audio samples to give you an idea of what to expect. For now, back to work…

Embedded Software: #ifndef #define my_way

So, I’m deep in embedded software, or as people in the know call it, firmware.  A lot of what I’m dealing with is rookie nonsense.  Now, I’m probably more of a journeyman coder at this point, but good high quality code doesn’t just spring from good intention and effort.  There are a great many rules and tricks of the trade that can only really be learned from someone else.  I, being self-taught, have learned much of what I now know by blindly stumbling through the wilderness until through sheer effort, I find the way out of the woods of impenetrable error messages.  I’m going to be sharing over the course of many posts, some of the rules and best practices that I discover along my journey. Hopefully, they’ll shorten the duration of your meanderings.  Follow the jump for a discussion of the use of the preprocessor directive, #ifndef.

Continue reading

MCP23S08: 8 Bit I/O Expander: Part Two:
Extra Switch Inputs

In Part One about the MCP23S08, I discussed how to set up one of these i/o expanders as a bank of outputs to drive LEDs.  They can also be used as digital inputs.  They don’t do any good as analog inputs for things like pots.  You can use analog multiplexers for that.  As digital input expanders though, they make an excellent way to expand your systems switch capabilities.  I am using them for banks of tactile switches to step through options to control my synthesizer.  Follow the jump to see how I configure them…

Continue reading