root/trunk/libffado/src/rme/fireface_settings_ctrls.h

Revision 1600, 2.1 kB (checked in by jwoithe, 14 years ago)

RME: put setting control type defines in a more intelligent place. Add a separate type to denote an unset type field.
RME: Export a "model" info control to report the model via dbus (to be used by ffadomixer). Handle unknown control types in set/get methods.

Line 
1 /*
2  * Copyright (C) 2009 by Jonathan Woithe
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 "debugmodule/debugmodule.h"
25
26 #include "libcontrol/BasicElements.h"
27 #include "libcontrol/MatrixMixer.h"
28
29 namespace Rme {
30
31 #define RME_CTRL_NONE                  0x0000
32 #define RME_CTRL_PHANTOM_SW            0x0001
33 #define RME_CTRL_SPDIF_INPUT_MODE      0x0002
34 #define RME_CTRL_SPDIF_OUTPUT_OPTIONS  0x0003
35 #define RME_CTRL_CLOCK_MODE            0x0004
36 #define RME_CTRL_SYNC_REF              0x0005
37 #define RME_CTRL_DEV_OPTIONS           0x0006
38 #define RME_CTRL_LIMIT_BANDWIDTH       0x0007
39 #define RME_CTRL_INPUT_LEVEL           0x0008
40 #define RME_CTRL_OUTPUT_LEVEL          0x0009
41 #define RME_CTRL_INSTRUMENT_OPTIONS    0x000a
42 #define RME_CTRL_WCLK_SINGLE_SPEED     0x000b
43 #define RME_CTRL_PHONES_LEVEL          0x000c
44 #define RME_CTRL_INPUT0_OPTIONS        0x000d
45 #define RME_CTRL_INPUT1_OPTIONS        0x000e
46 #define RME_CTRL_INPUT2_OPTIONS        0x000f
47
48 #define RME_CTRL_INFO_MODEL            0x0100
49
50 class Device;
51
52 class RmeSettingsCtrl
53     : public Control::Discrete
54 {
55 public:
56     RmeSettingsCtrl(Device &parent, unsigned int type, unsigned int info);
57     RmeSettingsCtrl(Device &parent, unsigned int type, unsigned int info,
58         std::string name, std::string label, std::string descr);
59     virtual bool setValue(int v);
60     virtual int getValue();
61
62 protected:
63     Device &m_parent;
64     unsigned int m_type;
65     unsigned int m_value, m_info;
66 };
67
68 }
Note: See TracBrowser for help on using the browser.