wyze

package
v1.9.14 Latest Latest
Warning

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

Go to latest
Published: Jan 19, 2026 License: MIT Imports: 23 Imported by: 0

Documentation

Index

Constants

View Source
const (
	FrameSize1080P      = 0
	FrameSize360P       = 1
	FrameSize720P       = 2
	FrameSize2K         = 3
	FrameSizeFloodlight = 4
)
View Source
const (
	BitrateMax uint16 = 0xF0
	BitrateSD  uint16 = 0x3C
)
View Source
const (
	MediaTypeVideo       = 1
	MediaTypeAudio       = 2
	MediaTypeReturnAudio = 3
	MediaTypeRDT         = 4
)
View Source
const (
	KCmdAuth               = 10000
	KCmdChallenge          = 10001
	KCmdChallengeResp      = 10002
	KCmdAuthResult         = 10003
	KCmdControlChannel     = 10010
	KCmdControlChannelResp = 10011
	KCmdSetResolutionDB    = 10052
	KCmdSetResolutionDBRes = 10053
	KCmdSetResolution      = 10056
	KCmdSetResolutionResp  = 10057
)

Variables

This section is empty.

Functions

This section is empty.

Types

type AuthError

type AuthError struct {
	Message  string `json:"message"`
	NeedsMFA bool   `json:"needs_mfa,omitempty"`
	MFAType  string `json:"mfa_type,omitempty"`
}

func (*AuthError) Error

func (e *AuthError) Error() string

type AuthResponse

type AuthResponse struct {
	ConnectionRes string         `json:"connectionRes"`
	CameraInfo    map[string]any `json:"cameraInfo"`
}

type Camera

type Camera struct {
	MAC          string `json:"mac"`
	P2PID        string `json:"p2p_id"`
	ENR          string `json:"enr"`
	IP           string `json:"ip"`
	Nickname     string `json:"nickname"`
	ProductModel string `json:"product_model"`
	ProductType  string `json:"product_type"`
	DTLS         int    `json:"dtls"`
	FirmwareVer  string `json:"firmware_ver"`
	IsOnline     bool   `json:"is_online"`
}

type Client

type Client struct {
	// contains filtered or unexported fields
}

func Dial

func Dial(rawURL string) (*Client, error)

func (*Client) Close

func (c *Client) Close() error

func (*Client) GetBackchannelCodec

func (c *Client) GetBackchannelCodec() (codecID byte, sampleRate uint32, channels uint8)

func (*Client) Protocol

func (c *Client) Protocol() string

func (*Client) ReadPacket

func (c *Client) ReadPacket() (*tutk.Packet, error)

func (*Client) RemoteAddr

func (c *Client) RemoteAddr() net.Addr

func (*Client) SetBackchannelCodec

func (c *Client) SetBackchannelCodec(codecID byte, sampleRate uint32, channels uint8)

func (*Client) SetDeadline

func (c *Client) SetDeadline(t time.Time) error

func (*Client) SetResolution

func (c *Client) SetResolution(quality byte) error

func (*Client) StartAudio

func (c *Client) StartAudio() error

func (*Client) StartIntercom

func (c *Client) StartIntercom() error

func (*Client) StartVideo

func (c *Client) StartVideo() error

func (*Client) StopIntercom

func (c *Client) StopIntercom() error

func (*Client) SupportsAudio

func (c *Client) SupportsAudio() bool

func (*Client) SupportsIntercom

func (c *Client) SupportsIntercom() bool

func (*Client) WriteAudio

func (c *Client) WriteAudio(codec byte, payload []byte, timestamp uint32, sampleRate uint32, channels uint8) error

type Cloud

type Cloud struct {
	// contains filtered or unexported fields
}

func NewCloud

func NewCloud(apiKey, keyID string) *Cloud

func (*Cloud) GetCamera

func (c *Cloud) GetCamera(id string) (*Camera, error)

func (*Cloud) GetCameraList

func (c *Cloud) GetCameraList() ([]*Camera, error)

func (*Cloud) GetP2PInfo

func (c *Cloud) GetP2PInfo(mac string) (map[string]any, error)

func (*Cloud) Login

func (c *Cloud) Login(email, password string) error

type Producer

type Producer struct {
	core.Connection
	// contains filtered or unexported fields
}

func NewProducer

func NewProducer(rawURL string) (*Producer, error)

func (*Producer) AddTrack

func (p *Producer) AddTrack(media *core.Media, codec *core.Codec, track *core.Receiver) error

func (*Producer) Start

func (p *Producer) Start() error

Jump to

Keyboard shortcuts

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