Documentation
¶
Index ¶
- Constants
- Variables
- func DESDecrypt(src, key []byte) ([]byte, error)
- func DESEncrypt(src, key []byte) ([]byte, error)
- type Channels
- type Control
- type Device
- type DiscFormat
- type EKB
- type Encoding
- type Group
- type NetMD
- func (md *NetMD) Close()
- func (md *NetMD) EraseTrack(trk int) error
- func (md *NetMD) MoveTrack(trk, to int) error
- func (md *NetMD) NewTrack(title string, fileName string) (trk *Track, err error)
- func (md *NetMD) RecordingParameters() (encoding Encoding, channels Channels, err error)
- func (md *NetMD) RequestDiscCapacity() (recorded uint64, total uint64, available uint64, err error)
- func (md *NetMD) RequestDiscHeader() (string, error)
- func (md *NetMD) RequestStatus() (disk bool, err error)
- func (md *NetMD) RequestTrackCount() (c int, err error)
- func (md *NetMD) RequestTrackEncoding(trk int) (encoding Encoding, err error)
- func (md *NetMD) RequestTrackFlag(trk int) (flag TrackProt, err error)
- func (md *NetMD) RequestTrackLength(trk int) (duration uint64, err error)
- func (md *NetMD) RequestTrackTitle(trk int) (t string, err error)
- func (md *NetMD) Send(trk *Track, c chan Transfer)
- func (md *NetMD) SetDiscHeader(t string) error
- func (md *NetMD) SetTrackTitle(trk int, t string, isNew bool) (err error)
- func (md *NetMD) Wait() error
- type Nonce
- type Packet
- type Root
- type Track
- type TrackProt
- type Transfer
- type TransferType
- type WireFormat
Constants ¶
const ( EncSP Encoding = 0x90 EncLP2 Encoding = 0x92 EncLP4 Encoding = 0x93 ChanStereo Channels = 0x00 ChanMono Channels = 0x01 ControlRejected Control = 0x0a ControlAccepted Control = 0x09 ControlInterim Control = 0x0f ControlStub Control = 0x08 TrackProtected TrackProt = 0x03 TrackUnprotected TrackProt = 0x00 )
const ( WfPCM WireFormat = 0x00 WfLP2 WireFormat = 0x94 WfLP4 WireFormat = 0xa8 DfLP4 DiscFormat = 0 DfLP2 DiscFormat = 2 DfMonoSP DiscFormat = 4 DfStereoSP DiscFormat = 6 )
Variables ¶
var (
ByteArr16 = []byte{0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}
)
var ( Devices = [...]Device{ {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, {/* contains filtered or unexported fields */}, } )
var ( FrameSize = map[WireFormat]int{ WfPCM: 2048, WfLP2: 192, WfLP4: 96, } )
Functions ¶
func DESDecrypt ¶
func DESEncrypt ¶
Types ¶
type DiscFormat ¶
type DiscFormat int
type NetMD ¶
type NetMD struct {
// contains filtered or unexported fields
}
func (*NetMD) EraseTrack ¶
EraseTrack will erase the trk number starting from 0
func (*NetMD) RecordingParameters ¶
RecordingParameters current default recording parameters set on the NetMD
func (*NetMD) RequestDiscCapacity ¶
RequestDiscCapacity returns the totals in seconds
func (*NetMD) RequestDiscHeader ¶
RequestDiscHeader returns the raw title of the disc
func (*NetMD) RequestStatus ¶
RequestStatus returns known status flags
func (*NetMD) RequestTrackCount ¶
func (*NetMD) RequestTrackEncoding ¶
RequestTrackEncoding returns the Encoding of the trk starting from 0
func (*NetMD) RequestTrackFlag ¶
func (*NetMD) RequestTrackLength ¶
RequestTrackLength returns the duration in seconds of the trk starting from 0
func (*NetMD) RequestTrackTitle ¶
RequestTrackTitle returns the raw title of the trk number starting from 0
func (*NetMD) Send ¶
Send will transmit the Track data encrypted (concurrent) to the NetMD the Transfer channel will receive different TransferType's so the process can be followed closely from a different process
func (*NetMD) SetDiscHeader ¶
SetDiscHeader will write a raw title to the disc
func (*NetMD) SetTrackTitle ¶
SetTrackTitle set the title of the trk number starting from 0, isNew can be be true if it's a newadded track
type Root ¶
func (*Root) SearchGroup ¶
SearchGroup will return the group of the trk number starting from 0 it belongs to or nil if none matched. the Group will contain non-zero based indexes of the tracks (0->1)
type Track ¶
type Track struct { Title string Format WireFormat DiscFormat DiscFormat Frames int Padding int Packets []*Packet // contains filtered or unexported fields }
func (*Track) TotalBytes ¶
type TransferType ¶
type TransferType string
const ( TtSetup TransferType = "setup" TtSend TransferType = "send" TtPoll TransferType = "poll" TtTrack TransferType = "track" )
type WireFormat ¶
type WireFormat byte