# $language = "VBScript" | |
# $interface = "1.0" | |
Sub SendApplicationCommand(shell_command) | |
crt.Screen.Send shell_command & VbCr & VbCr | |
crt.sleep 1000 | |
End Sub | |
Sub main | |
pon_ni = inputbox("PON NI: [0-15]" ) | |
onu = inputbox("ONU ID: [0-127]" ) | |
gem = inputbox("GEM PORT ID?" ) | |
SendApplicationCommand "/~ off " | |
crt.sleep 100 | |
SendApplicationCommand "/api/set object=gpon_gem_port pon_ni=" & pon_ni & " gem_port_id=" & gem & " configuration.direction=bidirectional configuration.type=unicast onu_id=" & onu & " downstream_encryption_mode=disable upstream_destination_queue=data control=enable" | |
crt.sleep 100 | |
SendApplicationCommand "/~ on " | |
crt.sleep 100 | |
End Sub |