The first thing you should know about me is that I don't like unstated assumptions.
The world is a complicated place, and our small minds can barely hope to fully grasp it. So, I'll pretend that I'm a good writer and you can pretend you're interested in reading about what sounds like a confused dating profile.
It's not a dating profile.
I like long walks on the gravely beaches of Alberta, pina colada flavored bubble tea, and getting caught in a try/catch exception. My pastimes include coding, making impeccable websites, making peckable websites (*insert chicken peck*), and guitar. If you'd like a website like this one, and would like to pay me for it, head over to the freelance (*link*) section. If you'd like to hear more options, please press 2. (*insert dial popup*)
In all seriousness, I wrote this website to help market myself as I move to freelancing and just really to show others what a website can be and what kinds of things that websites nowadays are capable of. Of course I don't claim to have the fanciest website around, but it loads quick, it's quirky (if I do say so), and it represents who I am. Coincidentally, that's also what kinds of things I'd like to work on for freelancing.
Archived: Arduino Guitar Pedal
This all stemmed from when I had linked a friend a nifty demo of a guitar pedal. He wanted one so much I suddenly felt the urge to build him one. Luckily there were many DIY guides on how to build an arduino guitar pedal including one on how to build the one in the video, courtesy of Kyle McDonald.
My design was based off of Kyle’s, but I improved in certain areas. I didn’t want an external preamp (because I didn’t have one) and I didn’t need stereo output (because I’m not Van Halen). I bought most of my parts from sparkfun.com and the rest I got from random hobby shops.
I had initially tried read in the guitar signal directly, only to realise it was in the milivolt range. Even a windmill strike with max volume did no more than a blip on the input. For simplicity’s sake I plugged the guitar directly into the LM358 op-amp which added some ridiculous gain (something like 10x-100x). My input’s minimum and maximum gain is shown below:
However I had a problem, my input clipped the negative portion of the guitar signal. An op-amp needs a positive
and negative rail to guide it’s input in both directions, I only had
Later I tried adding a DC bias to the guitar signal simply by connecting it to a voltage divider. The idea was to add about
to the input wave so that when amplified it would swing about
When I removed the op-amp I had for my output stage (explained below) I had a free op-amp which I then used to act as a proper virtual ground. This was essentially a voltage divider plugged into a unity-gain amplifier (voltage follower) which then plugged into the “ground” end of my guitar. The op-amp’s resistance was ludicrously high so it didnt affect the guitar whatsoever. Now I could capture the full waveform (500 is midpoint):
For my output stage, I used Kyle’s method. Using the PWM signal from
At first I added an amplification stage to my output signal which involved adding a DC bias, amplifying with an op-amp, then removing the DC bias. Luckily, the DAC signal was strong enough on it’s own (maybe twice that of a guitar) so the output amp stage was remove, freeing up an op-amp.
So far, my input and output stages were working. I could test the input by printing off values through the serial port, and the output by having my code output a sine wave (in the form of a stored array of sine values). Since my output had it’s DC bias removed, it didn’t matter where my values were centered at just as long as they were centered somewhere. With no effects (input value not changed before output) my pedal sounded like this:
The first effect I added was an AND response filter. I had tried an OR response filter but it was so weak it sounded just like the clean input. The final code for the AND filter is as such:
since the sample was a
The second effect was a XOR filter which used a similar method as the above. The only difference being the
Both of these effects have a “distortion” sound to them. The next 2 effects work in a similar fashion:
A circular buffer stores the previous values in a FIFO manner. By using
The last effect was a frequency detection algorithm dubbed “Cthulu Mode”. This would use an FHT (faster verion of FFT) to plot a sample window into frequency domain. For this I used a neat FFT library for the arduino. After the frequency was found, a sine wave of the same frequency was played as output. This effect got it’s name when it hilariously failed to detect the guitar’s fundamental frequency and instead sounded like Cthulu, demon of the sea, was trapped in my amplifier.
Unfortunatly my “source control” repository reverted to an older version (thanks Google Drive), so I’ve lost the code for “Cthulu Mode” as of writing this. Luckily, I’ll never
see that ugly piece of code again lest it thrust forth from
This was so far the most complete project I’ve done yet. If I were to improve anything it would be a complete redesign of “Cthulu Mode” using a better frequency detection algorithm such as this.
following the tradition of giving pedals abstract and synesthetic names, I christened my pedal
END OF POST
Archived from my previous website. Still have the working pedal, haven’t touched it in awhile. I’m on to other musical things now.
things I made
In no order (TODO: add images, reformat as grid)
- Arduino Guitar Pedal
- 4Score Iphone game
- Soundcloud scraper
- Raspberry Pi Wireless Sampler
- Home-made touch screen
- Software modular audio synthesiser
- Experiments in natural language processing and machine learning
- LED control circuits withh arduino
- Arduino spatula bot controlled by twitch
- Github commit viewer
- Auditory github commit viewer
- App for geotagging landmarks and commenting (anonument)
- Redid computer engineering wordpress site
- This website
- Experiments in DSP for face/eye tracking
- Homemade unofficial calendar for the 2015 Edmonton Fringe
- GPS path viewer
- Scrolling RPG platformer for GameJam
- Experiments in genetic programming
- Experiments in GPU programming (CUDA/WebGL)
- Encoding images from phone onto reel to reel tapedeck
- Program to take screenshots of Ionic phone apps
- Tool to see how frequently JS code is run (js-hist)
- Multi-user poetry app with unique suggestion UI
- Online signal for when to go to the bar in school
- Unfinished procedurally generated space RPG
- Discover Alberta app
- Enroute Taxi Advertising System
- Forestry radio tower registry
- Timesheet management system
- Home appliance maintenance app
- U of A Rutherford house tour app
- Social restaurant marketing app (MyTab)