Show Posts
Pages: [1] 2
1  Using Arduino / Project Guidance / Audio spectrum analysis all in Software on: April 10, 2014, 03:55:11 pm
I want to analyse the spectrum of an audio input with FFT.

First of all, I want to done everything with software. That's to say, there won't be any spectrum analyzer IC or signal input through Hardware.

What I need to know is, how to get the audio signal as input while I am also playing the sound on computer. So, what I want to achieve is simply playing a song on PC and get this as input to arduino software to be able to process it simultaneously and send this data to analog outputs to be able to visualize them through LEDs.

1- How can I get the audio signal ?
2- Is there any "straight forward" FFT code to use easily. Asking cause I am not good at signal processing. ( Using an IC instead is not an option for me, since me to get one takes weeks due to shipping)

Thanks in advance.
2  Using Arduino / Programming Questions / Re: Arduino interacting with computer application on: March 23, 2014, 02:53:59 pm
If you read up on Serial, this is what you want.  Here's the Serial.write reference

http://arduino.cc/en/Serial/write

Once the comm port on the PC recieves the message, you can do what you like with it.  I've used Flash bu there's simpler/free ways, most folks use Processing or LabView I believe.

You can also send the event wireless from the Arduino using an XBee (or BT),  with a USB-XBee adaptor hanging off the PC.

Carl

Thanks for your answer.

So, how can I read this data from the interface of arduino. I mean how can I connect the software I wrote.
That kinda confuses me. What I want is playing some .wav files accordingly.
3  Using Arduino / Programming Questions / Arduino interacting with computer application on: March 23, 2014, 02:25:38 pm
Not sure if this one fits this forum but found that the most adequate.

My question is; I want to take a input signal from arduino (through a force sensor) and by using this input I want to control a program on the computer. Imagine there is a push button, when I press it, on the app screen where will happen something.

I don't know how this connection between arduino and computer application is made.

Appreciate if you inform me further.
4  Using Arduino / Project Guidance / Digital instrument idea on: March 21, 2014, 03:26:13 pm
Planning to build a digital instrument which will play a certain .waw files in accordance with the data coming from pressure sensor.

My question is, how can I store theses .waw files ?

This project will not be connected to a computer, it will be portable. So, somehow I have to store the sound files.
Since I have never tried such thing, have no idea how can I achieve it.
Appreciate if you guide me.

Thank you
5  Using Arduino / Project Guidance / Re: Driving multiple leds on: January 31, 2014, 02:42:33 pm
Thanks so much for your answer.

One more thing;

Let's say I'l be driving 25*7 = 175 LEDs,

With the array I got from spectrum analyzer, which is size of 7, I need to create another array with size of 175. Then I need to load this to 22 shift registers and then release the parallel data. This will be done over and over again, very quickly, since the LEDs have to be synced with the audio.

Would I experience any time delay between the actual serial data and its representation on LEDs ?

Thank you again.

Yes, you are ok just using some 74HC595 shift registers to drive LEDs. Have proper resistors to limit the current. These shift registers are meant to drive signal lines, not high-power LEDs. You may chain them into a good length. Just make sure you wait long enough between shifting out the last bit and latching the values out. It takes time to propagate the bits to the last shift register. If you see your last few LEDs always lit or blinking and not doing what they should do, that is when you latch out the values too soon. The LED driver from sparkfun probably has current limitation built in and needs no resistors. Here is a cheap source of the 595s

http://www.dipmicro.com/store/74HC595
Shipping coupon:

https://www.dipmicro.com/coupon?A9Y1

Compared with sparkfun price:

https://www.sparkfun.com/products/733
6  Using Arduino / Project Guidance / Driving multiple leds on: January 31, 2014, 02:25:32 pm
I'm planning to read an audio signal and analyze its frequency spectrum with MSGEQ7 Integrated Circuit.

This IC will give me a serial analog data. Then in accordance with the value of each analog data in the array with size of 7, I will drive certain numbers of LEDs at the same time.

Since I'm not familiar with shift register I'm not sure if it is suitable for such purpose ?
I have another option, which is; LED Display Driver (8-Digit) - MAX7219CNG from sparkfun;

https://www.sparkfun.com/products/9622

It's quite a bit expensive though.

So, would I be fine with cascaded shift register ?
7  Using Arduino / Project Guidance / Building Arduino on PCB on: January 17, 2014, 06:06:35 pm
I don't know if this is discussed before (Probably has been) but I couldn't find any document, that's why I am asking.

I want to build a PCB and when I place the processor on it, it will work as arduino. To do so, I need to combine some components like crystal clock, capacitor and stuff like that but don't know what I exactly have to do. Is there a guideline for this ?

Thank you.
8  Using Arduino / Project Guidance / Audio spectrum with leds on: January 04, 2014, 04:31:59 pm
For a while I've been searching about that project.

Planning to build something like that;


Apparently what I need is MSGEQ7 chip for analyzing the spectrum in 7 different range;
A demultiplexer, since I'll need a lot of output to run many LEDs;

One more thing that I need is having the audio signal in. I don't know what this input socket for 3.5mm jack is called but I believe there must be a type of component to place on breadboard, right ?

Basic components aside, do you think I might need any other specific component or do you suggest any thing before I start ?

Thank you.


9  Using Arduino / General Electronics / Driving a transformer on: April 13, 2013, 06:30:50 pm
Just wrote down a basic square wave to drive the transformer which is 230V AC input and 11V AC output.
This was a transformer extracted from a Guitar amplifier.
Connected the arduino from 11V side and expected to see at least half of the 230 V (If I'm not mistaken arduino supplies around 3V, right)

However when I touched the LED to 230 V side of the transformer, LED was barely blinking with a pale light.

What might be wrong with this ? Why the voltage drops even under the 5V when it passed through the transformer ?

Quote
 digitalWrite(led, HIGH);
  delay(20);      
  digitalWrite(led, LOW);  
  delay(20);
10  Using Arduino / Programming Questions / Re: Interrupting IF statement on: March 02, 2013, 12:28:54 pm
int check()
{
  if(digitalRead(9) == LOW)
  {
    return 0;
  }
}

this is the function and calling this function by writing down check(); statement whenever I want to check the condition to interrupt the if statement would work I think.
Don't have the board with me, so can't test. But this is my idea.
11  Using Arduino / Programming Questions / Interrupting IF statement on: March 02, 2013, 12:15:52 pm
Assume somewhere in the middle of the if statement, upon an input, I want to interrupt it.
How can I handle this ?



12  Using Arduino / Project Guidance / Re: AC for running the transformer on: February 14, 2013, 03:43:02 pm
Actually I have a circuit built on a matrix board working with 555 timer to get a square wave, however couldn't get it worked.
Thought programming the arduino on computer to get an AC current , but apparently not that easy to do.

Have a 230V to 11V transformer. Want to run it to have a spark gap.
First thought creating an Sine Wave would be easy with arduino but apparently not that easy.

Just a couple of thoughts here... first, don't use "normal" transformers this way. They're not very good at it. If you want a spark gap, use a high-frequency ferrite core transformer, like the baby flybacks you find in plasma globes. You may get a painful shock/small burn if you're not careful, but you're quite unlikely to die unless you decide to experiment with it naked covered in salt water.... so don't do that :p

Also, don't throw a microcontroller at a project that doesn't need one. It'd be easy enough to knock together a 555-based oscillator with some big fat power transistors to make an appropriate driver circuit, and a lot less hassle if you burn something out. Google "flyback driver 555" for some ideas, it's not difficult. You can vary the output voltage by varying the duty cycle of the 555 oscillator.
13  Using Arduino / Project Guidance / AC for running the transformer on: February 14, 2013, 01:47:05 pm
Have a 230V to 11V transformer. Want to run it to have a spark gap.
First thought creating an Sine Wave would be easy with arduino but apparently not that easy.

Idea is quite simple but the value I monitor fluctuates around 280 rather than going all the way up to 255 and then falling to 0 in a loop
Quote
int out = 9;
int i=0;

void setup()
{
  pinMode(out, OUTPUT);
  Serial.begin(9600);
}

void loop()
{
  for(i;i<256;i++)
  {
    analogWrite(out, i);
    Serial.println(analogRead(out));
  }
  for(i;i>-1;i--)
  {
    analogWrite(out, i);
    Serial.println(analogRead(out));
  }
}
14  Using Arduino / Programming Questions / Re: Get the push button sense once on: February 09, 2013, 04:04:42 pm
1
11
111

at 1 press. Very snappy :/
What can I do ?
15  Using Arduino / Programming Questions / Re: Get the push button sense once on: February 09, 2013, 03:10:34 pm
Seems pretty logical but doesn't work.
I've implemented more or less a similar solution but it didn't work either. Strange


You must make a variable that holds the state of the button. Only if the state changes there is action

something like this
Code:

int pressed = 0;

void loop()
{
  if (digitalRead(b1) == LOW && pressed == 0)
  {
    pressed = 1;
    pass += "1";
    counter++;
  }
  if (digitalRead(b1) == HIGH && pressed == 1)
  {
    pressed = 0;
  }
}

give it a try

Pages: [1] 2