addded netlink and iw based wifi scanner for linux

This commit is contained in:
2017-10-10 17:00:12 +02:00
parent 7eb3a16e48
commit 628be72e1f
7 changed files with 601 additions and 23 deletions

View File

@@ -0,0 +1,30 @@
#ifndef INDOOR_WIFICHANNELS_H
#define INDOOR_WIFICHANNELS_H
class WiFiChannels {
public:
static int freqToChannel(const int freq) {
switch(freq) {
case 2412: return 1;
case 2417: return 2;
case 2422: return 3;
case 2427: return 4;
case 2432: return 5;
case 2437: return 6;
case 2442: return 7;
case 2447: return 8;
case 2452: return 9;
case 2457: return 10;
case 2462: return 11;
case 2467: return 12;
case 2472: return 13;
case 2484: return 14;
}
throw "error";
}
};
#endif // INDOOR_WIFICHANNELS_H