dfu

package module
v1.0.17 Latest Latest
Warning

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

Go to latest
Published: Aug 8, 2019 License: LGPL-3.0 Imports: 13 Imported by: 3

README

Library for using the MD-380 (and other) DMR Radios in DFU mode

This library provides a go API for using the MD-380 (and other DMR radios) in DFU (Device Firmware Update) mode.

Author

Dale Farnsworth

dale@farnsworth.org

IRC: freenode channel: #md380, user: dfarnsworth

Documentation

Overview

Package dfu implements reading/writing from/to the md380 radio via usb.

Package dfu implements reading/writing from/to the md380 radio via usb.

Index

Constants

View Source
const (
	MinProgress = 0
	MaxProgress = 1000000
)
View Source
const CmdSleep = -2
View Source
const (
	MaxUV380Users = 122197
)

Variables

This section is empty.

Functions

func FilterUsers

func FilterUsers(users [][]string, countryMap map[string]bool) [][]string

func ParseUV380Users

func ParseUV380Users(reader io.Reader) [][]string

Types

type Dfu

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

func New

func New(progressCallback func(progressCounter int) error) (*Dfu, error)

func (*Dfu) Close

func (dfu *Dfu) Close()

func (*Dfu) ReadCodeplug

func (dfu *Dfu) ReadCodeplug(data []byte) error

func (*Dfu) ReadSPIFlash

func (dfu *Dfu) ReadSPIFlash(writer io.Writer) error

func (*Dfu) ReadUsers

func (dfu *Dfu) ReadUsers(file *os.File) error

func (*Dfu) WriteCodeplug

func (dfu *Dfu) WriteCodeplug(data []byte) error

func (*Dfu) WriteFirmware

func (dfu *Dfu) WriteFirmware(iRdr io.Reader) error

func (*Dfu) WriteUV380Users

func (dfu *Dfu) WriteUV380Users(users [][]string) error

func (*Dfu) WriteUsers

func (dfu *Dfu) WriteUsers(filename string) error

Jump to

Keyboard shortcuts

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