cancel
Showing results for 
Search instead for 
Did you mean: 

PSoC 5, 3 & 1 MCU

Anonymous
Not applicable

Hi every one,

I'm a french student in électronic and i have to do project for the class and i ll evaluate on it.

I'd like to create mini synthetizer .

I would like to know how could i generate tone like piano notes with the wave dac8 component?

I can't find the fonctions to set my values on the main C

I already set my frequency value for my DO note with the wavedac8

Thanks for your answer;

Best regards Kevin

0 Likes
Reply
1 Solution
Honored Contributor II

Kevin,

there is old Application Note by Dave Van Ess, which is no longer available on Cypress site. It describes simple piano simulation using PSoC1. You have to re-write the code, as it is not directly compatible with PSoC5.

I suggest not to use WaveDAC at this moment, but to do it simply in code (see example AN2024). WaveDAC is more useful for continuous generation of the Sine, which is not a note (a note is amplitude modulated sine, having rise, decay, sustain and fall).

Also take a look on Theremin project by Tom Minnich

Theremin made with Cypress PSoC - Hackster.io

It runs on PSoC4, so must be closely compatible with PSoC5. It produces continuous sound though (like WaveDAC), but introduces DDS concept of tone tuning.

View solution in original post

0 Likes
Reply
5 Replies
Esteemed Contributor II

The note A is 440Hz. 12 notes make an octave, A' has 880Hz

Next tone from A is A#(or Bb) with a frequency of 440 * 12th root of 2. So you can build or calculate the required frequencies.

Bob

0 Likes
Reply
Anonymous
Not applicable

Thanks for your answer,

I had already set up all my frequency with an external clock and using my wavedac but still don't know how to program it

thank a lot

0 Likes
Reply
Esteemed Contributor II

"I had already set up all my frequency with an external clock"

The WaveDac needs a table with the values to output. So you need to generate a table for each tone. The API WaveDAC8_Wave1Setup(uint8 *WavePtr, uint16 NumberOfSamples) is used to introduce the table. When you cannot provide a table for each tone in flash you will need to compute it in sram.

Bob

0 Likes
Reply
Honored Contributor II

Kevin,

there is old Application Note by Dave Van Ess, which is no longer available on Cypress site. It describes simple piano simulation using PSoC1. You have to re-write the code, as it is not directly compatible with PSoC5.

I suggest not to use WaveDAC at this moment, but to do it simply in code (see example AN2024). WaveDAC is more useful for continuous generation of the Sine, which is not a note (a note is amplitude modulated sine, having rise, decay, sustain and fall).

Also take a look on Theremin project by Tom Minnich

Theremin made with Cypress PSoC - Hackster.io

It runs on PSoC4, so must be closely compatible with PSoC5. It produces continuous sound though (like WaveDAC), but introduces DDS concept of tone tuning.

View solution in original post

0 Likes
Reply
Honored Contributor II

I posted a small piano demo here: Polyphonic piano basic demo using KIT-059 and MIDI Keyboard

It can help you to start.

odissey1

0 Likes
Reply