ADC board for Raspberry PI 3

An ADC board with the device PCM1808, a 24-bit 96kHz stereo analog-to-digital converter.

http://select.marutsu.co.jp/list/detail.php?id=258

pi@raspberrypi:~ $ arecord -l
**** List of CAPTURE Hardware Devices ****
card 0: sndrpipcm1808ad [snd_rpi_pcm1808_adc], device 0: PCM1808 ADC HiFi pcm1808-dai-0 []
  Subdevices: 1/1
  Subdevice #0: subdevice #0

pi@raspberrypi:~ $ arecord -vD hw:0,0 -c 2 -d 60 -r 96000 -f S16_LE test96.wav
Recording WAVE 'test96.wav' : Signed 16 bit Little Endian, Rate 96000 Hz, Stereo
Hardware PCM card 0 'snd_rpi_pcm1808_adc' device 0 subdevice 0

LilyPond (2)

You can debug your source code by playing a MIDI file generated by LilyPond. Just insert a \midi block inside a \score block.

\score {
  \new StaffGroup <<
    \new Staff << \global \violineOne >>
    \new Staff << \global \violineTwo >>
  >>
  \layout { }
  \midi {
    \tempo 2 = 90
  }
}

LilyPond

LilyPond is a program for music engraving.

Let’s see how it works. Here is the source code, which you can decipher rather easily. It took me about five minutes to write this down.

\version "2.18.2"
\header{
  title = "Sinfonie in g"
}

global = {
  \tempo "Molto Allegro"
  \time 2/2
  \key g \minor
}

violineOne = \new Voice \relative g''{
  \set Staff.instrumentName = #"Violin 1 "

  \clef "treble"
  r2 r4 ees8(\p d) d4 ees8( d) d4 ees8( d) d4( bes')
  r4 bes8( a) g4 g8( f) ees4 ees8( d) c4 c
  r4 d8( c)
}

violineTwo = \new Voice \relative g'{
  \set Staff.instrumentName = #"Violin 2 "

  \clef "treble"
  r2 r4 ees8(\p d) d4 ees8( d) d4 ees8( d) d4( bes')
  r4 bes8( a) g4 g8( f) ees4 ees8( d) c4 c
  r4 d8( c)
}

\score {
  \new StaffGroup <<
    \new Staff << \global \violineOne >>
    \new Staff << \global \violineTwo >>
  >>
  \layout { }
}

You save the source file and compile it to get the pdf file. VoilĂ !

Raspberry PI and pigpio library (2)

A shell command, pigs, is provided to control the GPIO.

pi@raspberrypi:~/Zpigpio $ sudo pigpiod

pi@raspberrypi:~/Zpigpio $ pigs w 4 1
pi@raspberrypi:~/Zpigpio $ pigs r 4
1
pi@raspberrypi:~/Zpigpio $ pigs w 4 0
pi@raspberrypi:~/Zpigpio $ pigs r 4
0