-
Notifications
You must be signed in to change notification settings - Fork 1
/
Commands.h
47 lines (33 loc) · 2.57 KB
/
Commands.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
//----------------------------------------------------------------------------
//Модуль реализации выполнения команд Wake: header file
//----------------------------------------------------------------------------
#ifndef CommandsH
#define CommandsH
#include "Port.h"
#include "Wake.h"
//-------------------------------- Константы: --------------------------------
//Коды специальных команд:
#define powerButton 0x21 /**< Питание (вкл/выкл) (1/0) */
#define lightButton 0x22 /**< Свет (вкл/выкл) (1/0) */
#define powerStatus 0x41 /**< Питание (вкл/выкл) (1/0) */
#define lightStatus 0x42 /**< Свет (вкл/выкл) (1/0) */
#define soundSignal 0x23 /**< Гудок (вкл/выкл) (1/0) */
#define speedButton 0x24 /**< Скорость (медленно/быстро) (0/1..9) */
#define highTemperature 0x31 /**< Перегрев ОЖ (нет/есть) (0/1) */
#define hookWarning 0x32 /**< Ограничитель подъема (срабатывание/норм.работа) (1/0) */
#define modeCrOrP 0x51 /**< Режим работы - Опоры или Cтойка, стрела, лебедка (1/0) */
#define modeCrOrPStatus 0x52 /**< Режим работы - Опоры или Cтойка, стрела, лебедка (1/0) */
#define pillar 0x25 /**< Поворот стойки (-128..127) */
#define derrick 0x27 /**< Подъемная стрела (-128..127) */
#define outrigger 0x29 /**< Выносная стрела (-128..127) */
#define telescopic 0x2B /**< Телескопическая стрела (-128..127) */
#define hook 0x2D /**< Лебедка(крюк) (-128..127) */
#define leftCrutch 0x2F /**< Левая опора (-128..127) */
#define rightCrutch 0x2E /**< Правая опора (-128..127) */
#define SEND_REPLY 0 /**< Отправлять ответ на команды управления элементами КМУ*/
//----------------------------------------------------------------------------
//---------------------------- Прототипы функций: ----------------------------
void Commands_Exe(void); //выполнение команд
void Tx_Replay(char n, char err); //передача ответа на команду
//----------------------------------------------------------------------------
#endif