Documentation
¶
Overview ¶
LibreRemotePlaySignals is a Go library used in the LibreRemotePlay project.
It provides a set of functions and types to handle signals and communication between the LibreRemotePlay client and server.
The library is designed to be used in the LibreRemotePlay APP and CLI.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetMDNSLocal ¶ added in v1.3.0
func GetMDNSLocal() string
GetMDNSLocal returns the current MDNS .local domain used by the server
func InitServer ¶
func InitServer(options ServerOptions, ips_listening chan<- []string) error
InitServer initializes a HTTP + WS server on the given port. The ips_listening channel is used to notify the outside world about the IPs listening on the server. The server will listen on all available IPs.
This function is used in the CLI or in the LibreRemotePlay Host APP to start the server. The server will be started in a goroutine.
Types ¶
type ClientCodeT ¶
type ClientCodeT = types.ClientCode
ClientCodeT represents the client code sent to the server.
func ReceiveClientCode ¶
func ReceiveClientCode(s ServerT, ID uint16) (ClientCodeT, error)
ReceiveClientCode receives the client code from the server with a given connection ID.
type HostCodeT ¶
HostCodeT represents the host code sent to the server.
func SendClientCode ¶
func SendClientCode(s ServerT, client_code ClientCodeT, ID uint16) (HostCodeT, error)
SendClientCode sends the client code to the server with a given connection ID and returns the host code with the same connection ID.
type ServerOptions ¶ added in v1.2.0
type ServerOptions = types.ServerOptions
ServerOptions represents the configuration available for the HTTP/WS server (port, ...)