WiShield disconnects when I press any buttons in the app.

56 views
Skip to first unread message

Brian Williams

unread,
Jul 30, 2012, 1:13:52 AM7/30/12
to rc...@googlegroups.com
Hi,

I have a problem with the wifi connection. I can create an ad hoc connection between the Arduino and the iPhone, and I can see that I'm connected in the app, but whenever I press some or any buttons in the app, I get the disconnected. Basically, I get the "NO CONNECT" message.

Here is my configuration:
I bought my Arduino board and shields from a company called WebUrban. I bought their Arduino clone (I think it's a clone of Duemilanove") + their USB connector module and their WiFi module. The WiFi module is based on the WiShield, and the WiShield library works with no problem. Then, I connected a servo to a breadboard, and I connected the breadboard to the pins "5v", "GND", and then for the 3rd wire I tried different digital pins from 0 to 9. However, once I start pressing buttons in the app, I get disconnected and then I have to unplug my arduino and plug it back on.


Do you think I get this problem because I don't have a Motor Driver Shield? On what pins would you recommend connecting the servo?


In the libraries folder, I have the following libraries that I've downloaded from your website:
RCKit
AccelStepper
WiShield

I just copied them there without making any modifications, and then I've compiled and uploaded them to the Arduino without having any problems. Then, I've followed your instructions and assigned the iPhone a static connection.


I really believe that it disconnects because of the servo connection. I remember when I tried a few weeks ago to control a servo using the WiShield's SimpleServer example, I could control the servo moving in one direction from the website, but as soon as I tried changing direction, the page would appear loading forever and I would get disconnected.

Please help me. I've spent countless hours troubleshooting this and I'm stuck.


Thank you very much,

Brian

Mike McCauley

unread,
Jul 30, 2012, 2:39:03 AM7/30/12
to rc...@googlegroups.com
Hi Brian,

On Sunday, July 29, 2012 10:13:52 PM Brian Williams wrote:
> Hi,
>
> I have a problem with the wifi connection. I can create an ad hoc
> connection between the Arduino and the iPhone, and I can see that I'm
> connected in the app, but whenever I press some or any buttons in the app,
> I get the disconnected. Basically, I get the "NO CONNECT" message.

After that, does your iphone Settings show that the wi-fi connection is still
connected or not?

>
> Here is my configuration:
> I bought my Arduino board and shields from a company called WebUrban. I
> bought their Arduino clone (I think it's a clone of Duemilanove") + their
> USB connector module and their WiFi module. The WiFi module is based on the
> WiShield, and the WiShield library works with no problem. Then, I connected
> a servo to a breadboard, and I connected the breadboard to the pins "5v",
> "GND", and then for the 3rd wire I tried different digital pins from 0 to
> 9. However, once I start pressing buttons in the app, I get disconnected
> and then I have to unplug my arduino and plug it back on.

Does it still disconnect when the servo is not connected
>
>
> Do you think I get this problem because I don't have a Motor Driver Shield?
> On what pins would you recommend connecting the servo?

Shouldnt really matter. I often use 3 and 4.

>
>
> In the libraries folder, I have the following libraries that I've
> downloaded from your website:
> RCKit
> AccelStepper
> WiShield
>
> I just copied them there without making any modifications, and then I've
> compiled and uploaded them to the Arduino without having any problems.
> Then, I've followed your instructions and assigned the iPhone a static
> connection.
>
>
> I really believe that it disconnects because of the servo connection. I
> remember when I tried a few weeks ago to control a servo using the
> WiShield's SimpleServer example, I could control the servo moving in one
> direction from the website, but as soon as I tried changing direction, the
> page would appear loading forever and I would get disconnected.
>
> Please help me. I've spent countless hours troubleshooting this and I'm
> stuck.

Is it possible the current drawn by your servo is making the arduino voltage
drop enough to reset it?

Cheers.

>
>
> Thank you very much,
>
> Brian
--
Mike McCauley mi...@open.com.au
Open System Consultants Pty. Ltd
9 Bulbul Place Currumbin Waters QLD 4223 Australia http://www.open.com.au
Phone +61 7 5598-7474 Fax +61 7 5598-7070

Radiator: the most portable, flexible and configurable RADIUS server
anywhere. SQL, proxy, DBM, files, LDAP, NIS+, password, NT, Emerald,
Platypus, Freeside, TACACS+, PAM, external, Active Directory, EAP, TLS,
TTLS, PEAP, TNC, WiMAX, RSA, Vasco, Yubikey, MOTP, HOTP, TOTP,
DIAMETER etc. Full source on Unix, Windows, MacOSX, Solaris, VMS, NetWare etc.

Brian Williams

unread,
Jul 30, 2012, 3:27:15 AM7/30/12
to rc...@googlegroups.com
Wow, thank you Mike for such prompt reply.

So, after I got the NO CONNECT message, I went to check the settings, and I don't see the "RCArduino" network anymore. This is why I have to turn off the Arduino and turn it on again, so that the network reappears.

I unplugged the servo completely from the Arduino, and I could play with both Joystick controllers and the buttons for Ch5 to Ch9. However, as soon as I press the Ch4 button, I get NO CONNECT. I must mention that sometimes a similar thing happened when I had the servo plugged in. It all dependent on which digital pin I plugged the 3rd wire.

I've also thought that the current drawn by the servo could make the Arduino voltage drop enough to reset it. I remember the first time I received my clone, it had the jumper placed on 3.3 v, so the WiFi module wasn't activating. Now the jumper is on 5v and the WiFi module works, but I still think 5v is not enough for the clone + wifi + servo. If this is the problem, would there be anything I could do to increase the voltage?


Thank you again,

Brian

Mike McCauley

unread,
Jul 30, 2012, 3:43:15 AM7/30/12
to rc...@googlegroups.com
Hi Brian,

On Monday, July 30, 2012 12:27:15 AM Brian Williams wrote:
> Wow, thank you Mike for such prompt reply.
>
> So, after I got the NO CONNECT message, I went to check the settings, and I
> don't see the "RCArduino" network anymore. This is why I have to turn off
> the Arduino and turn it on again, so that the network reappears.
>
> I unplugged the servo completely from the Arduino, and I could play with
> both Joystick controllers and the buttons for Ch5 to Ch9. However, as soon
> as I press the Ch4 button, I get NO CONNECT. I must mention that sometimes
> a similar thing happened when I had the servo plugged in. It all dependent
> on which digital pin I plugged the 3rd wire.

Hmmm, puzzling.

>
> I've also thought that the current drawn by the servo could make the
> Arduino voltage drop enough to reset it. I remember the first time I
> received my clone, it had the jumper placed on 3.3 v, so the WiFi module
> wasn't activating. Now the jumper is on 5v and the WiFi module works, but I
> still think 5v is not enough for the clone + wifi + servo. If this is the
> problem, would there be anything I could do to increase the voltage?

Maybe run it from an external battery instead of USB?

Brian Williams

unread,
Jul 30, 2012, 3:48:07 AM7/30/12
to rc...@googlegroups.com
k, I will report back in a few minutes. I'm not sure if this matters, but the example loaded on the Arduino is the RCRx, not TestSuite or others.

Brian Williams

unread,
Jul 30, 2012, 4:23:57 AM7/30/12
to rc...@googlegroups.com
Ok, I made the servo work for about 15 seconds using the left Joystick. Here's what I did:

I plugged a used (maybe 50%; I will buy a new one tomorrow) 9v battery into the Arduino. By itself, it wasn't enough, because as soon as I started pressing any buttons in the app, I would get NO CONNECT.  Therefore, I also plugged in the USB cable. Then, in the app, I started playing with the Joystick, and the servo was moving as I was directing it. After about 12 seconds or so, the voltage in the app dropped to 4.8v. Then, I got NO CONNECT.

Could the voltage be the problem? If I may ask, what voltage does your app display when you use it?

Mike McCauley

unread,
Jul 30, 2012, 5:54:58 AM7/30/12
to rc...@googlegroups.com
On Monday, July 30, 2012 01:23:57 AM Brian Williams wrote:
> Ok, I made the servo work for about 15 seconds using the left Joystick.
> Here's what I did:
>
> I plugged a used (maybe 50%; I will buy a new one tomorrow) 9v battery into
> the Arduino. By itself, it wasn't enough, because as soon as I started
> pressing any buttons in the app, I would get NO CONNECT. Therefore, I also
> plugged in the USB cable. Then, in the app, I started playing with the
> Joystick, and the servo was moving as I was directing it. After about 12
> seconds or so, the voltage in the app dropped to 4.8v. Then, I got NO
> CONNECT.
>
> Could the voltage be the problem? If I may ask, what voltage does your app
> display when you use it?

5.0V

Another possibility is electrical noise from your servo?

Cheers.

Brian Williams

unread,
Jul 30, 2012, 7:14:14 AM7/30/12
to rc...@googlegroups.com
I've been researching some more since my last reply, and I think the problem is due to the power source. Based on what I've read, a lot of people have problems using servos with Arduinos, and most of these problems are because of power. From my findings, in order to make the servos work correctly, I should power the Arduino board by USB or a 9V battery, and the servo by a pack of 4 AA batteries. I will also get a different servo tomorrow... As you mentioned, the servo might create electrical noise.

If this doesn't fix the problem, then I guess I'll have to buy the exact components you use in your Youtube examples, and make my own WiShield board based on the schematics.

I will post my results tomorrow.

Brian Williams

unread,
Jul 31, 2012, 2:18:47 AM7/31/12
to rc...@googlegroups.com
Alright, I'm happily announcing that I finally made the servo work and be stable!

The problem was in the power supply (the batteries to be more exactly). All I had to do was connect the servo to 4 AA batteries, and the Arduino + USB + WiFi modules to a 9V battery. The app now works like a charm.

The only problem that still remains is the Ch4 button. For an unknown reason, every time I press it, I get NO CONNECT after about 1 second. Perhaps if I had a horn attached for channel 4, it would stop displaying NO CONNECT. After searching your source code for "Channel 4" I found:
         The switches set channels 4 through 9 inclusive. The one connected to channel 4 is momentary contact.
         /// 1 Digital output (horn) (receiver channel 4)
        
So this is how Ch4 is different from the others: it is for digital output.

In any case, my friend will contact you will contact you soon with a request to license your app.
Reply all
Reply to author
Forward
0 new messages