Go Down

Topic: iPhone auxiliary into Arduino with FFT to control motors (Read 674 times) previous topic - next topic

mabo1008

Hello, I am new to this forum and was working on an engineering project and needed some help. I am currently running the project off of a Teensy 3.6, which uses Arduino Software and code to run. The plan here is to have an iPhone (or any device) connect to an axillary port, which will then connect to the teensy through its analog input, the teensy will then take that input data and do a FFT on the data, then the teensy will send a PWM to a voltage regulator, which will then run these motors at different voltages to simulate the beat of the song to the motors. My main question is this, how can I take the iPhone data and input it into the teensy using the axially port on the iPhone / will this even work? I linked below my circuit diagram for further insight.

Grumpy_Mike

Your diodes are the wrong way round they will short out the supply as you have them.

Quote
the teensy will send a PWM to a voltage regulator,
No that should not happen. Luckily your schematic shows no such thing.

Quote
which will then run these motors at different voltages to simulate the beat of the song to the motors
Not sure this will give you that result, my feeling is the motor's will just be a random mess.

MarkT

How much current do these motors take?  2 motors per transistor seems risky.  Also the 330 ohm base resistors are probably too large.
[ I DO NOT respond to personal messages, I WILL delete them unread, use the forum please ]

mabo1008

Your diodes are the wrong way round they will short out the supply as you have them.
No that should not happen. Luckily your schematic shows no such thing.
Not sure this will give you that result, my feeling is the motor's will just be a random mess.
So what I'm getting from this is to flip the diodes. The project has to work its for my final grade in my class. I've been testing the mat and it will be possible for it to simulate the song running the motors at different volts making higher or lower frequency vibrations. The mat will be played alongside music so the user will feel the music as they hear it. It may not be perfectly to the beat, but as long as the user somewhat feels the song it is a success.

How much current do these motors take?  2 motors per transistor seems risky.  Also the 330 ohm base resistors are probably too large.
The motors take .3 amps each.

Grumpy_Mike

Quote
So what I'm getting from this is to flip the diodes.
Yes.

Quote
The project has to work its for my final grade in my class.
Sadly physics is notoriously indifferent to human desires.

Quote
I've been testing the mat
What is "the mat", remember you know what is in your mind, we only know what you have told us.

Quote
The motors take .3 amps each.
That is probably when running. You need to know the stall current. To find this, measure the resistance of the motor and use ohms law to work out the current for any voltage you apply.

mabo1008

That is probably when running. You need to know the stall current. To find this, measure the resistance of the motor and use ohms law to work out the current for any voltage you apply.
I measured the sitting resistance, the motors have a resistance of 11.5 ohms at stall. Using ohms law, I want the voltages of the motors to range from 6 volts to 12 volts, so I would then change send different currents to the motors in order to simulate different vibrations, I would send anywhere between .52173913 to 1.04347 amps to the motors. To change the amount of amps the motors will get, this will be done within the code and through the use of the transistors in my circuit correct?

Grumpy_Mike

Quote
To change the amount of amps the motors will get, this will be done within the code and through the use of the transistors in my circuit correct?
You can not do that with the circuit you have.

You have 2 motors so you have to double the current that one will take. At 2A you should use a logic level FET not a bipolar transistor. You will need a 12 power supply and you control the speed by using PWM. You do not supply a smaller voltage, all the motor speed can be done with the PWM duty cycle.

Go Up