Simple Wave Player with PWM, Lite version.

Dependencies:   mbed

Information

Under construction

/media/uploads/mimi3/wave_player_pwm_lite.jpg http://mpu.up.seesaa.net/image/wave_player_pwm_10bit_nucleo-f030r8-frizing.gif

Description

  • This is a simple wave player application(not library) using PWM ports.
  • This is Lite version.
    (difference from https://developer.mbed.org/users/mimi3/code/wave_player_pwm/)
  • Speed up SD card accsess by modified SDFileSystem library with DMA capability.
  • Only very simple User Interfaces.
  • 32 step digital volume capability. (New feature)
  • Variable speed functionality to play. (Up usability)
  • 10bit PWM resolution quality. (Decent audio quality)
  • Small code size. (About 32K byte)
  • LED indicator while playing music. (New feature / (Inaccurate :D ))
  • Using only passive electric components except SD card.
    ( It is needed only some resisters and capacitors )

Spec.

  • Input data: WAVE file(PCM:*.wav files). ( must be converted by foobar2000)
  • Data length: 16bit, 8bit.
  • fs : ... 32kHz,44.1kHz,48kHz.
  • Channel: Stereo, mono
  • Output data: PWM 10bit resolutuon.
    fs and Channels are the same as input data.

Board

Using Library

Terminal base CUI

UART Terminal (e.g. Tera Term) base operation, /media/uploads/mimi3/wave_player_pwm_lite_cui_terminal.png

Tera Tem settings

  • Serial om port: Baudrate 115200bps.
  • Main Menu - [Setup] - [Terminal] dialog:

New-line settings.

/media/uploads/mimi3/terraterm-new-line-settings.png

Operation

KeyOperationon Playon Pause
p,sPause or Play.PausePlay
., n, SpaceNext song.oo
dPlay slowly 3 step.oo
uPlay rappidly 3 step.oo
0(Zero)Set normal play speed.oo
+,-Digital Volume 32 stepoo
hHelp menu.-o
!Show system information.oo
qQuit player mode.oo

Playing music

Now You can hear the sound from PWM port of mbed board.

Music01: Serenity

Music02: About That Oldie

Music03: Gemini Robot

Download repository: zip gz

Files at revision 0:b5e8059dd716

Name Size Actions
[up]
main.cpp 214 Revisions Annotate
mbed.bld 65 Revisions Annotate