Back to Smartcitizen.me

Get Wi-Fi info

Hi,

Is there any way to see Wi-Fi info? As IP address, port being used, DHCP info, etc ?

I got it by accident somehow when activating the module sing “$$$” but I can’t replicate it anymore.

Hi again @brunoperes! Let me check this with the team as I have also had problems to replicate it. I will get back to you later today with a solution. It is great to have you on board! Best.

Hi @brunoperes,

I have been just checking your question with the team and I can explain you now how to see the wifi info, IP address and so on.

To obtain all this info from the device you need to enter the wifly module’s terminal mode. Once you are in terminal mode you can use a few serial commands that will give you the required information.

Despite you probably already know some of them, I will go step by step describing what you have to do in order to make the terminal mode to work. Here we go:

  1. Connect your SCK via USB and make sure your SCK is on.

  2. Open the Arduino IDE.

  3. Select the right board in Tools -> Board (Arduino LilyPad USB)

  4. Select the right port (./dev/tty.usbmodemXXXX for MacOS and comXX for Windows) in Tools -> Serial Port

  5. Open the Serial Monitor

  6. Select the “No line ending” option in the drop down menu at the bottom right of the Serial Monitor’s window.

  7. Write “$$$” in the command line. If you get the message “Please, wait to wifly sleep”, wait for a few seconds. Try again and again until you get the next message:

wifly-GSX Ver: 4.41 Build: r1057, Jan 17 2014 10:26:26 on RN-131
MAC Addr=00:06:66:21:8b:4c
READY
Auto-Assoc DI&L chan=1 mode=MIXED SCAN OK
Joining DI&L now…
Associated!
DHCP: Start
DHCP in 1052ms, lease=7200s
IF=UP
DHCP=ON
IP=172.26.10.163:2000
NM=255.255.0.0
GW=172.26.0.6
Listen on 2000

  1. When you get the message above, write again “$$$” in the command line and you should get the message:

CMD

This message indicates that you are in Terminal mode.

  1. Now you can start to send serial commands to your wifi module but first you have to select “Carriage return” option in the drop down menu and the bottom right of the Serial Monitor’s window.

  2. In order to see the Wi-Fi settings you have to write “get wlan” in the command line and hit enter. You will get the message:

get wlan
SSID=YOURNETWORKSSID
Chan=0
ExtAnt=0
Join=1
Auth=YOURAUTENTIFICATIONMODE (wlan, mixed, wep, open)
Mask=0x1fff
Rate=12, 24 Mb
Linkmon=30
Passphrase=YOURNETWORKPASSWORD
EAP_Id=userid
EAP_User=peap-user
<4.41>

  1. In order to see the network settings of your kit, you have to write the command “get ip” in the command line, hit enter and you will get the message:

get ip
IF=UP
DHCP=ON
IP:2000=XXX.XXX.XXX.XXX
NM=255.255.0.0
GW=XXX.XXX.XXX.XXX
HOST=0.0.0.0:2000
PROTO=TCP,TCP_CLIENT,
MTU=1524
FLAGS=0x7
TCPMODE=0x0
BACKUP=0.0.0.0
<4.41>

  1. In order to leave the terminal mode (and with “Carriage return” option selected in the drop down menu at the bottom right of the Serial Monitor’s window) write “exit”. You will get the message:

exit

This means that you are already out of the terminal mode and your SCK should go back to normal operation mode and re-start sending measurements again. If not, you just need to reset (turn off/on) your kit.

I hope all this info helps and, please, let me know how it goes.

Kind regards.

PS: There are much more commands that you can find here: http://bit.ly/1mMIqvM

Hi. I am new here. I have a problem with WiFi. After I write “$$$” in commend line, I keep getting these messages:

Auto-Assoc ESS777 chan=9 mode=MIXED SCAN OK
Joing E77 ow.
Disconn from ESS777,AUTH-ERR
Auto-Assoc ESS777 chan=9 mode=MIXED SCAN OK
Joining ESS777 now…
Disconn from ESS777,AUTH-ERR
Auto-Assoc ESS777 chan=9 mode=MIXED SCAN OK
Joining ESS777 now…
Disconn from ESS777,AUTH-ERR
Auto-Assoc ESS777 chan=9 mode=MIXED SCAN OK
Joining ESS777 now…
Disconn from ESS777,AUTH-ERR
Auto-Assoc ESS777 chan=9 mode=MIXED SCAN OK
Joining ESS777 now…
Disconn from ESS777,AUTH-ERR
Auto-Assoc ESS777 chan=9 mode=MIXED SCAN OK
Joining ESS777 now…

*ESS777 is the name of my network. What is AUTH-ERR? and how can I fix this? Thanks in advance.

hi @SemooSetoo! Sorry for the late response. Please, could you try to upload the firmware again. And could you tell us what you see in Arduino IDE’s Serial Monitor after uploading the firmware!? Note that for SCK v1.1 you have to select “LilyPad Arduino USB” in Tools > Boards. Looking forward to hearing from you. Best. :slight_smile:

Hi @arpegius,

Have you tried setting up your SCK via the normal route? http://docs.smartcitizen.me/#/start/adding-a-smart-citizen-kit

Or is there a reason you’re trying to set it up manually?

-Matt
SCK 685

Hi @arpegius,

I don’t think any data will be lost (since it is linked to the user and device), but let’s see if we can get some insight from the others out there.

@aitoraloa, will arpegius’s current and historical data be lost if they re-configure their SCK?

-Matt
SCK 685