root/branches/libffado-2.0/src/bebob/edirol/edirol_fa101.cpp

Revision 1371, 2.1 kB (checked in by ppalmers, 15 years ago)

* implement our own code to do FCP transactions. the code from libavc had too much side-effects.
* remove libavc1394 as a dependency
* set the SPLIT_TIMEOUT value for the host controller such that late responses by the DM1x00 based devices are not discarded. Should fix the issues with FA-101 discovery. (re:
#155, #162)

Line 
1 /*
2  * Copyright (C) 2008 by Daniel Wagner
3  *
4  * This file is part of FFADO
5  * FFADO = Free Firewire (pro-)audio drivers for linux
6  *
7  * FFADO is based upon FreeBoB.
8  *
9  * This program is free software: you can redistribute it and/or modify
10  * it under the terms of the GNU General Public License as published by
11  * the Free Software Foundation, either version 2 of the License, or
12  * (at your option) version 3 of the License.
13  *
14  * This program is distributed in the hope that it will be useful,
15  * but WITHOUT ANY WARRANTY; without even the implied warranty of
16  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
17  * GNU General Public License for more details.
18  *
19  * You should have received a copy of the GNU General Public License
20  * along with this program.  If not, see <http://www.gnu.org/licenses/>.
21  *
22  */
23
24 #include "edirol_fa101.h"
25
26 namespace BeBoB {
27 namespace Edirol {
28
29 EdirolFa101Device::EdirolFa101Device( DeviceManager& d,
30                                       std::auto_ptr<ConfigRom>( configRom ))
31     : BeBoB::AvDevice( d , configRom)
32 {
33     debugOutput( DEBUG_LEVEL_VERBOSE, "Created BeBoB::Edirol::EdirolFa101Device (NodeID %d)\n",
34                  getConfigRom().getNodeId() );
35
36     m_fixed_clocksource.type = FFADODevice::eCT_Auto;
37     m_fixed_clocksource.valid = true;
38     m_fixed_clocksource.locked = true;
39     m_fixed_clocksource.id = 0;
40     m_fixed_clocksource.slipping = false;
41     m_fixed_clocksource.description = "Device Controlled";
42 }
43
44 EdirolFa101Device::~EdirolFa101Device()
45 {
46 }
47
48 FFADODevice::ClockSource
49 EdirolFa101Device::getActiveClockSource() {
50     return m_fixed_clocksource;
51 }
52
53 bool
54 EdirolFa101Device::setActiveClockSource(ClockSource s) {
55     // can't change, hence only succeed when identical
56     return s.id == m_fixed_clocksource.id;
57 }
58
59 FFADODevice::ClockSourceVector
60 EdirolFa101Device::getSupportedClockSources() {
61     FFADODevice::ClockSourceVector r;
62     r.push_back(m_fixed_clocksource);
63     return r;
64 }
65
66 void
67 EdirolFa101Device::showDevice()
68 {
69     debugOutput(DEBUG_LEVEL_VERBOSE, "This is a BeBoB::EdirolFa101::EdirolFa101Device\n");
70     BeBoB::AvDevice::showDevice();
71 }
72
73 }
74 }
Note: See TracBrowser for help on using the browser.