A virtual analog organ in a Spartan 3E FPGA in VHDL

(c) 2006 Jürgen Schuhmacher

 

Subject

This project intends to reveal my physical organ built first in 2001 with a Xilinx XC4000 PLD and analog environment. See the Virtual PLD organ 03 page. All hardware was totally replaced by VHDL and moved to a current Spartan 3E FPGA. A virtual keyboard controller is established by adding a wave player module to obtain automatic song performance. The RAM holds around 4030 music notes events which are preprocessed processed and mapped to the virtual keyboard, which provides 7 x 6 = 42 notes and thus covers all the white keys of 6 octaves altogether. The tuning is C-Major tempered tuning in 440Hz / 443Hz. 2 Organ registers are available. Both registers can be enhanced with an analog boost option to emulate the individual analog configuration of the sub modules. For more information about this strategy see the Analog PLD Organ V3 page.

Hardware

FPGA Organ Project - PLD Organ 2001 in a Spartan S3E 500

Digilent Spartan 3E Starter Kit with Xilinx S3E 500 FPGA.

Block Diagram of the Organ FPGA

Spartan Design

One main Organ Module drives 5 sub circuits. Here 5 channel groups are used and placed on a discrete stereo base. Find more information at the S3E Audio Page: PLD ORGAN V2003.

 

Data Flow of the Spartan 3E organ

Data Flow of PLD Organ - Sound Path - Jürgen Schuhmacher

 

 

Usage

The 4 buttons and the 4 switches of the Digilent PCB are used to control the music player:

 Button N : Increase Loudness

 Button S : Decrease Loudness

 Button W : Increase Speed

 Button E : Decrease Speed

 

 Switch 0 : Swap Stereo Channels Register 1

 Switch 1 : Switch on Register 2

 Switch 2 : AnalogBoostFilter of Register 1

 Switch 3 : AnalogBoostFilter of Register 2

 Rotary Knob / Push button : Restart the song.

 

 With restart, the source selector progresses one step. 4 options are available:

Keyboard 00: Song RAM

 Keyboard 01: Song RAM with octave overlay

 Keyboard 10: Generic Tones

 Keyboard 01: Generic Chords

 

The octave overlay is done that way, that the keyboard is moved one octave and added to the originally keys pressed. The song in the RAM is "mysong", similar to that version I composed for a VC20 video game in 1981.

 

Output

Since the PCB does not have an audio out, a dual PDM module is used to generate a 1-Bit-Data Stream similar to audio-PCM. The frequency is 15 MHz. To be able to hear the sound, a RC-Filter has to be added to the two output PINs of the Digilent Port. Use Pin "A4" for LEFT and Pin "B4" for RIGHT. The RC Filter should be R=470 Ohm and C= 10nF / 1uF in parallel.


FPGA Organ Project - PLD Organ 2001 in a Spartan S3E 500

High Quality Stereo PCM-to-Analog Conversion Circuit. Use light blue oxygen free wires only :-)

 

The Tuning can be configured with the e-scale tuning using my 185/196 ratio

 

 

FPGA - Design Spartan FPGA

FPGA Organ Project - Xilinx FPGA Tool Chain

The FPGA Design has been done with Xilinx ISE 8.1.

 

 

Program File

Download a bit file with an example song for Digilent Spartan 3SE FPGA board: spartan s3e organ.zip

The song is called "enthusiasm" and was composed in 2000 because of a certain impression  at the Olympic Games in Sydney.
Listen to a snap shot here: enthusiasm.mp3

Please note, that in this demo bit files, only one RAM is available. See the bundled readme file for details.

 

 

J.S. 2006