ArduinoGeneral

Romeo v2 - PWM

userHead Antonio 2014-03-11 07:01:58 3286 Views6 Replies
Hello,

I try a simple project to move my 4WD platform with a TV remote.

The mobile platform is working fine until I integrated the IRremote.h library into my program. Since that, only one motor is working. I make some research and it is a PWM problem as the ATMega328 has only 3 timers, the motors use 2 qnd the IR sensor uses another one. I have let the pin 4,5,6,7 free for the motors. I have my IR Sensor plugged on pin 10 and a LEd plugged on pin 2.
Thank you for help.


2017-04-13 20:31:18 Hi, I have the same problem : a PWM motor stop working.

Here is my remote control :

make_clickable_callback(MAGIC_URL_FULL, ' ', 'https://www.amazon.fr/Infrared-Receiver-Wireless-Control-Arduino/dp/028534286X', '', ' class="postlink"')
The Irremote library:

make_clickable_callback(MAGIC_URL_FULL, ' ', 'https://github.com/z3t0/Arduino-IRremote', '', ' class="postlink"')

which configuration should I use to make this work correctly ?

Thanks in advance
userHeadPic damien.deom
2014-03-12 17:49:53 Hello Antonio,

I haven't actually try your idea, or used the library in a while. If the library requires a timer, you will need to change the pin to some specific timers. If those specific timers conflict with the motor driver / PWM timer you will get some odd behaviour. Not sure if it will affect motors or readings/writtings from the IR. or both.

Does the IR library, writting and receiver work stand alone?
userHeadPic Jose
2014-03-12 16:33:59 Sorry I made a mistake in my schema, the LED is of course not connected to the IR Sensor but to the 5V of the Romeo. What do you mean change the timer? Isn't it just possible to change the pin of the IR sensor?

Thank you
Antonio
userHeadPic Antonio
2014-03-12 11:32:29 Hello Antonio,

You should be able to change the Timer.
If you are not using it, you might be able to just change the timer.
userHeadPic Jose
2014-03-11 18:07:55 I hope you are able to see the pictures I attached in the previous post. Here is attached the schema of my project.
- 1 TV remote
- 1 IR sensor receiving data from the TV remote (seems to use 1 PWM clock)
- 4 motors (2 by 2) (use 2 PWM clock)
- 1 LED that I turn on when I push a button on the TV remote

Hope it helps.
Thank you in advance.
Antonio
userHeadPic Antonio
2014-03-11 14:09:21 Hello Antonio, again
Could attach your sketch?
How do you receive the Data?
A IR receiver?
userHeadPic Grey.CC