MythTV  master
Classes | Namespaces | Macros | Functions | Variables
darwinfirewiredevice.cpp File Reference
#include <pthread.h>
#include <IOKit/IOMessage.h>
#include <IOKit/IOKitLib.h>
#include <IOKit/firewire/IOFireWireLib.h>
#include <IOKit/firewire/IOFireWireLibIsoch.h>
#include <IOKit/firewire/IOFireWireFamilyCommon.h>
#include <IOKit/avc/IOFireWireAVCLib.h>
#include <CoreServices/CoreServices.h>
#include <algorithm>
#include <vector>
#include "libmythbase/mthread.h"
#include "libmythbase/mythlogging.h"
#include "libmythbase/mythtimer.h"
#include "darwinavcinfo.h"
#include "darwinfirewiredevice.h"
#include <AVCVideoServices/StringLogger.h>
#include <AVCVideoServices/AVSShared.h>
#include <AVCVideoServices/MPEG2Receiver.h>
Include dependency graph for darwinfirewiredevice.cpp:

Go to the source code of this file.


class  DFDPriv


 DarwinFirewireChannel Copyright (c) 2005 by Jim Westfall SA3250HD support Copyright (c) 2005 by Matt Porter Copyright (c) 2006 by Dave Abrahams Distributed as part of MythTV under GPL v2 and later.


#define LOC   QString("DFireDev(%1): ").arg(guid_to_string(m_guid))
#define kAnyAvailableIsochChannel   0xFFFFFFFF


IOReturn AVS::CreateMPEG2Receiver (MPEG2Receiver **ppReceiver, DataPushProc dataPushProcHandler, void *pDataPushProcRefCon=nil, MPEG2ReceiverMessageProc messageProcHandler=nil, void *pMessageProcRefCon=nil, StringLogger *stringLogger=nil, IOFireWireLibNubRef nubInterface=nil, unsigned int cyclesPerSegment=kCyclesPerReceiveSegment, unsigned int numSegments=kNumReceiveSegments, bool doIRMAllocations=false)
IOReturn AVS::DestroyMPEG2Receiver (MPEG2Receiver *pReceiver)
static IOReturn dfd_tspacket_handler_thunk (UInt32 tsPacketCount, UInt32 **ppBuf, void *callback_data)
static void dfd_update_device_list (void *dfd, io_iterator_t deviter)
static void dfd_streaming_log_message (char *msg)
void * dfd_controller_thunk (void *callback_data)
void dfd_stream_msg (UInt32 msg, UInt32 param1, UInt32 param2, void *callback_data)
int dfd_no_data_notification (void *callback_data)
void dfd_update_device_list_item (DarwinFirewireDevice *dev, uint64_t guid, void *item)
int dfd_tspacket_handler (uint tsPacketCount, uint32_t **ppBuf, void *callback_data)


static constexpr std::chrono::milliseconds kNoDataTimeout { 300ms }
static constexpr std::chrono::milliseconds kResetTimeout { 1500ms }

Macro Definition Documentation


#define LOC   QString("DFireDev(%1): ").arg(guid_to_string(m_guid))

Definition at line 58 of file darwinfirewiredevice.cpp.

◆ kAnyAvailableIsochChannel

#define kAnyAvailableIsochChannel   0xFFFFFFFF

Definition at line 60 of file darwinfirewiredevice.cpp.

Function Documentation

◆ dfd_tspacket_handler_thunk()

static IOReturn dfd_tspacket_handler_thunk ( UInt32  tsPacketCount,
UInt32 **  ppBuf,
void *  callback_data 

Definition at line 933 of file darwinfirewiredevice.cpp.

Referenced by DarwinFirewireDevice::OpenAVStream().

◆ dfd_update_device_list()

static void dfd_update_device_list ( void *  dfd,
io_iterator_t  deviter 

Definition at line 940 of file darwinfirewiredevice.cpp.

Referenced by DarwinFirewireDevice::RunController().

◆ dfd_streaming_log_message()

static void dfd_streaming_log_message ( char *  msg)

Definition at line 964 of file darwinfirewiredevice.cpp.

Referenced by DFDPriv::DFDPriv().

◆ dfd_controller_thunk()

void * dfd_controller_thunk ( void *  callback_data)

Definition at line 891 of file darwinfirewiredevice.cpp.

◆ dfd_stream_msg()

void dfd_stream_msg ( UInt32  msg,
UInt32  param1,
UInt32  param2,
void *  callback_data 

Definition at line 913 of file darwinfirewiredevice.cpp.

◆ dfd_no_data_notification()

int dfd_no_data_notification ( void *  callback_data)

Definition at line 905 of file darwinfirewiredevice.cpp.

◆ dfd_update_device_list_item()

void dfd_update_device_list_item ( DarwinFirewireDevice dev,
uint64_t  guid,
void *  item 

Definition at line 899 of file darwinfirewiredevice.cpp.

Referenced by dfd_update_device_list().

◆ dfd_tspacket_handler()

int dfd_tspacket_handler ( uint  tsPacketCount,
uint32_t **  ppBuf,
void *  callback_data 

Definition at line 920 of file darwinfirewiredevice.cpp.

Referenced by dfd_tspacket_handler_thunk().

Variable Documentation

◆ kNoDataTimeout

constexpr std::chrono::milliseconds kNoDataTimeout { 300ms }

◆ kResetTimeout

constexpr std::chrono::milliseconds kResetTimeout { 1500ms }

Definition at line 62 of file darwinfirewiredevice.cpp.

Referenced by DarwinFirewireDevice::ProcessNoDataMessage().