sender

package
v0.0.0-...-1f94d21 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 22, 2022 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Sender

type Sender struct {
	User       string
	Pass       string
	HTTPS      bool
	IP         string
	Port       string
	GameID     string
	HTTPClient *http.Client
	Serial     *serial.Serial
}

Sender will represent the connection between the scoreboard and the connector service

func New

func New(serial *serial.Serial) *Sender

New will return an instantiated Sender

func (*Sender) CheckConnection

func (s *Sender) CheckConnection() error

CheckConnection will check if the scoreboard is reachable and return an error if not It is used by the ui to check after updating the Scoreboard config

func (*Sender) NextPlayer

func (s *Sender) NextPlayer()

NextPlayer will send nextPlayer using sendToScoreboard

func (*Sender) Rematch

func (s *Sender) Rematch()

Rematch will send rematch using sendToScoreboard

func (*Sender) Throw

func (s *Sender) Throw(matrix string)

Throw will send a throw using sendToScoreboard

func (*Sender) UpdateStatus

func (s *Sender) UpdateStatus()

UpdateStatus will fetch and update the status from the scoreboard with sendToScoreboard

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL