Skip to content

Instantly share code, notes, and snippets.

@jsinai
Last active May 18, 2017 21:14
Show Gist options
  • Save jsinai/9eb9f3d3843616f6bb9910f13d0717e2 to your computer and use it in GitHub Desktop.
Save jsinai/9eb9f3d3843616f6bb9910f13d0717e2 to your computer and use it in GitHub Desktop.
Configures the Diagnostic Web Server on a BrightSign. See notify.brs for the Notify subroutine.
Sub Main()
nc = CreateObject("roNetworkConfiguration", 0)
if type(nc) <> "roNetworkConfiguration" then
nc = CreateObject("roNetworkConfiguration", 1)
endif
if type(nc) = "roNetworkConfiguration" then
dwsAA = CreateObject("roAssociativeArray")
dwsAA["port"] = "80"
' Turn off authentication:
dwsAA["password"] = ""
' If you prefer using authentication:
'dwsAA["open"] = "brightsign"
nc.SetupDWS(dwsAA)
nc.Apply()
Notify("DWS is configured", -1)
endif
End Sub
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment