OLE Developer Guide
Latest Git
•
All
Data Structures
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Macros
Modules
Pages
rdm_model.h
Go to the documentation of this file.
1
/*
2
* This library is free software; you can redistribute it and/or
3
* modify it under the terms of the GNU Lesser General Public
4
* License as published by the Free Software Foundation; either
5
* version 2.1 of the License, or (at your option) any later version.
6
*
7
* This library is distributed in the hope that it will be useful,
8
* but WITHOUT ANY WARRANTY; without even the implied warranty of
9
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
10
* Lesser General Public License for more details.
11
*
12
* You should have received a copy of the GNU Lesser General Public
13
* License along with this library; if not, write to the Free Software
14
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
15
*
16
* rdm_model.h
17
* Copyright (C) 2015 Simon Newton
18
*/
19
41
#ifndef FIRMWARE_SRC_RDM_MODEL_H_
42
#define FIRMWARE_SRC_RDM_MODEL_H_
43
44
#include <stdbool.h>
45
#include <stdint.h>
46
#include "
rdm_frame.h
"
47
48
#ifdef __cplusplus
49
extern
"C"
{
50
#endif
51
56
typedef
enum
{
57
NULL_MODEL_ID
= 0x0000,
58
62
LED_MODEL_ID
= 0x0100,
63
67
PROXY_MODEL_ID
= 0x0101,
68
72
MOVING_LIGHT_MODEL_ID
= 0x0102,
73
77
SENSOR_MODEL_ID
= 0x0103,
78
82
NETWORK_MODEL_ID
= 0x0104,
83
87
DIMMER_MODEL_ID
= 0x0105,
88
92
PROXY_CHILD_MODEL_ID
= 0x0106,
93
}
ResponderModel
;
94
101
typedef
enum
{
108
IOCTL_GET_UID
,
109
}
ModelIoctl
;
110
116
typedef
struct
{
117
uint16_t
model_id
;
118
124
void (*activate_fn)();
125
132
void (*deactivate_fn)();
133
142
int (*ioctl_fn)(
ModelIoctl
command, uint8_t *data,
unsigned
int
length);
143
152
int (*request_fn)(
const
RDMHeader *header,
const
uint8_t *param_data);
153
159
void (*tasks_fn)();
160
}
ModelEntry
;
161
162
#ifdef __cplusplus
163
}
164
#endif
165
170
#endif // FIRMWARE_SRC_RDM_MODEL_H_
ResponderModel
ResponderModel
The Model IDs.
Definition:
rdm_model.h:56
SENSOR_MODEL_ID
A responder that contains only sensors.
Definition:
rdm_model.h:77
PROXY_CHILD_MODEL_ID
A responder that sits behind the PROXY_MODEL_ID device.
Definition:
rdm_model.h:92
IOCTL_GET_UID
Copies the model's UID into the data pointer.
Definition:
rdm_model.h:108
NULL_MODEL_ID
No model set.
Definition:
rdm_model.h:57
DIMMER_MODEL_ID
A responder that acts as a dimmer with sub-devices.
Definition:
rdm_model.h:87
PROXY_MODEL_ID
A responder that acts as a proxy.
Definition:
rdm_model.h:67
MOVING_LIGHT_MODEL_ID
A responder that acts a moving light.
Definition:
rdm_model.h:72
rdm_frame.h
Remote Device Management.
ModelEntry
The function table entry for a particular responder model.
Definition:
rdm_model.h:116
ModelIoctl
ModelIoctl
Model ioctl enums.
Definition:
rdm_model.h:101
LED_MODEL_ID
A LED driver model.
Definition:
rdm_model.h:62
ModelEntry::model_id
uint16_t model_id
The model ID.
Definition:
rdm_model.h:117
NETWORK_MODEL_ID
A responder that presents network interfaces.
Definition:
rdm_model.h:82
firmware
src
rdm_model.h
Generated on Wed Aug 1 2018 03:17:48 for OLE Developer Guide by
1.8.8