Other Parts Discussed in Thread: TMS320F28335, ADS8867, DAC8563
Below is a brief overview of my senior design project completed at the University of Florida in Fall '14.
TI E2E: https://e2e.ti.com/support/microcontrollers/c2000/f/171/p/371869/2027538#2027538,
TI E2E: https://e2e.ti.com/support/microcontrollers/c2000/f/171/p/548590/2024965#2024965
General
The idea was to design a digital guitar "Pedal" using the F28335. I had a lot of big ideas for this project, but most of them were squashed by the time constraint and other project constraints/requirements. I absolutely enjoyed this project and a lot of credit goes to TI for supplying most of the hardware at little to no cost.
Major Components
-
TMS320F28335 (Processor)
-
ADS8867 (ADC)
-
DAC8563 (DAC)
-
CFAH1602ZYYHET_v1.0 (LCD)
-
24LC256 (EEPROM)
-
TC4066BP (Switch)
On Github, the main portion of the audio processing can be found in guitarEffects\src\effect.c.
Digital Section
The F28335 was able to sample, process and output 16 bit audio at ~44.1 kHz. I remember not being able to get the number exact, either going a little over or a little under that rate. The F28335 surprised me as it was able to process all of the listed effects in effects.c strung together at ~44.1 kHz.
One of the design goals of this project was to have full control over the audio pipeline. The ordering of the audio processing was determined by which effect button you stomped first. You are able to achieve some interesting sound by stringing these effects together in different order. One of my regrets of this project was not having enough time to create more. Each effect had some sort of variable input that could be controlled by the user, i.e. reverb depth, tremolo frequency, wah frequency, etc... I had a pedal that I planned on interfacing to the board to control these settings, but due to time constraints we had to go with a simple knob on the front of the box. The Wah was by far my favorite effect to design.
The project needed to interface with some sort of memory. The plan initially was to interface with EEPROM to save audio presets and a RAM chip to store audio samples for reverb. The RAM interfacing didn't go as planned so the EEPROM ended up being the only memory we used. You can store/recall presets that preserved the audio chain and each individual effect setting.
The project needed some sort of user interface, so the LCD listed above was used. This was our easiest option because we used it in prior courses and it is extremely simple to interface with, albeit extremely slow. Between the LCD printing and the EEPROM read/write, a lot of code rework/optimization was needed to maintain the 44.1 kHz sample rate.
Analog Section
We needed to some sort of analog circuitry in our design, so instead of implementing digital distortion, we put it in an analog circuit at the front of the audio chain, right behind the EQ. We used an op-amp design with diodes. These circuits are readily available on the internet with a simple Google search. Here is a link that may be useful: http://www.generalguitargadgets.com/how-to-build-it/technical-help/articles/design-distortion/
I used the TC4066BP to determine whether or not to sample the clean channel or the distortion channel. The user was able to select this by clicking the distortion button on the box. A little more work and I would have been able to place the distortion channel anywhere in the pipeline.
The EQ circuit was the very first part of the audio chain. Its was based off of "An audio circuit collection" by Bruce Carter. Here are links to all parts of the series.
Code
I hope a lot of the code on Github can be useful to other people. All of the initialization code for SPI, Timers, Interrupts, and overclocking was found through TI documentation. The Effects were trial and error so I'm sure they can be heavily improved. If you do make mods to them, I ask that you please share them with me so I can learn along with you.
Overall, the F28335 is an ideal choice for simple, home-made guitar effects. I hope this project proves a solid base for anyone else to build off of.