HotRemote is a simple and user-friendly Go library for programmatically controlling HOT Boxes.
- Hot Box Control: Programmatically control your Hot Box, for example changing channels.
- Button Press: Simulate pressing buttons on your Hot Box's remote control, enabling you to automate tasks and create custom interactions.
- API Abstraction: Abstracts the complexity of Hot Box protocol, providing a simple and unified interface.
- Feature Coverage: Full capability with the mobile app.
To use HotRemote in your Go project, you need to have Go installed and set up. You can install the library by running the following command:
go get github.com/yakiroren/hotremote
To use HotRemote in your Go code, import the library into your project:
import "github.com/yakiroren/hotremote"
package main
import (
"log"
"github.com/yakiroren/hotremote"
)
func main() {
client, err := HotRemote.New()
if err != nil {
log.Fatal(err)
}
// Use the `client` object to interact with the Hot Box
}
devices, err := client.ListDevices()
if err != nil {
log.Fatal(err)
}
for _, device := range devices {
log.Println(device.ID, device.Name)
}
420254005266 HOT FiberBox266
316501071005 Hot FiberBox0000
321307003805 HOT mini FiberBox805
Use the device ID to create a session
session := client.CreateSession("316501071005")
session.SwitchToChannel(13)
session.SwitchToChannel(12)
// Power on or off the device
session.PressPower()
// color buttons
session.PressRed()
session.PressGreen()
session.PressBlue()
session.PressYellow()
// movement buttons
session.PressUp()
session.PressDown()
session.PressLeft()
session.PressDown()
// open search menu
session.OpenSearch()
session.SendStr("value to search")
session.PressSelect()
session.PressInfo()
// or direct call
session.Press(Buttons.Info)
See more at the examples folder.