Coding Problems with Voice recognition module on Uno R3.

Hello Gals and Gents,

I am trying to complete a school project, consisting of 4ea recycle bins. I am using 4 servos (SG92R), together with a Geeetech voice recognition module, 1 green LED and an Arduino Uno R3 board. The basic idea is to open/close the lids of the bins with voice commands controlling the servos.

I am powering the Arduino through the barrel jack, with 1ea 9.9 volts, 2200 mAh battery (LifeP04, 3 cels). The servos are powered through the breadboard by using a DC-DC Buck Converter Step Down Module, the input voltage is adjusted to 5.01 volts. Servos and voice module ground wires are common/shared with Arduino.

I use 2 groups of voice commands. Group 1 is imported during initial boot up and has 4 commands:
"Lets Start" = led turns on and the system sets servos to bins closed position and is ready to roll.
"Goodbye" = led off and the system is unusable.
"Open" = Arms the open cycle and imports Group 2.
"Close" = Arms the close cycle and imports Group 2.

Group 2 consists of 5 voice commands:
"Blue", "Yellow", "Orange" and "Green", different bin lids and "All" which moves all 4 servos.
All Group 2 commands import Group 1 back in the system.

The code is compiled and imported successfully.

I really hope I did not get you tired already. The actual problem I have is that after a few initial commands that work (like "Lets Start"-"Open"- "Blue", I get the servos moving by just the "Open" Or "Close" command. I do not understand why this happens. The whole thing becomes inconsistent. Then the voice command becomes unavailable (blinks fast and is not doing anything). I replaced the voice command to troubleshoot a possible hardware failure but to no help.

If you could please have a look at the code I am using and suggest what can cause this, I would be very grateful. Maybe the voice module is not up to standard?

I attached the code I am using as a file (too long, max. limit exceeded).

Thanks in advance for your time and advice,
EasyBusy. _

sketch_jan04b.ino (11.2 KB)

As soon as you include breadboard and servos in the same project, expect trouble. Breadboards are not meant to carry current necessary to operate a servo let alone several servos.

Paul

Thanks a lot for your reply Paul,

From the information I gathered through the internet, breadboards are commonly rated for five volts at one ampere. And it is probably a bit less on the Chinese stuff I am using . . .

Reading the specs of the servos I use on this project, it says that normal moving current is 100-300 mA, while the measured stall current tops at 650 mA.

Considering I need to move one servo at the time (the all together command was just for fun really, do not need it in the project), I thought I might get away with using a breadboard.

I also believe that the problem I face is code related.

But I will try to use another means of connecting the servos to my 5 volts power supply and I will report back.

Thanks again for your comment.

regards,
EasyBusy. _

Just curios, how well does the voice recognition work? are you happy with it? what module are you using?
It was something i wanted to try out in my project.

I am using the "Geeetech Voice Recognition Module With Microphone", bought from Banggood, China.

I have tried 2 identical units so far, I mean it is OK, but it creates glitches sometimes.
The microphone that comes with it is not very good (3.5mm mono-channel microphone), but this module has a pin interface where you can solder a mike on it.

You will need a 5V TTL level UART interface module to connect it via USB to a PC and train/upload the commands.

Kindly find attached the instructions manual for the module in question.

All in all, for the 17 odd dollars it costs it is not that bad. But it often creates problems and voice recognition is not 100% accurate. I suppose you get what you paid for.

regards,
EasyBusy. _

User Manual.pdf (604 KB)

I removed the breadboard and did some soldering on an old PCB board with jumper wires. The problem is always there. Not a breadboard problem.

I think the problem is that half of the times I try to switch command groups on the voice recognition module, it fails to complete the switching. I believe that, because if I use simpler coding, where it does not require to import another group of voice commands, everything works fine. The problem with that is, I can only effectively use one group of commands and that is limited to only 5 different commands.

I am running out of ideas.

regards,
EasyBusy. _