src/seedlink.js
SEEDLINK_PROTOCOL

Type: string

SequencedDataRecord

src/seedlink.js
SequencedDataRecord

Type: {rawsequence: string, sequence: number, miniseed: miniseed.DataRecord}

Properties
rawsequence (string)
sequence (number)
miniseed (miniseed.DataRecord)

SeedlinkConnection

src/seedlink.js

A seedlink websocket connection to the given url. The connection is not made until the connect() method is called. Note this cannot connect directly to a native TCP socket, instead it sends the seedlink protocol over a websocket. Currently only the IRIS ringserver, https://github.com/iris-edu/ringserver, supports websockets, but it may be possible to use thrid party tools to proxy the websocket to a TCP seedlink socket.

new SeedlinkConnection(url: string, requestConfig: Array<string>, receiveMiniseedFn: function (packet: SequencedDataRecord): void, errorFn: function (error: Error): void)
Parameters
url (string) websocket URL to connect to
requestConfig (Array<string>) an array of seedlink commands like:



[ 'STATION JSC CO',
'SELECT 00BHZ.D' ]
</pre></code>
receiveMiniseedFn (function (packet: SequencedDataRecord): void) the callback function that will be invoked for each seedlink packet received which contains 'sequence', a sequence number and 'miniseed', a single miniseed record.
errorFn (function (error: Error): void)
Instance Members
requestConfig
receiveMiniseedFn
errorFn
closeFn
webSocket
command
setTimeCommand(startTime)
setOnError(errorFn)
setOnClose(closeFn)
connect()
close()
handle(event)
handleMiniseed(event)
isConnected()
sendHello()
sendCmdArray(cmd)
createCmdPromise(mycmd)