Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
languagejs
titlenetworkdiagnostics IDL
collapsetrue
interface NetworkDiagnostics {
    Promise<NetworkDiagnosticsResult> testInternetConnectivity()
    Promise<NetworkDiagnotsticsResult> testNetworkInterface(String interface_name)
    Promise<PingResult> ping(String host_name, PingConfig config)
    //< For BrightSign internal use. Behavior subject to change without notice.
    Promise<TracerouteResult> traceroute(String host_name, TracerouteConfig config)
    //< For BrightSign internal use. Behavior subject to change without notice.
};
 
interface InterfaceTestResult {
    String diagnosis;
    bool    ok;
    Array<Log> log;
};
 
interface Log {
    String name;
    bool pass;
    String result;
    Array<String> info;
    //< For BrightSign internal use. Behaviour subject to change without notice.
};

interface PingConfig {
    unsigned? short count; // default 10
    unsigned long? interval; // in milliseconds, default 100
    unsigned long? timeout; // in seconds, default 10000
    unsigned long? packetsize; // in bytes, default 56
    bool? ipv4; // enable pinging IPv4 addresses, default true
    bool? ipv6; // enable pinging IPv6 addresses, default falsetrue
    bool? allAddresses; // if true then ping all addresses returned from DNS query,
                        // if false then each will be pinged in turn until one responds, default false
};

interface PingResult {
    String hostname; // host name or literal address pinged
    PingResults results;
};

interface PingResults {
    bool up; // true if at least one address responded to at least 50% of the echo requests
    Array<ProtocolPingResult>? ipv4;
    Array<ProtocolPingResult>? ipv6;
};

interface ProtocolPingResult {
    String address; // IP address pinged
    bool up; // true if the address responded to at least 50% of the echo requests
    ProtocolPingReport report;
};

interface ProtocolPingReport {
    unsigned short transmitted; // number of echo requests sent
    unsigned short received; // number of echo replies received
    ProtocolPingStats stats;
};

interface ProtocolPingStats {
    unsigned long quickest; // quickest reply received
    unsigned long average; // average time across all replies from address
    unsigned long slowest; // slowest reply received
    String units; // always "us" to indicate microseconds
};

...

Code Block
languagejs
Promise<PingResult> ping(String host_name, PingConfig config)

For BrightSign internal use. Behavior subject to change without notice. Pings a device with the specified host_name to determine if there are connection issues. 

traceroute()
Code Block
languagejs
Promise<InterfaceTestResult> traceroute(String host_name, TraceRouteConfig config)

...

  • [unsigned short] count: The default value is 10.
  • [unsigned long] interval: The interval value in milliseconds. The default is 100.
  • [unsigned long] timeout: The timeout value in seconds. The default is 10000.
  • [unsigned long] packetsize: Packet The packet size in bytes. The default is 56.
  • [bool] ipv4: Enable pinging IPv6 IPv4 addresses. The default is true.
  • [bool] ipv6: Enable pinging IPv6 addresses. The default isfalsetrue.
  • [bool] allAddresses: If true then ping all addresses returned from the DNS query. If false, then each will be pinged in turn until one responds. The default is false.

PingResult

This interface is not recommended unless you are using BrightSign OS v8.3.45 and later.

...

  • [unsigned long] quickest: The quickest reply received
  • [unsigned long]  average: The average time across all replies from address
  • [unsigned long]  slowest: The slowest reply received.
  • [string]  units: The value is always "us", to indicate microseconds

Example

...