My little place on the web

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
projects:spectrumanaliser:step1_hardware [2012/05/06 10:11]
elger
projects:spectrumanaliser:step1_hardware [2016/11/16 13:06] (current)
Line 1: Line 1:
-**UNDER CONSTRUCTION** 
- 
 ====== Spectrumanaliser Hardware ====== ====== Spectrumanaliser Hardware ======
  
-There are four hardware components in my spectrumanaliser project;+There are four hardware components in my [[projects:​spectrumanaliser|spectrumanaliser project]];
   * Power-supply   * Power-supply
   * Opamp   * Opamp
Line 16: Line 14:
 Usually I would not mention this separately but there is one important thing to know about powering this project. Usually I would not mention this separately but there is one important thing to know about powering this project.
 {{ :​projects:​spectrumanaliser:​spectrumanaliser_powersupply.jpg?​200|}} {{ :​projects:​spectrumanaliser:​spectrumanaliser_powersupply.jpg?​200|}}
-The Opamp (audio amplifier) is very sensitive. If there is a lot of noise on the power-supply then the opamp. So the best thing to prevent interference from the display on the audio signal is to have one power source for the Arduino ​and opamp, and another one for only the display. +The Opamp (audio amplifier) is very sensitive. If there is a lot of noise on the power supply then the opamp will pick up this interference. So the best thing to do, to prevent interference from the display on the audio signalis to have one power source for the Arduino ​opamp, and another one for only the display. 
-The Ground (0 Volt line) of both supplies must be connected (of course).+The Ground (0 Volt line) of both supplies must be connected (of course) ​so the 5V level of both supplies are the same 5V above ground. If you do not connect the ground together, you will get two "​floating"​ 5V lines. Both are 5V but what level is the one 5V relative to the other 5V? This is why you must join the ground lines to each other.
  
-I simply made two 7805 circuits and joined the GND together.+I simply made two 7805 circuits and joined the ground ​together.
  
 ===== Opamp ===== ===== Opamp =====
 {{:​projects:​spectrumanaliser:​spectrumanaliser_opamp.jpg?​200 |}} {{:​projects:​spectrumanaliser:​spectrumanaliser_opamp.jpg?​200 |}}
 {{ :​projects:​spectrumanaliser:​lm386_opamp_schematic.png?​200|}} {{ :​projects:​spectrumanaliser:​lm386_opamp_schematic.png?​200|}}
-The opamp is based on a LM386. This is a very standard opamp that (also) works on 5 Volt. There is one thing to consider, the ADC (Analog to Digital Converter) on the Arduino can read 0V to 5V, but no negative values. So the output on pin1 of JP4 (see schematic) is 2.5V insilence, and sound can produce up to 0V to 5V. And this is exactly what is usefull ​for the Arduino. On regular ​adio projects you would like the AC (-2.5V to 2.5V) signal; this comes out of pin2 of JP4 (see schematic).+The opamp is based on a LM386. This is a very standard opamp that (also) works on 5 Volt. There is one thing to consider, the ADC (Analog to Digital Converter) on the Arduino can read 0V to 5V, but no negative values. So the output on pin1 of JP4 (see schematic) is 2.5V in silence, and sound can produce up to 0V to 5V. And this is exactly what is useful ​for the Arduino. On regular ​audio projects you would like the AC (-2.5V to 2.5V) signal; this comes out of pin2 of JP4 (see schematic).
  
 The input for this opamp can be a ecectret condensor microphone, but if you adjust the pot, you can also use a line-in signal from a music-player. The input for this opamp can be a ecectret condensor microphone, but if you adjust the pot, you can also use a line-in signal from a music-player.
Line 30: Line 28:
  
 ===== Arduino (clone) ===== ===== Arduino (clone) =====
-{{ :​projects:​spectrumanaliser:​spectrumanaliser_arduino_uno_portb.jpg?​200|}} +{{:​projects:​spectrumanaliser:​spectrumanaliser_arduino_uno_portb.jpg?​200 |}}
-This should speak for its self, I used a Atmega328P based Arduino (a.k.a. Arduino UNO). And the clone I have works just as well. Actually, the clone board has the "​portb"​ marked much clearer so finding the right pins was much easier.+
 {{ :​projects:​spectrumanaliser:​spectrumanaliser_arduino_clone_portb.jpg?​200|}} {{ :​projects:​spectrumanaliser:​spectrumanaliser_arduino_clone_portb.jpg?​200|}}
 +This should speak for its self, I used a Atmega328P based Arduino (a.k.a. Arduino UNO). And the clone I have works just as well. 
 +The library for driving the LED display actually addresses a "​port"​ on the Arduino, so you need to find out where "​portb"​ is. In some other page I will describe the software and the libraries I used, you will see the "​portb"​ there again.
 +Actually, the clone board has the "​portb"​ marked much clearer so finding the right pins was much easier.
 +
 +
 +===== Display =====
 +
 +{{:​projects:​spectrumanaliser:​spectrumanaliser_display_overview.jpg?​200 |}}
 +{{ :​projects:​spectrumanaliser:​spectrumanaliser_detail.jpg?​200|}}
 +For the LED display, I used two of the Sure Electronics DE-DP14211 bi-colour (red-green) 16*32 5mm LED displays. Giving me a total of 16*64 LEDs. This is very practical as there are 2^6 (two to the power of 6) = 64 channels that I calculate using the (fast) Fourier transformations.
 +This display shares the ground (0 Volt line) with the Arduino, but it is on its own 5V power supply. This is because, ones the display it operating, there is some distortion on the power supply. This will interfere with the opamp. So just give the display its own power supply and there are no worries about that.