Documentation ¶
Index ¶
- Constants
- func LessThanZero(numString string) bool
- func ToIndexOne(numString string) (string, error)
- func ToIndexZero(numString string) (string, error)
- type CommandInfo
- type Kramer4x4
- func (vs *Kramer4x4) GetActiveSignal(ctx context.Context, port string) (error, structs.ActiveSignal)
- func (vs *Kramer4x4) GetActiveSignalByPort(ctx context.Context, port string, readWelcome bool) (structs.ActiveSignal, error)
- func (vs *Kramer4x4) GetHardwareInfo(ctx context.Context) (structs.HardwareInfo, error)
- func (vs *Kramer4x4) GetInfo(ctx context.Context) (interface{}, error)
- func (vs *Kramer4x4) GetInputByOutput(ctx context.Context, output string) (string, error)
- func (vs *Kramer4x4) SendCommand(ctx context.Context, cmd []byte) ([]byte, error)
- func (vs *Kramer4x4) SetFrontLock(ctx context.Context, state bool) error
- func (vs *Kramer4x4) SetInputByOutput(ctx context.Context, output, input string) error
- type Kramer4x4Option
- type Kramer4x4optionFunc
- type Kramer4x4options
- type KramerAFM20DSP
- func (dsp *KramerAFM20DSP) GetHardwareInfo(ctx context.Context) (structs.HardwareInfo, error)
- func (dsp *KramerAFM20DSP) GetInfo(ctx context.Context) (interface{}, error)
- func (dsp *KramerAFM20DSP) GetMutedByBlock(ctx context.Context, block string) (bool, error)
- func (dsp *KramerAFM20DSP) GetVolumeByBlock(ctx context.Context, block string) (int, error)
- func (dsp *KramerAFM20DSP) SendCommand(ctx context.Context, cmd []byte) ([]byte, error)
- func (dsp *KramerAFM20DSP) SetMutedByBlock(ctx context.Context, block string, muted bool) error
- func (dsp *KramerAFM20DSP) SetVolumeByBlock(ctx context.Context, block string, level int) error
- type KramerAFM20DSPOption
- type KramerAFM20DSPoptionFunc
- type KramerAFM20DSPoptions
- type KramerVP558
- func (dsp *KramerVP558) GetHardwareInfo(ctx context.Context) (structs.HardwareInfo, error)
- func (vsdsp *KramerVP558) GetInfo(ctx context.Context) (interface{}, error)
- func (vsdsp *KramerVP558) GetInputByOutput(ctx context.Context, output string) (string, error)
- func (vsdsp *KramerVP558) GetMutedByBlock(ctx context.Context, block string) (bool, error)
- func (vsdsp *KramerVP558) GetVolumeByBlock(ctx context.Context, block string) (int, error)
- func (vsdsp *KramerVP558) SendCommand(ctx context.Context, cmd []byte) ([]byte, error)
- func (vsdsp *KramerVP558) SetInputByOutput(ctx context.Context, output, input string) error
- func (vsdsp *KramerVP558) SetMutedByBlock(ctx context.Context, block string, muted bool) error
- func (vsdsp *KramerVP558) SetVolumeByBlock(ctx context.Context, block string, level int) error
- type KramerVP558Option
- type KramerVP558optionFunc
- type KramerVP558options
- type Logger
- type Response
Constants ¶
const ( BuildDate = "BUILD-DATE" Model = "MODEL" SerialNumber = "SN" FirmwareVersion = "VERSION" ProtocolVersion = "PROT-VER" Temperature = "HW-TEMP" PowerSave = "POWER-SAVE" IPAddress = "NET-IP" Gateway = "NET-GATE" MACAddress = "NET-MAC" NetDNS = "NET-DNS" Signal = "SIGNAL" )
const ( CARRIAGE_RETURN = 0x0D LINE_FEED = 0x0A SPACE = 0x20 DELAY_BETWEEN_CONNECTIONS = time.Second * 10 )
Variables ¶
This section is empty.
Functions ¶
func LessThanZero ¶
Returns if a given number (in a string) is less than zero.
func ToIndexOne ¶
This function converts a number (in a string) to index-based 1.
func ToIndexZero ¶
This function converts a number (in a string) to index-base 0.
Types ¶
type CommandInfo ¶
type Kramer4x4 ¶ added in v0.1.2
func NewVideoSwitcher ¶
func NewVideoSwitcher(addr string, opts ...Kramer4x4Option) *Kramer4x4
func (*Kramer4x4) GetActiveSignal ¶ added in v0.1.2
func (*Kramer4x4) GetActiveSignalByPort ¶ added in v0.1.2
func (*Kramer4x4) GetHardwareInfo ¶ added in v0.1.2
func (*Kramer4x4) GetInputByOutput ¶ added in v0.1.2
GetInput returns the current input
func (*Kramer4x4) SendCommand ¶ added in v0.1.2
SendCommand sends the byte array to the desired address of projector
func (*Kramer4x4) SetFrontLock ¶ added in v0.1.2
type Kramer4x4Option ¶ added in v0.1.2
type Kramer4x4Option interface {
// contains filtered or unexported methods
}
type Kramer4x4optionFunc ¶ added in v0.1.2
type Kramer4x4optionFunc func(*Kramer4x4options)
type Kramer4x4options ¶ added in v0.1.2
type Kramer4x4options struct {
// contains filtered or unexported fields
}
type KramerAFM20DSP ¶ added in v0.1.2
func NewDsp ¶ added in v0.1.2
func NewDsp(addr string, opts ...KramerAFM20DSPOption) *KramerAFM20DSP
func (*KramerAFM20DSP) GetHardwareInfo ¶ added in v0.1.2
func (dsp *KramerAFM20DSP) GetHardwareInfo(ctx context.Context) (structs.HardwareInfo, error)
func (*KramerAFM20DSP) GetInfo ¶ added in v0.1.2
func (dsp *KramerAFM20DSP) GetInfo(ctx context.Context) (interface{}, error)
GetInfo .
func (*KramerAFM20DSP) GetMutedByBlock ¶ added in v0.1.2
GetMuted returns the Mute Status current input The blocks are going to be a number between 1-20, determined by its configuration
func (*KramerAFM20DSP) GetVolumeByBlock ¶ added in v0.1.2
GetVolume returns the volume Level for the given input The blocks are going to be a number between 1-20, determined by its configuration
func (*KramerAFM20DSP) SendCommand ¶ added in v0.1.2
SendCommand sends the byte array to the desired address of projector
func (*KramerAFM20DSP) SetMutedByBlock ¶ added in v0.1.2
SetMuted changes the input on the given output to input The blocks are going to be a number between 1-20, determined by its configuration
func (*KramerAFM20DSP) SetVolumeByBlock ¶ added in v0.1.2
SetVolume changes the volume level on the given block to the level parameter The blocks are going to be a number between 1-20, determined by its configuration
type KramerAFM20DSPOption ¶ added in v0.1.2
type KramerAFM20DSPOption interface {
// contains filtered or unexported methods
}
TODO add specific options for each model
type KramerAFM20DSPoptionFunc ¶ added in v0.1.2
type KramerAFM20DSPoptionFunc func(*KramerAFM20DSPoptions)
type KramerAFM20DSPoptions ¶ added in v0.1.2
type KramerAFM20DSPoptions struct {
// contains filtered or unexported fields
}
type KramerVP558 ¶ added in v0.1.2
func NewVideoSwitcherDsp ¶ added in v0.1.2
func NewVideoSwitcherDsp(addr string, opts ...KramerVP558Option) *KramerVP558
func (*KramerVP558) GetHardwareInfo ¶ added in v0.1.2
func (dsp *KramerVP558) GetHardwareInfo(ctx context.Context) (structs.HardwareInfo, error)
func (*KramerVP558) GetInfo ¶ added in v0.1.2
func (vsdsp *KramerVP558) GetInfo(ctx context.Context) (interface{}, error)
GetInfo .
func (*KramerVP558) GetInputByOutput ¶ added in v0.1.2
GetInput returns the current input The API is zero indexed, so outputs 0-3 correspond with outputs 1-4 on device inputs 0-10 correspond with outputs 1-11 see https://cdn.kramerav.com/web/downloads/manuals/vp-558_rev_4.pdf (page 66)
func (*KramerVP558) GetMutedByBlock ¶ added in v0.1.2
GetMuted returns the Mute Status current input Audio inputs are formatted 0:0 - 4:2, and audio level is between 0-100. for more information on Audio Inputs reference https://cdn.kramerav.com/web/downloads/manuals/vp-558_rev_4.pdf (pg. 64)
func (*KramerVP558) GetVolumeByBlock ¶ added in v0.1.2
GetVolume returns the volume Level for the given input Audio inputs are formatted 0:0 - 4:2, and audio level is between 0-100. for more information on Audio Inputs reference https://cdn.kramerav.com/web/downloads/manuals/vp-558_rev_4.pdf (pg. 64)
func (*KramerVP558) SendCommand ¶ added in v0.1.2
SendCommand sends the byte array to the desired address of projector
func (*KramerVP558) SetInputByOutput ¶ added in v0.1.2
func (vsdsp *KramerVP558) SetInputByOutput(ctx context.Context, output, input string) error
SwitchInput changes the input on the given output to input The API is zero indexed, so outputs 0-3 correspond with outputs 1-4 on device inputs 0-10 correspond with outputs 1-11 see https://cdn.kramerav.com/web/downloads/manuals/vp-558_rev_4.pdf (page 66)
func (*KramerVP558) SetMutedByBlock ¶ added in v0.1.2
setMuted changes the input on the given output to input Audio inputs are formatted 0:0 - 4:2, and audio level is between 0-100. for more information on Audio Inputs reference https://cdn.kramerav.com/web/downloads/manuals/vp-558_rev_4.pdf (pg. 64)
func (*KramerVP558) SetVolumeByBlock ¶ added in v0.1.2
SetVolume changes the volume level on the given block to the level parameter Audio inputs are formatted 0:0 - 4:2, and audio level is between 0-100. for more information on Audio Inputs reference https://cdn.kramerav.com/web/downloads/manuals/vp-558_rev_4.pdf (pg. 64)
type KramerVP558Option ¶ added in v0.1.2
type KramerVP558Option interface {
// contains filtered or unexported methods
}
type KramerVP558optionFunc ¶ added in v0.1.2
type KramerVP558optionFunc func(*KramerVP558options)
type KramerVP558options ¶ added in v0.1.2
type KramerVP558options struct {
// contains filtered or unexported fields
}