Netduino - WiFi - Project Showcase - Netduino Forums
   
Netduino home hardware projects downloads community

Jump to content


The Netduino forums have been replaced by new forums at community.wildernesslabs.co. This site has been preserved for archival purposes only and the ability to make new accounts or posts has been turned off.
Photo

Netduino - WiFi


  • Please log in to reply
44 replies to this topic

#1 monewwq1

monewwq1

    Advanced Member

  • Members
  • PipPipPip
  • 104 posts

Posted 22 July 2011 - 12:49 AM

I bought a Netduino Plus but decided I really need to go wireless, so I picked up a Gainspan WiFi breakout board from Sparkfun (http://www.sparkfun.com/products/10505) and after some fiddling with the AT commands, I was able to get a WiFi connection going.

#2 Stefan

Stefan

    Moderator

  • Members
  • PipPipPip
  • 1965 posts
  • LocationBreda, the Netherlands

Posted 22 July 2011 - 07:58 AM

Nice NickDuino! Any chance to see the actual code? I know a lot of community members (me included) would love to play with Wifi :)
"Fact that I'm a moderator doesn't make me an expert in things." Stefan, the eternal newb!
My .NETMF projects: .NETMF Toolbox / Gadgeteer Light / Some PCB designs

#3 Chris Walker

Chris Walker

    Secret Labs Staff

  • Moderators
  • 7767 posts
  • LocationNew York, NY

Posted 22 July 2011 - 01:36 PM

I'll second that!

#4 monewwq1

monewwq1

    Advanced Member

  • Members
  • PipPipPip
  • 104 posts

Posted 22 July 2011 - 07:14 PM

Yes, no problem. I will post the code in a few hours this weekend. I'll provide some details on how to connect it as well.

#5 monewwq1

monewwq1

    Advanced Member

  • Members
  • PipPipPip
  • 104 posts

Posted 23 July 2011 - 03:18 AM

Hi all,

The project files are attached. There are comments in the project indicating how to connect the Gainspan module to the Netduino. The code contains very little error handling, as this is currently in the experimental stage.

Here are links to the documents I consulted to put this together:



#6 monewwq1

monewwq1

    Advanced Member

  • Members
  • PipPipPip
  • 104 posts

Posted 24 July 2011 - 12:01 AM

Hi, I re-factored the code today. There were issues with the DataReceived event and commands processed way too slowly. Now the commands are near-instantaneous to respond. This also adds the ability for multiple clients to control the LED, and I also added a small PC fan to the circuit, controllable via one of the PWM outputs on the Netduino Plus. The code update is attached.

#7 Stefan

Stefan

    Moderator

  • Members
  • PipPipPip
  • 1965 posts
  • LocationBreda, the Netherlands

Posted 24 July 2011 - 08:43 AM

Very nice, just added an item to my sparkfun wishlist :D
"Fact that I'm a moderator doesn't make me an expert in things." Stefan, the eternal newb!
My .NETMF projects: .NETMF Toolbox / Gadgeteer Light / Some PCB designs

#8 Goat

Goat

    New Member

  • Members
  • Pip
  • 3 posts

Posted 25 July 2011 - 01:05 AM

I was just looking for something like that... Thanks for the tip!

#9 two schnauzers

two schnauzers

    Member

  • Members
  • PipPip
  • 10 posts

Posted 26 July 2011 - 05:04 PM

Dumb question. Can this be used with a regular Netduino (not Plus)?

#10 monewwq1

monewwq1

    Advanced Member

  • Members
  • PipPipPip
  • 104 posts

Posted 27 July 2011 - 12:52 PM

Dumb question. Can this be used with a regular Netduino (not Plus)?


Yes, this can be used with the regular Netduino as well.

#11 monewwq1

monewwq1

    Advanced Member

  • Members
  • PipPipPip
  • 104 posts

Posted 01 August 2011 - 01:09 AM

Hi all, For those interested, just an update on this Gainspan module- please note that in order to obtain the newest firmware and future updates, you will need to sign a mutual Non-Disclosure Agreement with Gainspan. I wasn't real happy about having to do this, but it was relatively painless and the new firmware opened up a world of more possibilities. It took me 8 days to get my NDA approved.

#12 Cuno

Cuno

    Advanced Member

  • Members
  • PipPipPip
  • 144 posts
  • LocationZürich / Switzerland

Posted 23 August 2011 - 10:04 AM

Hi Nick, I ordered a GainSpan module from SparkFun, and thanks to your code was up and running quickly. I haven't done any systematic measurements yet, but got the impression that the module's throughput is rather low. I thought of using bulk mode transfers, which may be faster, but the documentation (Serial_to_WiFi_Adapter_Guide ver 5_3.pdf) appears inconsistent. I tried the command AT+BDATA=1 to enable bulk mode, and then ESC 'Z' for sending data, but got error messages. My module's firmware version is 2.2.4, btw. Do you have experience regarding the module's throughput? Thanks and best regards Cuno

#13 monewwq1

monewwq1

    Advanced Member

  • Members
  • PipPipPip
  • 104 posts

Posted 24 August 2011 - 02:45 AM

Hi Nick,

I ordered a GainSpan module from SparkFun, and thanks to your code was up and running quickly. I haven't done any systematic measurements yet, but got the impression that the module's throughput is rather low.

I thought of using bulk mode transfers, which may be faster, but the documentation (Serial_to_WiFi_Adapter_Guide ver 5_3.pdf) appears inconsistent. I tried the command AT+BDATA=1 to enable bulk mode, and then ESC 'Z' for sending data, but got error messages. My module's firmware version is 2.2.4, btw.

Do you have experience regarding the module's throughput?

Thanks and best regards

Cuno


Hi Cuno,

I am glad to hear you were able to get the Gainspan module communicating. To enable bulk data mode, you need version 2.3.1 of the Gainspan firmware. To obtain version 2.3.1, you would need to sign an NDA with Gainspan for the firmware update. When you say the throughput is low, do you mean the Wi-Fi to serial conversion? You might try adjusting the Baud Rate of the serial connection. Please update me on how you're doing with it. Good luck.

#14 Venerable Steve

Venerable Steve

    New Member

  • Members
  • Pip
  • 6 posts

Posted 12 September 2011 - 09:39 PM

Hello to people on the Netduino community I am from the programming (Delphi) side of the equation ........... I have a XRF module and a XBEE Pro Shield I just ran the code from v1 of above and the Associate LED on the XBEE Pro started to oscillate YES YES YES!!! (after switching the onboard button from USB to XBEE ) um on the Visual Studio side um I put a breakpoint at the line UARTConnection UART = new UARTConnection(SerialPorts.COM1,115200, Parity.None, 8, StopBits.One); and now I am just wondering how to proceed? I see the Neduino has 2 com ports under serialports.com1(is that right) or are we talking to the PC instead thanks :) oh and did you set one board up as a master or do the boards use straight serial? PS. I have another XRF hooked up to a DFRobot usb breakout board to accept and report the result.

#15 CarTech

CarTech

    New Member

  • Members
  • Pip
  • 9 posts

Posted 02 October 2011 - 05:16 PM

I'm using the gainspan 1011. I followed your source code and have tcp working nicely, thanks! I'm trying to get the httpsend feature working to send an http post. I setup a php script that accepts two fields and I've verified it works using putty. So far, the php script is telling me I'm sending an empty message. So, I'm definitely talking to the server, just not sending any data. I think maybe I've got the escape sequence incorrect. Here's the relevant commands I'm sending the gainspan:

at+httpconf=20,User-Agent: Mozilla/4.0\r
at+httpconf=3,keep-alive\r
at+httpconf=11,<myhost>\r
at+httpconf=7,application/x-www-form-urlencoded\r
at+httpopen=<myhostip>\r
at+httpsend=0,3,10,/test_post.php,23\r\x1BHname=myName&info=myInfo

Any suggestions? I'm not sure what to try next.

#16 monewwq1

monewwq1

    Advanced Member

  • Members
  • PipPipPip
  • 104 posts

Posted 07 October 2011 - 02:36 AM

I'm using the gainspan 1011. I followed your source code and have tcp working nicely, thanks! I'm trying to get the httpsend feature working to send an http post. I setup a php script that accepts two fields and I've verified it works using putty. So far, the php script is telling me I'm sending an empty message. So, I'm definitely talking to the server, just not sending any data. I think maybe I've got the escape sequence incorrect. Here's the relevant commands I'm sending the gainspan:

at+httpconf=20,User-Agent: Mozilla/4.0\r
at+httpconf=3,keep-alive\r
at+httpconf=11,<myhost>\r
at+httpconf=7,application/x-www-form-urlencoded\r
at+httpopen=<myhostip>\r
at+httpsend=0,3,10,/test_post.php,23\r\x1BHname=myName&info=myInfo

Any suggestions? I'm not sure what to try next.


Hi, unfortunately I have not used the built-in http features of the Gainspan. For my Gainspan projects I rolled my own http communications.

#17 CarTech

CarTech

    New Member

  • Members
  • Pip
  • 9 posts

Posted 14 October 2011 - 01:16 AM

Hi, unfortunately I have not used the built-in http features of the Gainspan. For my Gainspan projects I rolled my own http communications.


I figured out the problem was I left out the command which sets the data length, fifth line below. Here is the working code snippet:

at+httpconf=20,Mozilla/4.0\r
at+httpconf=3,keep-alive\r
at+httpconf=11,enginuitydiagnostics.com\r
at+httpconf=7,application/x-www-form-urlencoded\r
at+httpconf=5,23\r
at+httpopen=<myhostip>\r
at+httpsend=0,3,10,/test_post.php,23\r\x1BHname=myName&info=myInfo


#18 mcinnes01

mcinnes01

    Advanced Member

  • Members
  • PipPipPip
  • 325 posts
  • LocationManchester UK

Posted 16 October 2011 - 06:58 PM

Hi, I have just got a gainspan module from sparkfun, and I wondered if you could help... Firstly can you tell me which version of the firmware do I need (I have the NDK now), I have downloaded both but am not sure which one to use; the Mxp or MEE? Also how do I then update the firmware? Finally do you have an example web script as I have not really done much with websites before and don't really know where to begin with that side? Many thanks, Andy

#19 monewwq1

monewwq1

    Advanced Member

  • Members
  • PipPipPip
  • 104 posts

Posted 16 October 2011 - 11:43 PM

Hi,

I have just got a gainspan module from sparkfun, and I wondered if you could help...

Firstly can you tell me which version of the firmware do I need (I have the NDK now), I have downloaded both but am not sure which one to use; the Mxp or MEE?

Also how do I then update the firmware?

Finally do you have an example web script as I have not really done much with websites before and don't really know where to begin with that side?

Many thanks,

Andy


Andy,

Out of the box, you do not need to update the firmware. If you need the current functionality, such as Bulk Data mode and others, you'll need to update the firmware.

The part number should be written on the device. Mine is a GS1011MIP, so I would use the MxP firmware. The part number just indicates whether it uses an internal or external Power Amplifier (PA) and whether it uses an external or PCB antenna. For example, an MIP has an internal PA with PCB antenna. An MEE has an external PA with External antenna. See also http://www.gainspan....e/s_modules.php

I update the firmware using a 3.3v USB-to-TTL adapter and the communication software provided with the Gainspan software download. I can't remember the name of the software at the moment but it is included in the download, as long as you have a login and have signed the non-disclosure agreement. Just plug the USB end of the adapter into the computer and wire the 3.3V, Tx, Rx, and Gnd from the ttl adapter to the corresponding pins on the Gainspan module, with Tx to Rx, and Rx to Tx.

As for the example web script, maybe describe what you're trying to do exactly and I can try to help.

Nick

#20 Johan

Johan

    Member

  • Members
  • PipPip
  • 10 posts

Posted 17 October 2011 - 02:32 PM

I wish I didn't have a Netduino and a Gainspan WiFi module laying around. Now I need to try this as well :-)




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

home    hardware    projects    downloads    community    where to buy    contact Copyright © 2016 Wilderness Labs Inc.  |  Legal   |   CC BY-SA
This webpage is licensed under a Creative Commons Attribution-ShareAlike License.