blob: 6b7a1de7376f7e98b6dadef637b27ed620c80328 [file] [log] [blame]
Shad Ansari2f7f9be2017-06-07 13:34:53 -07001# $language = "VBScript"
2# $interface = "1.0"
3
4
5Sub Sleep(timewait)
6
7 If crt.screen.waitforstring("pause", timewait) = true then msgbox "surprise"
8
9End Sub
10
11Sub SendShellCommand(shell_command)
12 crt.Screen.Send shell_command & VbCr
13End Sub
14
15sub main
16
17SendShellCommand("root")
18crt.Sleep 100
19SendShellCommand("root")
20crt.Sleep 100
21SendShellCommand("cd /opt/bcm68620/")
22crt.screen.WaitForString "#"
23crt.Sleep 100
24SendShellCommand("./svk_init.sh")
25crt.screen.WaitForString ">"
26crt.Sleep 1000
27crt.Screen.Send VbCr
28
29'mandatory
30SendShellCommand("/api/set object=device system_mode=gpon__16_x")
31crt.Sleep 50
32
33'Optional - configure the NNI speed in order to work with a 1g traffic generator
34SendShellCommand("/api/set object=device nni_speed.first_half=gbps_1 nni_speed.second_half=gbps_1 ")
35crt.Sleep 50
36
37'Optional - configure the PCIe dma queues sizes or configure the system not to fail on bad AVS check.
38SendShellCommand("/api/set object=device debug.host_dma_rx_queue_size=128 debug.host_dma_tx_queue_size=128 debug.avs_control=yes")
39crt.Sleep 50
40
41'Optional - configure the keep alive parameters
42SendShellCommand("/api/set object=device keepalive_interval=5 keepalive_tolerance=3")
43
44crt.Screen.Send VbCr
45crt.screen.WaitForString ">"
46crt.Sleep 50
47crt.Screen.Send VbCr
48
49
50SendShellCommand("/user/register_indication_handler")
51crt.Screen.Send VbCr
52crt.Screen.Send VbCr
53crt.screen.WaitForString ">"
54
55crt.Screen.Send VbCr
56crt.Sleep 50
57SendShellCommand("/user/register_proxy_rx_handler ")
58crt.Screen.Send VbCr
59crt.Sleep 50
60crt.Screen.Send VbCr
61SendShellCommand("/api/oper object=device sub=connect ")
62crt.Screen.Send VbCr
63crt.screen.WaitForString ">"
64crt.Screen.Send VbCr
65
66crt.Sleep 50
67
68End Sub