root/branches/echoaudio/src/libavc/avc_subunit_info.h

Revision 445, 1.8 kB (checked in by pieterpalmers, 17 years ago)

* name change from FreeBoB to FFADO
* replaced tabs by 4 spaces
* got rid of end-of-line spaces
* made all license and copyrights conform

library becomes LGPL, apps become GPL
explicitly state LGPL v2.1 and GPL v2 (don't like v3 draft)

copyrights are 2005-2007 Daniel & Pieter
except for the MotU stuff (C) Jonathan, Pieter

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
Line 
1 /*
2  * Copyright (C) 2005-2007 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 library is free software; you can redistribute it and/or
10  * modify it under the terms of the GNU Lesser General Public
11  * License version 2.1, as published by the Free Software Foundation;
12  *
13  * This library is distributed in the hope that it will be useful,
14  * but WITHOUT ANY WARRANTY; without even the implied warranty of
15  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
16  * Lesser General Public License for more details.
17  *
18  * You should have received a copy of the GNU Lesser General Public
19  * License along with this library; if not, write to the Free Software
20  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
21  * MA 02110-1301 USA
22  */
23
24 #ifndef AVCSUBUNITINFO_H
25 #define AVCSUBUNITINFO_H
26
27 #include "avc_generic.h"
28
29 #include <libavc1394/avc1394.h>
30
31
32 // No extended subunit queries supported
33
34 class SubUnitInfoCmd: public AVCCommand
35 {
36 public:
37     SubUnitInfoCmd( Ieee1394Service& ieee1349service );
38     virtual ~SubUnitInfoCmd();
39
40     virtual bool serialize( IOSSerialize& se );
41     virtual bool deserialize( IISDeserialize& de );
42
43     virtual const char* getCmdName() const
44     { return "SubUnitInfoCmd"; }
45
46     bool clear();
47
48     page_t           m_page;
49     extension_code_t m_extension_code;
50
51
52
53     enum {
54     eMaxSubunitsPerPage = 4,
55     eMaxSubunitsPerUnit = 32,
56     };
57
58     struct TableEntry {
59     subunit_type_t   m_subunit_type;
60     max_subunit_id_t m_max_subunit_id;
61     };
62
63     struct TableEntry m_table[eMaxSubunitsPerPage];
64
65     short getMaxNoOfPages()
66     { return eMaxSubunitsPerUnit / eMaxSubunitsPerPage; }
67
68
69     short            m_nrOfValidEntries;
70     short getNrOfValidEntries()
71     { return m_nrOfValidEntries; }
72
73 };
74
75
76 #endif // AVCSUBUNITINFO_H
Note: See TracBrowser for help on using the browser.