Documentation ¶
Index ¶
- func DecryptAes128Ecb(data []byte) []byte
- func EncodeBitmapForMask(bitmap [][]byte) ([]byte, error)
- func EncodeColorArrayForMask(columns int) []byte
- func EncryptAes128(data []byte) []byte
- func EncryptAes128Hex(hexstring string) []byte
- func GetTextImage(text string) [][]byte
- func InitAndConnect(MoreLogging bool) error
- func InitUpload(bitmap []byte, colorArray []byte) error
- func IsConnected() bool
- func SendDataToBtChar(device *bluetooth.DeviceCharacteristic, sendbuf []byte) error
- func SendRawData(sendbuf []byte) error
- func SetAnimation(image byte) error
- func SetDIYImage(image byte) error
- func SetImage(image byte) error
- func SetLight(brightness byte) error
- func SetMode(mode byte) error
- func SetText(text string) error
- func SetTextBackgroundColor(enable byte, r byte, g byte, b byte) error
- func SetTextColorMode(enable byte, mode byte) error
- func SetTextFrontColor(enable byte, r byte, g byte, b byte) error
- func SetTextSpeed(speed byte) error
- func Shutdown()
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DecryptAes128Ecb ¶
Len must be divsiable by 16 AES-ECB
func EncodeBitmapForMask ¶
EncodeBitmapForMask converts a bitmap to the custom mask format. Height must be 16 pixel.
func EncodeColorArrayForMask ¶
EncodeColorArrayForMask envodes a white color array
func EncryptAes128Hex ¶
Takes hex string, len must be divsiable by 16
func GetTextImage ¶
GetTextImage generates a bitmap out of a text using the font NotoSans
func InitAndConnect ¶
InitAndConnect searches and connects to a mask over BLE BLE must be enabled Blocking until a mask is found MoreLogging is showing debug output
func InitUpload ¶
InitUpload starts the bitmap upload process
func SendDataToBtChar ¶
func SendDataToBtChar(device *bluetooth.DeviceCharacteristic, sendbuf []byte) error
SendRawData sends a byte buffer to the specifed char, breaking it up if the buffer is to big
func SendRawData ¶
SendRawData sends a byte buffer to genralBtChar (UUID 0x9600)
func SetMode ¶
Sets the scroll mode 01 = steady 02 = blink 03 = scroll left 04 = scroll right 05 = steady
func SetText ¶
Comfort function that generates an image/bitmap from an string and starts the upload to the mask Text Color=White
func SetTextBackgroundColor ¶
Sets a background text color in RGB
func SetTextColorMode ¶
For text mode: sets special backgrounds mode: 00-03= text gradients () 04-07= background image (4 = x mask, 5 = christmas, 6 = love, 7 = scream)
func SetTextFrontColor ¶
Sets a foreground text color in RGB
Types ¶
This section is empty.