Jump to content
43oh

WiFi libraries AP functions


Recommended Posts

Hi all,

 

I can't find all functions I can use with WiFi library. If I start CC3200 in AP and a device connect to CC3200, with which commands I can communicate with it? I see all examples use client functions but all case CC3200 connect to an existing network.

 

What I want to do is start CC3200 in AP mode, let connect one client, start communication with this client with sending and reciving packets.

Link to post
Share on other sites

See the APWatchConnectDisconnect example.  That's how you track who connects.  Then you can extract their IP once you detect them (see the WiFi.deviceIpAddress() function's usage in that example) and use that as the IP to "connect" to in your code.

 

Or you set up a server, and let the client figure out where to talk ... I think there's some mDNS entry that defaults to the AP's local IP, like "mysimplelink.net" or somesuch.  We do need to make an API for changing that though.

Link to post
Share on other sites

See the APWatchConnectDisconnect example.  That's how you track who connects.  Then you can extract their IP once you detect them (see the WiFi.deviceIpAddress() function's usage in that example) and use that as the IP to "connect" to in your code.

 

Or you set up a server, and let the client figure out where to talk ... I think there's some mDNS entry that defaults to the AP's local IP, like "mysimplelink.net" or somesuch.  We do need to make an API for changing that though.

 

I've tryed this code and works well, created an AP, connected with another device and get device IP. But now I want to send a packed. Which function allow me to do this? For example: TCP or UDP protocol, to this IP, data variable.

 

Also, there is a monitor software that allow me to see this packets that or send data to CC3200? I've found that I can use somethink like packet sniffer, but isn't pratical.

 

Thanks for your help!

Link to post
Share on other sites

I've tryed this code and works well, created an AP, connected with another device and get device IP. But now I want to send a packed. Which function allow me to do this? For example: TCP or UDP protocol, to this IP, data variable.

 

Also, there is a monitor software that allow me to see this packets that or send data to CC3200? I've found that I can use somethink like packet sniffer, but isn't pratical.

 

Thanks for your help!

Hmmmm... It just occurred to me that the WiFi library might just not be documented well.  I always dive into the hardware/cc3200/libraries/WiFi directory and inspect the .h and .cpp files but that's not expected of new users...

 

Basically WiFiClient/WiFiServer handle TCP connections, and the WiFiUdp class handle UDP datagrams.  You can see the available functions by inspecting their header files, but I need to see if there's more elaborate documentation available for these.

Link to post
Share on other sites

Hmmmm... It just occurred to me that the WiFi library might just not be documented well.  I always dive into the hardware/cc3200/libraries/WiFi directory and inspect the .h and .cpp files but that's not expected of new users...

 

Basically WiFiClient/WiFiServer handle TCP connections, and the WiFiUdp class handle UDP datagrams.  You can see the available functions by inspecting their header files, but I need to see if there's more elaborate documentation available for these.

 

Thank you. I've found a simple WiFi packet sender and tested "WiFi UDP Send and Receive String" and works well. Also I've tryed "WiFi Web Client" in AP mode, seems to be slow and sometimes stop working but works. But when I try to create AP with UDP it doesn't send or recive any packets.

Link to post
Share on other sites

Thank you. I've found a simple WiFi packet sender and tested "WiFi UDP Send and Receive String" and works well. Also I've tryed "WiFi Web Client" in AP mode, seems to be slow and sometimes stop working but works. But when I try to create AP with UDP it doesn't send or recive any packets.

Ok, that's interesting ... can't say I've tried that combination yet.

 

Also as far as sniffers ... the only thing I've used is Wireshark on my laptop.  There may be some facility inside the CC3200/CC3100 itself but I'm not familiar enough with it yet.  I think TI typically has home-grown proprietary software and tools for debugging the CCxxxx series chips and the CC3100 has some special UART pins in its boosterpack setup to receive logs but I've never used it.

Link to post
Share on other sites

Hi all, I've recently started exploring the Wifi functionalities of the CC3200 LaunchPad.  I tried the APWatchConnectDisconnect example, and was able to connect 1 station point (my laptop) to the CC3200 AP.  The red light toggles when I connect and disconnect it, as expected.  However, when I try to have two Wifi connections to the CC3200 AP (e.g., one from my laptop and another from my Android phone), I am unable to get the second connection started.  I can first connect my phone's Wifi to this AP, but then not my laptop...and vice versa.  Does anyone here have success getting multiple station points to connect to the CC3200 AP simultaneously using the APWatchConnectDisconnect example or otherwise?

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...