element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Avnet & Tria Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • About Us
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      • Japan
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Vietnam
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
PiCasso Design Challenge
  • Challenges & Projects
  • Design Challenges
  • PiCasso Design Challenge
  • More
  • Cancel
PiCasso Design Challenge
Blog Blog #3: Painting the background, working with the mic
  • Blog
  • Forum
  • Documents
  • Polls
  • Files
  • Events
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
  • Share
  • More
  • Cancel
Group Actions
  • Group RSS
  • More
  • Cancel
Engagement
  • Author Author: jorgy
  • Date Created: 21 Apr 2019 12:07 AM Date Created
  • Views 447 views
  • Likes 8 likes
  • Comments 1 comment
  • picasso
  • picasso design challenge
  • raspberri pi
Related
Recommended

Blog #3: Painting the background, working with the mic

jorgy
jorgy
21 Apr 2019

Painting the background

My most recent work involved painting the watercolor background.   I have chosen Ampersand Aquabord for this in a 22x30" size, as it is firm and will allow me to drill holes for the fiber optics, as well as for mounting the glass in front and the electronics in back.  It is a wonderful surface to use watercolor on as it keeps the colors vivid.  My conundrum is that I need the background to be dark and unobtrusive, but not too dark, as the piece will need to be attractive both during the day and night.  I was going for a neutral gray, and one way that watercolorists make gray is to use a combination of ultramarine blue and a burnt sienna.  One of the attractive qualities of aquabord is that it granulates (separates in to grains) nicely, but in this case the greys break down into the composite blues and browns. I questioned whether this would detract from the overall design, but decided to go with it.

 

I am painting an abstract cross-hatch pattern, as shown here in the first half of the first layer:

image

 

After the second layer:

 

image

 

The fused glass pieces and fiber optics will go in front of this backdrop.

 

The Microphone

Since I am using so many sensors and so many LEDs and fiber optics being driven by LEDs, I may run out of GPIO pins.  Therefore, I didn't want to use a HAT-based microphone, and instead opted to use a USB microphone.   I chose the Adafruit 3367.  The reason for the microphone is to detect ambient sounds coming from the environment and adjust the artwork accordingly.  My hope was to do some basic analysis of the sounds (i.e. "loud conversation" or "empty room" ) using some sort of Fourier transform, but this is going to be too complicated, and my goal the last couple of weeks has been to focus on KISS (Keep It Simple Stupid).  Therefore, my new goal is to simply measure the amplitude of the audio sample and use this loudness factor in determining one input to the artwork algorithms.

 

I am trying to do this in python, and the guide I was using is this:

 

https://makersportal.com/blog/2018/8/23/recording-audio-on-the-raspberry-pi-with-python-and-a-usb-microphone

 

However, it did not go as planned, and I encountered errors:

 

pi@tableau:~ $ lsusb

Bus 001 Device 010: ID 8086:0808 Intel Corp.

Bus 001 Device 004: ID 0424:7800 Standard Microsystems Corp.

Bus 001 Device 003: ID 0424:2514 Standard Microsystems Corp. USB 2.0 Hub

Bus 001 Device 002: ID 0424:2514 Standard Microsystems Corp. USB 2.0 Hub

Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

 

Okay, the microphone is found by the OS, but the python library can't:

 

pi@tableau:~ $ sudo python3

Python 3.5.3 (default, Sep 27 2018, 17:25:39)

[GCC 6.3.0 20170516] on linux

Type "help", "copyright", "credits" or "license" for more information.

>>> import pyaudio

>>> p = pyaudio.PyAudio()

ALSA lib confmisc.c:1281:(snd_func_refer) Unable to find definition 'cards.bcm2835_alsa.pcm.front.0:CARD=0'

ALSA lib conf.c:4528:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory

ALSA lib conf.c:5007:(snd_config_expand) Evaluate error: No such file or directory

ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM front

ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.rear

ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.center_lfe

ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.side

ALSA lib confmisc.c:1281:(snd_func_refer) Unable to find definition 'cards.bcm2835_alsa.pcm.surround51.0:CARD=0'

ALSA lib conf.c:4528:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory

ALSA lib conf.c:5007:(snd_config_expand) Evaluate error: No such file or directory

ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM surround21

ALSA lib confmisc.c:1281:(snd_func_refer) Unable to find definition 'cards.bcm2835_alsa.pcm.surround51.0:CARD=0'

ALSA lib conf.c:4528:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory

ALSA lib conf.c:5007:(snd_config_expand) Evaluate error: No such file or directory

ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM surround21

ALSA lib confmisc.c:1281:(snd_func_refer) Unable to find definition 'cards.bcm2835_alsa.pcm.surround40.0:CARD=0'

ALSA lib conf.c:4528:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory

ALSA lib conf.c:5007:(snd_config_expand) Evaluate error: No such file or directory

ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM surround40

ALSA lib confmisc.c:1281:(snd_func_refer) Unable to find definition 'cards.bcm2835_alsa.pcm.surround51.0:CARD=0'

ALSA lib conf.c:4528:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory

ALSA lib conf.c:5007:(snd_config_expand) Evaluate error: No such file or directory

ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM surround41

ALSA lib confmisc.c:1281:(snd_func_refer) Unable to find definition 'cards.bcm2835_alsa.pcm.surround51.0:CARD=0'

ALSA lib conf.c:4528:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory

ALSA lib conf.c:5007:(snd_config_expand) Evaluate error: No such file or directory

ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM surround50

ALSA lib confmisc.c:1281:(snd_func_refer) Unable to find definition 'cards.bcm2835_alsa.pcm.surround51.0:CARD=0'

ALSA lib conf.c:4528:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory

ALSA lib conf.c:5007:(snd_config_expand) Evaluate error: No such file or directory

ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM surround51

ALSA lib confmisc.c:1281:(snd_func_refer) Unable to find definition 'cards.bcm2835_alsa.pcm.surround71.0:CARD=0'

ALSA lib conf.c:4528:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory

ALSA lib conf.c:5007:(snd_config_expand) Evaluate error: No such file or directory

ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM surround71

ALSA lib confmisc.c:1281:(snd_func_refer) Unable to find definition 'cards.bcm2835_alsa.pcm.iec958.0:CARD=0,AES0=4,AES1=130,AES2=0,AES3=2'

ALSA lib conf.c:4528:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory

ALSA lib conf.c:5007:(snd_config_expand) Evaluate error: No such file or directory

ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM iec958

ALSA lib confmisc.c:1281:(snd_func_refer) Unable to find definition 'cards.bcm2835_alsa.pcm.iec958.0:CARD=0,AES0=4,AES1=130,AES2=0,AES3=2'

ALSA lib conf.c:4528:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory

ALSA lib conf.c:5007:(snd_config_expand) Evaluate error: No such file or directory

ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM spdif

ALSA lib confmisc.c:1281:(snd_func_refer) Unable to find definition 'cards.bcm2835_alsa.pcm.iec958.0:CARD=0,AES0=4,AES1=130,AES2=0,AES3=2'

ALSA lib conf.c:4528:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory

ALSA lib conf.c:5007:(snd_config_expand) Evaluate error: No such file or directory

ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM spdif

ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.hdmi

ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.hdmi

ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.modem

ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.modem

ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.phoneline

ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.phoneline

ALSA lib confmisc.c:1281:(snd_func_refer) Unable to find definition 'defaults.bluealsa.device'

ALSA lib conf.c:4528:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory

ALSA lib conf.c:4996:(snd_config_expand) Args evaluate error: No such file or directory

ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM bluealsa

ALSA lib confmisc.c:1281:(snd_func_refer) Unable to find definition 'defaults.bluealsa.device'

ALSA lib conf.c:4528:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory

ALSA lib conf.c:4996:(snd_config_expand) Args evaluate error: No such file or directory

ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM bluealsa

connect(2) call to /tmp/jack-0/default/jack_0 failed (err=No such file or directory)

attempt to connect to server failed

>>>

 

 

 

So, plenty of work to do!

 

Next, work on the circuits for the motion detectors, and the circuits for the LEDs.

  • Sign in to reply

Top Comments

  • dubbie
    dubbie over 6 years ago +1
    Looks intriguing. Dubbie
Parents
  • dubbie
    dubbie over 6 years ago

    Looks intriguing.

     

    Dubbie

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • More
    • Cancel
Comment
  • dubbie
    dubbie over 6 years ago

    Looks intriguing.

     

    Dubbie

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • More
    • Cancel
Children
No Data
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2025 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube