WiFi scan working, how to get network cipher type?

I’ve written a function that uses wlan_scan(wlan_scan_callback, this) to return a list of networks together with their SSID, security type and RSSI. I am however unable to find a way to get the networks cipher (WLAN_CIPHER_AES/TKIP/…)
Without this I am unable to write a user interface (LCD) to allow the user to manually connect to a network.
Does anyone perhaps know how to retrieve the network cipher from a scan?

This is the front-end that will use the photon to off-load heavy networking tasks

Regards, Marcin

1 Like

@Sleziak, you might seriously want to consider an HMI display like this:

http://imall.itead.cc/display/nextion.html

I got some from their recent Indiegogo campaign and was quite pleased. The displays offload a lod of the work required for building an interface. :smiley:

Peekay, I’m afraid that these displays won’t reach the level of fidelity and detail that my application provides. I’m doing live 3D rendering of a .STL model that can be rotated in all axis. Also the interface has custom transitions and effects that can’t be matched by HMI displays. The asking price of $44.90 is almost 4x as much as a simple RGB interface LCD of the same size.
You might want to look into DMA2D on the STM32F4 series, the maximum CPU load on my core is a mere 5% during the most intensive graphical tasks.

@Sleziak, I’m going to crawl back under my rock. These are not the droids I am looking for :wink:

1 Like

Hahaha, my apologies, lack of sleep causes me to lose traits that define a human.

I wish these things existed when I was toying around with arduinos, it was a nightmare to use slow I2C/SPI displays

1 Like

The firmware release (happening today) has WiFi.scan() supported in the API. :smile:

1 Like

Your DEV team sounds like a dream, always one step ahead

Much appreciated!

EDIT: After reviewing the release, I have a quick question
My original code was roughly the same as WiFi.scan(), it returned a list of WiFiAccessPoint.
I had a problem however with setting creditals:

WiFi.setCredentials(SSID,password, securityType);  //Does not work
WiFi.setCredentials(SSID, strlen(SSID), password, strlen(password), securityType, WLAN_CIPHER_AES); //Works.

@mdma, Is there any additional steps I need to take between the .scan() and .setCreditals() to successfully connect to the scanned network?

1 Like