Ambitious Project - 16's Digital VU's and 16 Alpha Displays

Discussion in 'The Projects Forum' started by Eric Kubischta, Nov 24, 2014.

  1. Eric Kubischta

    Thread Starter New Member

    Nov 22, 2014
    21
    1
    Hi All - Just joined this forum, and am looking for some direction I guess.

    I am pretty much a newbie with electronics, I am a computer programmer by day, and a below-average musician at night who likes to record.

    I have used a soldering iron, primarily to work on wiring in my guitars (simple circuits)

    Ok - So, let me describe in a nutshell what I want to do, and then provide detail.

    Part 1: Send a digital stream of data for 16 individual "tracks" from a software mixer to a hardware device that will control 16 digital VU meters (LED Bars...probably 10, maybe 20 LED's each). The LED Bars should be logarithmic scaled. This data will stream in realtime during the playback of multi-track audio.

    Part 2: Send data to 16 small (no wider than 25MM) character LCD's - Hopefully support at LEAST 8 characters each. This data will be sent on command and "stay put" except on track layout changes in the software.

    The software I use is a product called "Reaper" which is simply a digital audio mixing software (similar to what Pro Tools does). It is programmable, and I can send realtime data stream from it.

    Whew - ok, here is the research I have done and some questions:

    1. I think maybe I could power the whole thing with an Arduino Mega 2560
    http://arduino.cc/en/Main/ArduinoBoardMega2560

    This seems to have lots of pins for output data and controlling stuff. And, it supports accepting data via USB in serial format. I shouldn't have a problem programming it to receive what I send. (I will likely send a stream of bytes, a few bytes for the control message, and 16 more for the actual values for the LED meters. Same deal on the LCD's)

    2. I have found this chip: LM3916 that seems like is what I need to control a 10 or 20 bar LED array. (It seems you can chain 2 of these together to drive more than 10)

    3. I am a bit lost on how to take my digital data I am receving on the Arduino, and convert it into what seems to be an analog voltage level for the LM3916. Unless I don't understand it correctly.

    4. I cannot find anywhere an LCD that meets my needs for part 2 (at least 8 characters, no more than 25mm wide....Does anything like this exist? - Also - Bonus would be if it would have configurable background color in RGB values

    All of this is going into a custom enclosure I am building to house stripped down 2 "BCF2000" Midi Controllers (Here is what one looks like: http://www.behringer.com/EN/Products/BCF2000.aspx)

    So - imaging that BCF2000 (2 of them side by side) - each with an LCD displaying a "track name" and a LED Bar for the Level Meter. Each track fader occupies an area about an inch wide.

    Anyway - If you have any ideas for me...Let me know. I was hoping I could find a different IC instead of the LM3916 to drive all 16 LED Bar's, because, this seems like a lot of breadboarding and wiring to me eh?

    Thanks again, and ask any questions at all! I am a newbie, but am good at research and willing to learn on my own if pointed in the right direction.

    Eric
     
  2. Papabravo

    Expert

    Feb 24, 2006
    10,136
    1,786
    What is the nature of the digital data? Is SPDIF, FLAC, MP3, TOSLINK or something else?
     
  3. Eric Kubischta

    Thread Starter New Member

    Nov 22, 2014
    21
    1
    Hi Papabravo - To reduce overhead, I wasn't planning on streaming the full audio streams of all 16 tracks.

    This is still all open to ideas, but, I currently have some python code that runs as a process in the background during playback. It reads the peaks of the realtime audio stream of all 16 tracks. I can then send that data over a serial USB connection to the Arduino.

    For example (for simplicity) I might send a stream of 16 bytes like: 5643589704324567 Each byte representing the value (peak) of the audio from each track at that specific instant.

    On the Arduino - I can run a python process that retrieves that data from the serial buffer, and then send signals to whatever "pins" - So I need to somehow get these pins on the Arduino to signal the LED arrays.

    I hope I am making sense!

    Note: I think I can also send the data as a Midi stream of values.

    Eric
     
  4. sirch2

    Well-Known Member

    Jan 21, 2013
    1,008
    351
  5. Eric Kubischta

    Thread Starter New Member

    Nov 22, 2014
    21
    1
    Thanks Sirch2 -

    The 4017 looks like it would work great. Hopefully the speed of my loop across 16 of them will be fast enough to keep the effect going. According to the diagram, I should be able to connect all of the reset pins together so I can issue one reset off of one pin on the Arduino? - This then allows me to run 16 of them with 17 pins?


    Now - on the display - Those OLED's look nice...but a bit pricey. I wonder if I should try to find a wider display - e.g. a using 4, 4-inch wide displays, each of them handling 4 tracks? Each display would have to be no more than 100mm wide and would have to show at least (hopefully) 32 characters

    Eric
     
  6. Papabravo

    Expert

    Feb 24, 2006
    10,136
    1,786
    Didn't know that Arduinos could run Python. Driving LEDs configured as a bargraph can be done in a number of ways. You could drive each LED directly but that would require a large number of pins. Sixteen displays by ten pins each is 160 pins. The alternate technique is called multiplexing. As the number of displays goes up the amount of time that each display is on causes them to appear dim. There are chips you can use that will provide an SPI interface for data that can manage all of the current limiting and multiplexing functions so you can concentrate on your application. You might also have to sacrifice the convenience of an Arduino for the bare metal assembly language programming of the AVR processor used in the Arduino.
     
  7. Eric Kubischta

    Thread Starter New Member

    Nov 22, 2014
    21
    1
  8. bance

    Member

    Aug 11, 2012
    315
    34
    Adafruit have a library to easily drive SPI/I2C oleds on github.

    HTH Steve
     
  9. Eric Kubischta

    Thread Starter New Member

    Nov 22, 2014
    21
    1
    With a Multiplexer - Do you think I can drive 16 of those OLED units from Arduino? - What is the minimum numbers of pins I would need off of the Arduino?
     
  10. sirch2

    Well-Known Member

    Jan 21, 2013
    1,008
    351
    Don't see why not, a 16MHz AVR should be fast enough depending on what else happens in the loop, even in Arduino which I think takes more cycles to write a pin I believe it is only about 8 cycles so around 0.5uS


    That OLED you linked would appear to have SPI and I2C interfaces. These are serial interfaces and so don't need multiplexing, just basically just connect them up in parallel. AFAIK the limit to the number of devices on and I2C/SPI bus is the total capacitance of the circuit so it depends on the length of the wires connecting them and the spec of the devices.

    For I2C each slave (OLED in your case) has an address so you only need two pins for comms, the I2C protocol sends the slave address followed by the data for that slave, other slaves ignore data not addressed to them.

    For SPI each slave has a "Slave Select" pin, so you would need 16 pins on the Arduino to address each of 16 salves.
     
    Last edited: Nov 26, 2014
  11. Eric Kubischta

    Thread Starter New Member

    Nov 22, 2014
    21
    1
    Thanks Sirch2 - That is good news on the I2C protocol.

    I know these are still general questions, but I am just still in the process of seeing if 1: I can make this work, and 2: The costs are worth it (to me anyway)

    I think maybe I will try to draw up a rough diagram next to see how this is going to go together.

    Eric
     
  12. sirch2

    Well-Known Member

    Jan 21, 2013
    1,008
    351
    Good idea, have a look at the Arduino I2C (also called TWI) library as well
     
  13. Eric Kubischta

    Thread Starter New Member

    Nov 22, 2014
    21
    1
    Hi All - I have been doing some more research, and came up with a basic Block Diagram for driving the 16x20 LED array.

    Can you look at the attachment and tell if I am on the right track?

    [​IMG]



    The diagram is based on the circuit diagram I found here, and I modified it a bit:

    http://www.instructables.com/id/Make-a-giant-LED-sign/step8/Make-the-circuit/


    I figure I can control the 2 4017's with 2 output pins on the Arduino and switch between them in a loop in the code on the Arduino.


    Thoughts?

    Thanks,
    Eric
     
  14. Eric Kubischta

    Thread Starter New Member

    Nov 22, 2014
    21
    1
    Any thoughts on this design? - Am I on the right track?

    Thanks,
    Eric
     
  15. MrChips

    Moderator

    Oct 2, 2009
    12,421
    3,356
    Sorry for being late to the party. I would do it differently.
    I would put one microcontroller chip (MCU) for each display to create an independent module. Then network each module with the master MCU using a serial interface, UART, SPI or I2C.
     
  16. Eric Kubischta

    Thread Starter New Member

    Nov 22, 2014
    21
    1
    Thanks MrChips - Any recommendations on an MCU Chip that accepts serial and can drive those leds?

    Eric
     
  17. MrChips

    Moderator

    Oct 2, 2009
    12,421
    3,356
    I would choose a simple MCU that has sufficient output pins for your display (20 in your case) and a UART interface.
    Atmel ATmega8 or ATmega48 come to mind.
     
Loading...