shokre / speed-touch-manager

PHP class for controling speed touch router

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

speed-touch-manager

PHP class for controling speed touch router

Usage

constructor

$stm = new SpeedTouchManager('router.ip', 'username', 'password');

listGames

List Game and Application Sharing assignments

$stm->listGames();

result:

...
[57] => Array
        (
            [game] => Lotus Notes
            [assignment] =>  
            [mode] => Server
        )

[58] => Array
        (
            [game] => Mail Server (SMTP)
            [assignment] => Unknown-ff-ff-ff-ff-ff-ff
            [mode] => Server
        )
...

create a game

Game is a service in speed-touch language

$stm->createGame('git');
$stm->assignPorts('git', SpeedTouchManager::PROTO_TCP, 9418);

assign game to network device

$stm->assignGame($srv, '192.168.1.1');

unassign game

$stm->unassignGame($srv, '192.168.1.1');

delete game

game must be unassigned first

$stm->deleteGame($srv, '192.168.1.1');

configure WLAN

$stm->configWLAN(
	true,                             // Interface Enabled
	'your ssid',                      // Network Name (SSID)
	SpeedTouchManager::TYPE_802_11bg, // Interface Type
	6,                                // Channel
	true,                             // Allow multicast from Broadband Network
	true,                             // Broadcast Network Name
	SpeedTouchManager::ALLOW_AUTO,    // Allow New Devices
	SpeedTouchManager::ENC_WPA,       // Security Mode
	'wpa_psk', 						  // WPA-PSK Preshared Key
	SpeedTouchManager::WPA_WPA2);     // WPA-PSK Version

Testing

Tested on:

  • SpeedTouch THOMSON ST780 (7.4.35.2)
  • SpeedTouch THOMSON TG782 (8.6.Q.3)

About

PHP class for controling speed touch router

License:MIT License


Languages

Language:PHP 100.0%