Skip to content

ChuckBland/Music-Display-Head-Node

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 

Repository files navigation

Music-Display-Head-Node

Music Information Source Node

This project is the music source processor that provides the music data to the display nodes via an ad hoc WiFi network.

This system digitizes the music to seven bands of values that range from 0 to 100, plus an average of all seven bands. As is, it reads right and left channels but combines them to one channel of information. It also provides an automatic gain control function using a closed loop algorithm based on an upper and lower threshold of the average number of lights on per audio band.

The values of patter, brightness, squelch, and the softpot are automatically saved in the ESP32 EEPROM and are restored on startup.

The LCD display shows the current AGC level, pattern number, brightness level, softpot, and squelch level.

It uses Infrared Remote control hardware supplied with most every Arduino starter kit.

Here is the system wiring diagram.

image

##Hardware Components used are:

  1. ESP32 WROOM, 38 pin version
  2. MSGEQ7 Seven Band Spectrum Analyzer Breakout Board
  3. 2x16 I2S LCD Display
  4. IR Remote Receiver
  5. IR Remote Control

It is important to note that the MSGEQ7 board can handle up to the levels a typical computer sound system will output. An attenuator will be necessary for any higher speaker level voltages.

##Software The software was written using the Arduino IDE and uses these libraries:

  1. esp_now - included in ESP32 core
  2. WiFi - included in ESP32 core
  3. Preferences - included in ESP32 core
  4. Taskscheduler by Anatoli Arkhipenko (in Arduino IDE)
  5. LiquirCrystal_I2C by Marco Schwartz (in Arduino IDE)
  6. IRSmallDecoder by Luis Carvahalho (in ARduino IDE)

Data packets are sent using the ESP-NOW protocol at around a 50 mS update rate.

The structure of the packet is:

struct struct_message
    {
    byte  packetVersion;
    byte  pattern;
    byte  brightness;
    byte  monoAverage;
    byte  softpot;
    byte  channelData[7];
    }

##IR Remote Key Commands

  • POWER: Display on/off - stops ALL displays
  • PLUS: Increase LED brightness
  • MINUS: Decrease LED brightness
  • NEXT: Increase pattern number (>>| key)
  • PREVIOUS: Decrease pattern number (|<< key)
  • MODE: Display backlight on
  • ZERO: Decrement softpot
  • ONE: Increment softpot
  • TWO: Decrement squelch
  • THREE: Increment squelch

##Debug Output The ESP USB serial output is set to 115200 bps rate. When connected it responds the following commands:

  • 0 - Debug off
  • 1 - Output channel packets
  • 2 - Show remote control key entries

Helpful Resources

While not all this information is directly relevant to the operation of the Music Head node, it does apply to understanding the overall system. It is to your benefit to review the following information.

I HIGHLY Recommend you watch this video to learn the difference between LED Strips. There are many different types and each has their strengths and weaknesses. So watch this video first!

* LED Strips, what's the difference?

You might want help configuring the Arduino IDE to support the ESP32. Check out this tutorial page from Random Nerd Tutorials.

* Setting-up Arduino IDE for ESP32

Once youj've installed ESP32 support in the Arduino IDE, the ESP-NOW and WIFi libraries will be automatically available. Here are some links to helpful technical detail.

* Technical Overview of ESP-NOW

* Getting Started with ESP-NOW

The FastLED library will be a big help to you. Bookmark this site.

* FastLED Library Home

-* FastLED Color Names

Scott Marley has an EXCELLENT YouTube channel filled with tutorials on the FastLED library and some very cool projects. You should take the time to watch these vids from the series, FastLED Basics". Each are shorter than twnety minutes in length.

* FastLED Basics Part 1

* FastLED Basics Part 2

* FastLED Basics Part 3

* FastLED Basics Part 4

* FastLED Basics Part 5

* FastLED Basics Part 6

About

Music Information Source Node

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published