parameters.h 37 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470
  1. /********************************* (C) РОТЕК ***********************************
  2. * @module parameters
  3. * @file parameters.h
  4. * @version 1.0.0
  5. * @date XX.XX.XXXX
  6. * $brief parameters
  7. *******************************************************************************
  8. * @history Version Author Comment
  9. * XX.XX.XXXX 1.0.0 Telenkov D.A. First release.
  10. *******************************************************************************
  11. */
  12. /* Define to prevent recursive ----------------------------------------------*/
  13. #ifndef PARAMETERS_H
  14. #define PARAMETERS_H
  15. #include <stdbool.h>
  16. #include "common_config.h"
  17. /**
  18. * @brief
  19. */
  20. bool GetRebootStatus(void);
  21. // ************************************************************************** //
  22. // Параметры UPS
  23. void GetInputFreqStr(char *str, uint8_t *len);
  24. void GetInputFreqInt(float *value);
  25. void GetOutputFreqStr(char *str, uint8_t *len);
  26. void GetInputVoltageStr(char *str, uint8_t *len);
  27. void GetInputVoltageInt(float *value);
  28. void GetOutputVoltageStr(char *str, uint8_t *len);
  29. void GetOutputVoltageInt(float *value);
  30. void GetPowerStr(char *str, uint8_t *len);
  31. void GetPowerInt(int32_t *value);
  32. void GetLoadAKBModeStr(char *str, uint8_t *len);
  33. void GetLoadAKBModeInt(int32_t *value);
  34. void GetDataCheckLoadStr(char *str, uint8_t *len);
  35. void GetDataFormatCheckLoadStr(char *str, uint8_t *len);
  36. void GetBatCapacityStr(char *str, uint8_t *len);
  37. void GetBatCapacityInt(int32_t *value);
  38. void GetRuntimeStr(char *str, uint8_t *len);
  39. void GetRuntimeInt(int32_t *value);
  40. void GetAKBWorktimeStr(char *str, uint8_t *len);
  41. void GetAKBWorktimeInt(int32_t *value);
  42. void GetInternalTempStr(char *str, uint8_t *len);
  43. void GetInternalTempInt(float *value);
  44. /**
  45. * @brief
  46. */
  47. void GetAlarmMonitorStr(char *str, uint8_t *len);
  48. void GetConnectMonitorStr(char *str, uint8_t *len);
  49. /**
  50. * @brief
  51. */
  52. void GetInputCurrentStr(char *str, uint8_t *len);
  53. /**
  54. * @brief
  55. */
  56. void GetInputCurrentInt(float *value);
  57. /**
  58. * @brief
  59. */
  60. void GetOutputCurrentStr(char *str, uint8_t *len);
  61. /**
  62. * @brief
  63. */
  64. void GetOutputCurrentInt(float *value);
  65. /**
  66. * @brief
  67. */
  68. void GetVoltageAKBtStr(char *str, uint8_t *len);
  69. /**
  70. * @brief
  71. */
  72. void GetVoltageAKBInt(float *value);
  73. /**
  74. * @brief Режим работы
  75. */
  76. void GetModeStr(char *str, uint8_t *len);
  77. /**
  78. * @brief Режим работы
  79. */
  80. void GetModeEn(char *str, uint8_t *len);
  81. /**
  82. * @brief Индикация аварийных ситуаций
  83. * TODO добавить реальный параметр
  84. */
  85. void GetAlarmStr(char *str, uint8_t *len);
  86. /**
  87. * @brief Индикация аварийных ситуаций
  88. */
  89. void GetUPSAlarmStr(char *str, uint8_t *len);
  90. /**
  91. * @brief Индикация аварийных ситуаций
  92. */
  93. void GetAKBAlarmStr(char *str, uint8_t *len);
  94. /**
  95. * @brief Индикация аварийных ситуаций
  96. */
  97. void GetConnectUPSAlarmStr(char *str, uint8_t *len);
  98. /**
  99. * @brief Индикация аварийных ситуаций
  100. */
  101. void GetUPSModeStr(char *str, uint8_t *len);
  102. /**
  103. * @brief Текущее время ч/м/с
  104. */
  105. void GetCurrentTimeStr(char *str, uint8_t *len);
  106. // ************************************************************************** //
  107. // Параметры даты и времени
  108. /**
  109. * @brief Дата (Ready for PRS!)
  110. */
  111. void GetDateStr(char *str, uint8_t *len);
  112. /**
  113. * @brief Время (Ready for PRS!)
  114. */
  115. void GetTimeStr(char *str, uint8_t *len);
  116. /**
  117. * @brief Время (Ready for PRS!)
  118. */
  119. void GetUnixTimeStr(char *str, uint8_t *len);
  120. // ************************************************************************** //
  121. // Параметры SNTP
  122. /**
  123. * @brief Состояние SNTP (Ready for PRS!)
  124. */
  125. void GetSntpStateStr(char *str, uint8_t *len);
  126. /**
  127. * @brief Состояние SNTP (Ready for PRS!)
  128. */
  129. void GetSntpStateStrRU(char *str, uint8_t *len);
  130. /**
  131. * @brief IP адрес SNTP сервера (Ready for PRS!)
  132. */
  133. void GetSntpServerIpStr(char *str, uint8_t *len);
  134. /**
  135. * @brief Часовой пояс контроллера (Ready for PRS!)
  136. */
  137. void GetSntpTimeZoneStr(char *str, uint8_t *len);
  138. /**
  139. * @brief Дата последней синхронизации SNTP (Ready for PRS!)
  140. */
  141. void GetSntpLastDataStr(char *str, uint8_t *len);
  142. // ************************************************************************** //
  143. // Информация
  144. // ************************************************************************** //
  145. // Настройки аутентификации
  146. void GetUserLogin(uint8_t user_id, char *str, uint8_t *len);
  147. void GetUserPassword(uint8_t user_id, char *str, uint8_t *len);
  148. void GetUserLevel(uint8_t user_id, char *str, uint8_t *len);
  149. void GetUserLevelInt(uint8_t user_id, uint8_t *value);
  150. /**
  151. * @brief Время работы устройства
  152. */
  153. void GetWorkTimeStr(char *str, uint8_t *len);
  154. /**
  155. * @brief Модель устройства
  156. */
  157. void GetModelStr(char *str, uint8_t *len);
  158. /**
  159. * @brief Название устройсва устройства
  160. */
  161. void GetNameDeviceStr(char *str, uint8_t *len);
  162. /**
  163. * @brief Дата производства
  164. */
  165. void GetProductionDataStr(char *str, uint8_t *len);
  166. /**
  167. * @brief Версия ПО
  168. */
  169. void GetVersionStr(char *str, uint8_t *len);
  170. /**
  171. * @brief MAC адрес устройства
  172. */
  173. void GetMacStr(char *str, uint8_t *len);
  174. /**
  175. * @brief Серийный номер устройства
  176. */
  177. void GetSerialNumberStr(char *str, uint8_t *len);
  178. /**
  179. * @brief Владелец устройства
  180. */
  181. void GetOwnerStr(char *str, uint8_t *len);
  182. /**
  183. * @brief Местоположение устройства
  184. */
  185. void GetLocationStr(char *str, uint8_t *len);
  186. /**
  187. * @brief Комментарии
  188. */
  189. void GetCommentsStr(char *str, uint8_t *len);
  190. /**
  191. * @brief Серийный номер UPS
  192. */
  193. void GetUPSSerialStr(char *str, uint8_t *len);
  194. /**
  195. * @brief Модель UPS
  196. */
  197. void GetUPSModelStr(char *str, uint8_t *len);
  198. /**
  199. * @brief Версия UPS ПО
  200. */
  201. void GetUPSVersionStr(char *str, uint8_t *len);
  202. #ifdef NOTIFICATION_CONTROL_ENABLE
  203. // ************************************************************************** //
  204. // Параметры уведомления
  205. /**
  206. * @brief Параметр разрешения отправки трапа
  207. */
  208. void GetNotificationTrapsStateStr(char *str, uint8_t *len, uint8_t num);
  209. /**
  210. * @brief Параметр разрешения отправки трапа
  211. */
  212. void GetNotificationTrapsStateStr2(char *str, uint8_t *len, uint8_t num);
  213. /**
  214. * @brief Длинное имя трапа
  215. */
  216. void GetTrapLongNameStr(char *str, uint8_t *len, uint8_t num);
  217. #endif
  218. // ************************************************************************** //
  219. // Параметры WEB
  220. /**
  221. * @brief Текущий IP адрес
  222. */
  223. void GetIpStr(char *str, uint8_t *len);
  224. /**
  225. * @brief Текущий шлюз
  226. */
  227. void GetGatewayStr(char *str, uint8_t *len);
  228. /**
  229. * @brief Текущая маска подсети
  230. */
  231. void GetMaskStr(char *str, uint8_t *len);
  232. /**
  233. * @brief Настройка DHCP
  234. */
  235. void GetDhcpStateStr(char *str, uint8_t *len);
  236. /**
  237. * @brief Настройка DHCP
  238. */
  239. void GetDhcpStateUDP(char *str, uint8_t *len);
  240. /**
  241. * @brief Настройка DHCP
  242. */
  243. void GetDhcpStateStrRu(char *str, uint8_t *len);
  244. #ifdef WHITELIST_ENABLE
  245. // ************************************************************************** //
  246. // Параметры довверительных хостов
  247. /**
  248. * @brief диапазон доверительных хостов
  249. */
  250. void GetWhiteListSTR(char *str, uint8_t *len, uint8_t num);
  251. /**
  252. * @brief первый диапазон доверительных хостов
  253. */
  254. void GetWhiteList1STR(char *str, uint8_t *len);
  255. /**
  256. * @brief второй диапазон доверительных хостов
  257. */
  258. void GetWhiteList2STR(char *str, uint8_t *len);
  259. /**
  260. * @brief третий диапазон доверительных хостов
  261. */
  262. void GetWhiteList3STR(char *str, uint8_t *len);
  263. /**
  264. * @brief четвертый диапазон доверительных хостов
  265. */
  266. void GetWhiteList4STR(char *str, uint8_t *len);
  267. /**
  268. * @brief пятый диапазон доверительных хостов
  269. */
  270. void GetWhiteList5STR(char *str, uint8_t *len);
  271. /**
  272. * @brief маска диапазона доверительных хостов
  273. */
  274. void GetWhiteListMask(uint32_t *value, uint8_t num);
  275. /**
  276. * @brief ip диапазона доверительных хостов
  277. */
  278. void GetWhiteListIP(uint32_t *value, uint8_t num);
  279. #endif
  280. #ifdef PORTGW_ENABLE
  281. // ************************************************************************** //
  282. // Параметры прозрачного порта
  283. /**
  284. * @brief Включен/Выключен
  285. */
  286. void GetPortGwEnabledStr(char *str, uint8_t *len);
  287. /**
  288. * @brief Включен/Выключен
  289. */
  290. void GetPortGwEnabledRUStr(char *str, uint8_t *len);
  291. /**
  292. * @brief Четность
  293. */
  294. void GetPortGwParityRUStr(char *str, uint8_t *len);
  295. /**
  296. * @brief Четность
  297. */
  298. void GetPortGwParityInt(uint32_t *value);
  299. /**
  300. * @brief IP-адрес
  301. */
  302. void GetPortGwIpStr(char *str, uint8_t *len);
  303. /**
  304. * @brief Сетевой порт
  305. */
  306. void GetPortGwPortnumStr(char *str, uint8_t *len);
  307. /**
  308. * @brief Скорость передачи данных
  309. */
  310. void GetPortGwBaudStr(char *str, uint8_t *len);
  311. /**
  312. * @brief Четность
  313. */
  314. void GetPortGwParityStr(char *str, uint8_t *len);
  315. /**
  316. * @brief Число бит данных
  317. */
  318. void GetPortGwDatabitsStr(char *str, uint8_t *len);
  319. /**
  320. * @brief Число стоп-бит
  321. */
  322. void GetPortGwStopbitsStr(char *str, uint8_t *len);
  323. #endif
  324. #if defined(DALLAS_SENSOR_ENABLE) || defined(AM2301_SENSOR_ENABLE)
  325. // ************************************************************************** //
  326. // Параметры датчика температуры
  327. /**
  328. * @brief Размещение датчика температуры 1
  329. */
  330. void GetTS1locationStr(char *str, uint8_t *len);
  331. /**
  332. * @brief Размещение датчика температуры 2
  333. */
  334. void GetTS2locationStr(char *str, uint8_t *len);
  335. /**
  336. * @brief Размещение датчика температуры
  337. */
  338. void GetTSlocationStr(char *str, uint8_t *len, uint8_t num);
  339. #endif
  340. // ************************************************************************** //
  341. // Параметры SNMP
  342. /**
  343. * @brief Текущее TRAP community
  344. */
  345. void GetTrapCommunity(char *str, uint8_t *len);
  346. /**
  347. * @brief Текущее community для чтения
  348. */
  349. void GetReadCommunity(char *str, uint8_t *len);
  350. /**
  351. * @brief Текущее community для записи
  352. */
  353. void GetWriteCommunity(char *str, uint8_t *len);
  354. /**
  355. * @brief IP SNMP менеджера
  356. */
  357. void GetManagerIp(char *str, uint8_t *len);
  358. void GetManagerIp2(char *str, uint8_t *len);
  359. void GetManagerIp3(char *str, uint8_t *len);
  360. void GetManagerIp4(char *str, uint8_t *len);
  361. void GetManagerIp5(char *str, uint8_t *len);
  362. #ifdef RADIUS_SERVER_ENABLE
  363. // ************************************************************************** //
  364. // Параметры RADIUS
  365. /**
  366. * @brief Текущий IP адрес
  367. */
  368. void GetRDSIpStr(char *str, uint8_t *len);
  369. /**
  370. * @brief Текущий Порт
  371. */
  372. void GetRDSPortStr(char *str, uint8_t *len);
  373. /**
  374. * @brief Текущий Код access
  375. */
  376. void GetRDSKeyAccesstStr(char *str, uint8_t *len);
  377. /**
  378. * @brief Текущая пароль RADIUS
  379. */
  380. void GetRDSPasswordkStr(char *str, uint8_t *len);
  381. /**
  382. * @brief Настройка вкл/ выкл RADIUS сервера
  383. */
  384. void GetRDSEnableStateStr(char *str, uint8_t *len);
  385. void GetRADIUSEnableStrRU(char *str, uint8_t *len);
  386. /**
  387. * @brief Настройка вкл/ выкл авторизации
  388. */
  389. void GetAuthEnableStateStr(char *str, uint8_t *len);
  390. #endif
  391. #ifndef BT6702_SERVICE
  392. // ************************************************************************** //
  393. // Температура с внешних датчиков
  394. #if defined(DALLAS_SENSOR_ENABLE) || defined(AM2301_SENSOR_ENABLE)
  395. /**
  396. * @brief
  397. */
  398. void GetTempCaseStr(char *str, uint8_t *len);
  399. /**
  400. * @brief
  401. */
  402. void GetTempCaseInt(float *value);
  403. #endif
  404. #ifdef AM2301_SENSOR_ENABLE
  405. void GetHumidityCaseStr(char *str, uint8_t *len);
  406. #endif
  407. #endif
  408. // ************************************************************************** //
  409. // Параметры реле/сухих контактов
  410. #ifdef DINS_ENABLE
  411. /**
  412. * @brief Тип действий при срабатывание сухих контактов
  413. */
  414. void GetDINTypeActStr(char *str, uint8_t *len, uint8_t num);
  415. /**
  416. * @brief Тип действий при срабатывание сухих контактов
  417. */
  418. void GetDIN0TypeActStr(char *str, uint8_t *len);
  419. /**
  420. * @brief Тип действий при срабатывание сухих контактов
  421. */
  422. void GetDIN1TypeActStr(char *str, uint8_t *len);
  423. /**
  424. * @brief Имя сухого контакта
  425. */
  426. void GetDINNameStr(char *str, uint8_t *len, uint8_t num);
  427. /**
  428. * @brief Имя сухого контакта
  429. */
  430. void GetDIN0NameStr(char *str, uint8_t *len);
  431. /**
  432. * @brief Имя сухого контакта
  433. */
  434. void GetDIN1NameStr(char *str, uint8_t *len);
  435. /**
  436. * @brief Состояние сухого контакта
  437. */
  438. void GetDINStatusStr(char *str, uint8_t *len, uint8_t num);
  439. /**
  440. * @brief Состояние сухого контакта
  441. */
  442. void GetDIN0StatusStr(char *str, uint8_t *len);
  443. /**
  444. * @brief Состояние сухого контакта
  445. */
  446. void GetDIN1StatusStr(char *str, uint8_t *len);
  447. /**
  448. * @brief Состояние сухого контакта
  449. */
  450. void GetDINStatusStrRU(char *str, uint8_t *len, uint8_t num);
  451. #endif
  452. #ifdef DOUTS_ENABLE
  453. /**
  454. * @brief Источник срабатывания реле
  455. */
  456. void GetROTypeActStr(char *str, uint8_t *len, uint8_t num);
  457. /**
  458. * @brief Источник срабатывания реле
  459. */
  460. void GetRO0TypeActStr(char *str, uint8_t *len);
  461. /**
  462. * @brief Источник срабатывания реле
  463. */
  464. void GetRO1TypeActStr(char *str, uint8_t *len);
  465. /**
  466. * @brief Источник срабатывания реле
  467. */
  468. void GetRO2TypeActStr(char *str, uint8_t *len);
  469. /**
  470. * @brief Состояние релейного выхода
  471. */
  472. void GetDOUTStatusStr(char *str, uint8_t *len, uint8_t num);
  473. /**
  474. * @brief Состояние релейного выхода
  475. */
  476. void GetDOUTStatusStrRU(char *str, uint8_t *len, uint8_t num);
  477. /**
  478. * @brief Состояние релейного выхода
  479. */
  480. void GetDOUT0StatusStr(char *str, uint8_t *len);
  481. /**
  482. * @brief Состояние релейного выхода
  483. */
  484. void GetDOUT1StatusStr(char *str, uint8_t *len);
  485. /**
  486. * @brief Состояние релейного выхода
  487. */
  488. void GetDOUT2StatusStr(char *str, uint8_t *len);
  489. #endif
  490. #ifdef TELNET_ENABLE
  491. // ************************************************************************** //
  492. // Параметры Telnet
  493. /**
  494. * @brief Текущий Порт
  495. */
  496. void GetTelnetPortStr(char *str, uint8_t *len);
  497. /**
  498. * @brief Настройка вкл/ выкл Telnet сервера
  499. */
  500. void GetTelnetEnableStateStr(char *str, uint8_t *len);
  501. // ************************************************************************** //
  502. // Параметры SSH
  503. /**
  504. * @brief Текущий Порт
  505. */
  506. void GetSSHPortStr(char *str, uint8_t *len);
  507. /**
  508. * @brief Настройка вкл/ выкл SSH сервера
  509. */
  510. void GetSSHEnableStateStr(char *str, uint8_t *len);
  511. #endif
  512. #ifdef FTP_ENABLE
  513. // ************************************************************************** //
  514. // Параметры FTP
  515. void GetFTPServer(char *str, uint8_t *len);
  516. void GetFTPPort(char *str, uint8_t *len);
  517. void GetFTPPath(char *str, uint8_t *len);
  518. void GetFTPLogin(char *str, uint8_t *len);
  519. void GetFTPPassword(char *str, uint8_t *len);
  520. // ************************************************************************** //
  521. // Параметры Syslog
  522. void GetSyslogEnable(char *str, uint8_t *len);
  523. void GetSyslogEnableStrRU(char *str, uint8_t *len);
  524. void GetSyslogServer(char *str, uint8_t *len);
  525. void GetSyslogPort(char *str, uint8_t *len);
  526. #endif // FTP_ENABLE
  527. // ************************************************************************** //
  528. // Флаги
  529. /**
  530. * @brief Установить признак изменения сетевых параметров
  531. */
  532. void GetWebReinitFlag(char *str, uint8_t *len);
  533. // ************************************************************************** //
  534. // Параметры настройки ИБП
  535. /**
  536. * @brief Минимальное напряжение на ячейках АКБ
  537. */
  538. void GetUPSVoltCellMinStr(char *str, uint8_t *len);
  539. /**
  540. * @brief Минимальное напряжение на ячейках АКБ
  541. */
  542. void GetUPSVoltCellMinInt(float *value);
  543. /**
  544. * @brief Максимальное напряжение на ячейках АКБ
  545. */
  546. void GetUPSVoltCellMaxStr(char *str, uint8_t *len);
  547. /**
  548. * @brief Максимальное напряжение на ячейках АКБ
  549. */
  550. void GetUPSVoltCellMaxInt(float *value);
  551. /**
  552. * @brief Дата замены АКБ
  553. */
  554. void GetDataNextChangeAKBStrRU(char *str, uint8_t *len);
  555. /**
  556. * @brief Дата замены АКБ
  557. */
  558. void GetDataNextChangeAKBStr(char *str, uint8_t *len);
  559. /**
  560. * @brief Дата установки АКБ
  561. */
  562. void GetDataSetAKBStr(char *str, uint8_t *len);
  563. /**
  564. * @brief Срок службы АКБ
  565. */
  566. void GetLifeTimeAKBStr(char *str, uint8_t *len);
  567. /**
  568. * @brief Номинальное напряжение АКБ
  569. */
  570. void GetVoltageAKBNominalStr(char *str, uint8_t *len);
  571. /**
  572. * @brief Полная мощность АКБ
  573. */
  574. void GetUPSPowerStr(char *str, uint8_t *len);
  575. /**
  576. * @brief Полная мощность АКБ
  577. */
  578. void GetUPSPowerEnumStr(char *str, uint8_t *len);
  579. /**
  580. * @brief КПД ИБП
  581. */
  582. void GetUPSEfficiencyFactorInt(float *value);
  583. /**
  584. * @brief Емкость АКБ
  585. */
  586. void GetCapacityNominalAKBStr(char *str, uint8_t *len);
  587. /**
  588. * @brief Емкость АКБ
  589. */
  590. void GetCapacityNominalAKBInt(int32_t *value);
  591. // ************************************************************************** //
  592. // Параметры менеджера аварийных событий
  593. /**
  594. * @brief Верхняя граница VAC
  595. */
  596. void GetVACAlarmHighRangeStr(char *str, uint8_t *len);
  597. /**
  598. * @brief Верхняя граница VAC
  599. */
  600. void GetVACAlarmHighRangeInt(int32_t *value);
  601. /**
  602. * @brief Нижняя граница VAC
  603. */
  604. void GetVACAlarmLowRangeStr(char *str, uint8_t *len);
  605. /**
  606. * @brief Нижняя граница VAC
  607. */
  608. void GetVACAlarmLowRangeInt(int32_t *value);
  609. /**
  610. * @brief Гистерезис (VAC)
  611. */
  612. void GetVACAlarmHisteStr(char *str, uint8_t *len);
  613. /**
  614. * @brief Гистерезис (VAC)
  615. */
  616. void GetVACAlarmHisteInt(float *value);
  617. #ifdef VAC_IN_MONITOR
  618. /**
  619. * @brief Верхняя граница входящего напряжения
  620. */
  621. void GetVACInputAlarmHighRangeStr(char *str, uint8_t *len);
  622. /**
  623. * @brief Верхняя граница входящего напряжения
  624. */
  625. void GetVACInputAlarmHighRangeInt(int32_t *value);
  626. /**
  627. * @brief Нижняя граница входящего напряжения
  628. */
  629. void GetVACInputAlarmLowRangeStr(char *str, uint8_t *len);
  630. /**
  631. * @brief Нижняя граница входящего напряжения
  632. */
  633. void GetVACInputAlarmLowRangeInt(int32_t *value);
  634. /**
  635. * @brief Гистерезис входящего напряжения
  636. */
  637. void GetVACinputAlarmHisteStr(char *str, uint8_t *len);
  638. /**
  639. * @brief Гистерезис входящего напряжения
  640. */
  641. void GetVACinputAlarmHisteInt(float *value);
  642. #endif
  643. /**
  644. * @brief Верхняя граница температуры
  645. */
  646. void GetTemperatureAlarmHighRangeStr(char *str, uint8_t *len);
  647. /**
  648. * @brief Верхняя граница температуры
  649. */
  650. void GetTemperatureAlarmHighRangeInt(int32_t *value);
  651. /**
  652. * @brief Нижняя граница температуры
  653. */
  654. void GetTemperatureAlarmLowRangeStr(char *str, uint8_t *len);
  655. /**
  656. * @brief Нижняя граница температуры
  657. */
  658. void GetTemperatureAlarmLowRangeInt(int32_t *value);
  659. /**
  660. * @brief Гистерезис (температура)
  661. */
  662. void GetTemperatureAlarmHisteStr(char *str, uint8_t *len);
  663. /**
  664. * @brief Гистерезис (температура)
  665. */
  666. void GetTemperatureAlarmHisteInt(float *value);
  667. #if !(HARDWARE_BT6709 || HARDWARE_BT6709_MTS)
  668. /**
  669. * @brief Верхняя граница температуры
  670. */
  671. void GetTemperatureCabinetAlarmHighRangeStr(char *str, uint8_t *len);
  672. /**
  673. * @brief Верхняя граница температуры
  674. */
  675. void GetTemperatureCabinetAlarmHighRangeInt(int32_t *value);
  676. /**
  677. * @brief Нижняя граница температуры
  678. */
  679. void GetTemperatureCabinetAlarmLowRangeStr(char *str, uint8_t *len);
  680. /**
  681. * @brief Нижняя граница температуры
  682. */
  683. void GetTemperatureCabinetAlarmLowRangeInt(int32_t *value);
  684. /**
  685. * @brief Гистерезис (температура)
  686. */
  687. void GetTemperatureCabinetAlarmHisteStr(char *str, uint8_t *len);
  688. /**
  689. * @brief Гистерезис (температура)
  690. */
  691. void GetTemperatureCabinetAlarmHisteInt(float *value);
  692. #endif
  693. /**
  694. * @brief Верхняя граница нагрузки
  695. */
  696. void GetLoadAlarmHighRangeStr(char *str, uint8_t *len);
  697. /**
  698. * @brief Верхняя граница нагрузки
  699. */
  700. void GetLoadAlarmHighRangeInt(int32_t *value);
  701. /**
  702. * @brief Гистерезис (нагрузки)
  703. */
  704. void GetLoadAlarmHisteStr(char *str, uint8_t *len);
  705. /**
  706. * @brief Гистерезис (нагрузки)
  707. */
  708. void GetLoadAlarmHisteInt(float *value);
  709. // ************************************************************************** //
  710. // Установка параметрв
  711. // ************************************************************************** //
  712. /**
  713. * @brief Установить признак обновления ПО.
  714. */
  715. void SetLoadMode(void);
  716. /**
  717. * @brief Установить признак изменения сетевых параметров
  718. */
  719. void SetWebReinitFlag(bool value);
  720. /**
  721. * @brief Установить флаг подтверждения сетевых настроек пользователем
  722. */
  723. void SetConfirmWebParamsFlag(void);
  724. #ifdef NOTIFICATION_CONTROL_ENABLE
  725. // ************************************************************************** //
  726. // Параметры уведомления
  727. /**
  728. * @brief Параметр разрешения отправки
  729. */
  730. void SetNotificationFlagsStr(uint8_t *value, uint8_t num);
  731. #endif
  732. // ************************************************************************** //
  733. // Сетевые параметры
  734. /**
  735. * @brief IP адрес
  736. */
  737. void SetIPStr(char *str);
  738. /**
  739. * @brief Шлюз
  740. */
  741. void SetGatewayStr(char *str);
  742. /**
  743. * @brief Текущая маска подсети
  744. */
  745. void SetMaskStr(char *str);
  746. /**
  747. * @brief Настройка DHCP
  748. */
  749. void SetDhcpStateStr(char *str);
  750. /**
  751. * @brief Настройка DHCP
  752. */
  753. void SetUDPDhcpStateStr(char *str);
  754. #ifdef WHITELIST_ENABLE
  755. // ************************************************************************** //
  756. // Параметры довверительных хостов
  757. /**
  758. * @brief диапазон доверительных хостов
  759. */
  760. void SetWhiteListSTR(char *str, uint8_t num);
  761. /**
  762. * @brief Первый диапазон доверительных хостов
  763. */
  764. void SetWhiteList1STR(char *str);
  765. /**
  766. * @brief Второй диапазон доверительных хостов
  767. */
  768. void SetWhiteList2STR(char *str);
  769. /**
  770. * @brief Третий диапазон доверительных хостов
  771. */
  772. void SetWhiteList3STR(char *str);
  773. /**
  774. * @brief Четвертый диапазон доверительных хостов
  775. */
  776. void SetWhiteList4STR(char *str);
  777. /**
  778. * @brief Пятый диапазон доверительных хостов
  779. */
  780. void SetWhiteList5STR(char *str);
  781. #endif
  782. #ifdef PORTGW_ENABLE
  783. // ************************************************************************** //
  784. // Параметры прозрачного порта
  785. /**
  786. * @brief Включен/Выключен
  787. */
  788. void SetPortGwEnabledStr(char *str);
  789. /**
  790. * @brief Сетевой порт
  791. */
  792. void SetPortGwPortnumStr(char *str);
  793. /**
  794. * @brief Скорость передачи данных
  795. */
  796. void SetPortGwBaudStr(char *str);
  797. /**
  798. * @brief Четность
  799. */
  800. void SetPortGwParityStr(char *str);
  801. /**
  802. * @brief Четность
  803. */
  804. void SetPortGwParityInt(uint32_t value);
  805. /**
  806. * @brief Число бит данных
  807. */
  808. void SetPortGwDatabitsStr(char *str);
  809. /**
  810. * @brief Число стоп-бит
  811. */
  812. void SetPortGwStopbitsStr(char *str);
  813. #endif
  814. #if defined(DALLAS_SENSOR_ENABLE) || defined(AM2301_SENSOR_ENABLE)
  815. // ************************************************************************** //
  816. // Параметры датчика температуры
  817. /**
  818. * @brief Размещение датчика температуры 1
  819. */
  820. void SetTS1locationStr(char *str);
  821. /**
  822. * @brief Размещение датчика температуры 2
  823. */
  824. void SetTS2locationStr(char *str);
  825. /**
  826. * @brief Размещение датчика температуры
  827. */
  828. void SetTSlocationStr(char *str, uint8_t num);
  829. #endif
  830. // ************************************************************************** //
  831. // Параметры SNMP
  832. /**
  833. * @brief TRAP community
  834. */
  835. void SetTrapCommunity(char *str);
  836. /**
  837. * @brief Community для чтения
  838. */
  839. void SetReadCommunity(char *str);
  840. /**
  841. * @brief Community для записи
  842. */
  843. void SetWriteCommunity(char *str);
  844. /**
  845. * @brief IP SNMP менеджера
  846. */
  847. void SetManagerIp(char *str);
  848. void SetManagerIp2(char *str);
  849. void SetManagerIp3(char *str);
  850. void SetManagerIp4(char *str);
  851. void SetManagerIp5(char *str);
  852. /**
  853. * @brief Название устройсва устройства
  854. */
  855. void SetNameDeviceStr(char *str);
  856. /**
  857. * @brief Установить владельца
  858. */
  859. void SetOwner(char *str);
  860. /**
  861. * @brief Установить местоположение
  862. */
  863. void SetLocation(char *str);
  864. /**
  865. * @brief Установить комментарий
  866. */
  867. void SetComment(char *str);
  868. #ifdef RADIUS_SERVER_ENABLE
  869. // ************************************************************************** //
  870. // Сетевые параметры RADIUS сервера
  871. /**
  872. * @brief IP адрес
  873. */
  874. void SetRDSIpStr(char *str);
  875. /**
  876. * @brief Порт
  877. */
  878. void SetRDSPortStr(char *str);
  879. /**
  880. * @brief Код access
  881. */
  882. void SetRDSKeyAccesstStr(char *str);
  883. /**
  884. * @brief пароль RADIUS
  885. */
  886. void SetRDSPasswordkStr(char *str);
  887. /**
  888. * @brief Настройка вкл/ выкл RADIUS сервера
  889. */
  890. void SetRDSEnableStateStr(char *str);
  891. /**
  892. * @brief Настройка вкл/ выкл авторизации
  893. */
  894. void SetAuthEnableStateStr(char *str);
  895. #endif
  896. #ifdef TELNET_ENABLE
  897. // ************************************************************************** //
  898. // Параметры Telnet
  899. /**
  900. * @brief Текущий Порт
  901. */
  902. void SetTelnetPortStr(char *str);
  903. /**
  904. * @brief Настройка вкл/ выкл Telnet сервера
  905. */
  906. void SetTelnetEnableStateStr(char *str);
  907. // ************************************************************************** //
  908. // Параметры SSH
  909. /**
  910. * @brief Текущий Порт
  911. */
  912. void SetSSHPortStr(char *str);
  913. /**
  914. * @brief Настройка вкл/ выкл SSH сервера
  915. */
  916. void SetSSHEnableStateStr(char *str);
  917. #endif
  918. #ifdef SYSLOG_ENABLE
  919. // ************************************************************************** //
  920. // Параметры Syslog
  921. void SetSyslogEnable(char *str);
  922. void SetSyslogServer(char *str);
  923. void SetSyslogPort(char *str);
  924. #endif // SYSLOG_ENABLE
  925. // ************************************************************************** //
  926. // Параметры даты и времени
  927. /**
  928. * @brief Дата
  929. */
  930. void SetDateStr(char *str);
  931. /**
  932. * @brief Время
  933. */
  934. void SetTimeStr(char *str);
  935. /**
  936. * @brief Время
  937. */
  938. void SetTimeWebStr(char *str);
  939. // ************************************************************************** //
  940. // Параметры SNTP
  941. /**
  942. * @brief Состояние SNTP
  943. */
  944. void SetSntpStateStr(char *str);
  945. /**
  946. * @brief IP адрес SNTP сервера
  947. */
  948. void SetSntpServerIpStr(char *str);
  949. /**
  950. * @brief Часовой пояс контроллера
  951. */
  952. void SetSntpTimeZoneStr(char *str);
  953. // ************************************************************************** //
  954. // Параметры реле/сухих контактов
  955. #ifdef DINS_ENABLE
  956. /**
  957. * @brief Тип действий при срабатывание сухих контактов
  958. */
  959. void SetDINTypeActStr(char *str, uint8_t num);
  960. /**
  961. * @brief Тип действий при срабатывание сухих контактов
  962. */
  963. void SetDIN0TypeActStr(char *str);
  964. /**
  965. * @brief Тип действий при срабатывание сухих контактов
  966. */
  967. void SetDIN1TypeActStr(char *str);
  968. /**
  969. * @brief Имя сухого контакта
  970. */
  971. void SetDINNameStr(char *str, uint8_t num);
  972. /**
  973. * @brief Имя сухого контакта
  974. */
  975. void SetDIN0NameStr(char *str);
  976. /**
  977. * @brief Имя сухого контакта
  978. */
  979. void SetDIN1NameStr(char *str);
  980. #endif
  981. #ifdef DOUTS_ENABLE
  982. /**
  983. * @brief Источник срабатывания реле
  984. */
  985. void SetROTypeActStr(char *str, uint8_t num);
  986. /**
  987. * @brief Источник срабатывания реле 1
  988. */
  989. void SetRO1TypeActStr(char *str);
  990. /**
  991. * @brief Источник срабатывания реле 2
  992. */
  993. void SetRO2TypeActStr(char *str);
  994. /**
  995. * @brief Источник срабатывания реле 3
  996. */
  997. void SetRO3TypeActStr(char *str);
  998. /**
  999. * @brief
  1000. */
  1001. void SetROStr(char *str, uint8_t num);
  1002. /**
  1003. * @brief
  1004. */
  1005. void SetROInt(uint8_t val, uint8_t num);
  1006. #endif
  1007. // ************************************************************************** //
  1008. // Параметры настройки ИБП
  1009. /**
  1010. * @brief Минимальное напряжение на ячейках АКБ
  1011. */
  1012. void SetUPSVoltCellMinStr(char *str);
  1013. /**
  1014. * @brief Минимальное напряжение на ячейках АКБ
  1015. */
  1016. void SetUPSVoltCellMinInt(float value);
  1017. /**
  1018. * @brief Максимальное напряжение на ячейках АКБ
  1019. */
  1020. void SetUPSVoltCellMaxStr(char *str);
  1021. /**
  1022. * @brief Максимальное напряжение на ячейках АКБ
  1023. */
  1024. void SetUPSVoltCellMaxInt(float value);
  1025. /**
  1026. * @brief Дата установки АКБ
  1027. */
  1028. void SetDataSetAKBStr(char *str);
  1029. /**
  1030. * @brief Срок службы АКБ
  1031. */
  1032. void SetLifeTimeAKBStr(char *str);
  1033. /**
  1034. * @brief Номинальное напряжение АКБ
  1035. */
  1036. void SetVoltageAKBNominalStr(char *str);
  1037. /**
  1038. * @brief Полная мощность АКБ
  1039. */
  1040. void SetUPSPowerStr(char *str);
  1041. /**
  1042. * @brief Полная мощность АКБ
  1043. */
  1044. void SetUPSPowerEnumStr(char *str);
  1045. /**
  1046. * @brief Емкость АКБ
  1047. */
  1048. void SetCapacityNominalAKBStr(char *str);
  1049. /**
  1050. * @brief Серийный номер ИБП
  1051. */
  1052. void SetUPSSerialStr(char *str);
  1053. // ************************************************************************** //
  1054. // Параметры менеджера аварий
  1055. /**
  1056. * @brief Верхняя граница VAC
  1057. */
  1058. void SetVACAlarmHighRangeStr(char *str);
  1059. /**
  1060. * @brief Верхняя граница VAC
  1061. */
  1062. void SetVACAlarmHighRangeInt(float value);
  1063. /**
  1064. * @brief Нижняя граница VAC
  1065. */
  1066. void SetVACAlarmLowRangeStr(char *str);
  1067. /**
  1068. * @brief Нижняя граница VAC
  1069. */
  1070. void SetVACAlarmLowRangeInt(float value);
  1071. /**
  1072. * @brief Гистерезис (VAC)
  1073. */
  1074. void SetVACAlarmHisteStr(char *str);
  1075. /**
  1076. * @brief Гистерезис (VAC)
  1077. */
  1078. void SetVACAlarmHisteInt(float value);
  1079. #ifdef VAC_IN_MONITOR
  1080. /**
  1081. * @brief Верхняя граница входящего напряжения
  1082. */
  1083. void SetVACInputAlarmHighRangeStr(char *str);
  1084. /**
  1085. * @brief Верхняя граница входящего напряжения
  1086. */
  1087. void SetVACInputAlarmHighRangeInt(float value);
  1088. /**
  1089. * @brief Нижняя граница входящего напряжения
  1090. */
  1091. void SetVACInputAlarmLowRangeStr(char *str);
  1092. /**
  1093. * @brief Нижняя граница входящего напряжения
  1094. */
  1095. void SetVACInputAlarmLowRangeInt(float value);
  1096. /**
  1097. * @brief Гистерезис входящего напряжения
  1098. */
  1099. void SetVACinputAlarmHisteStr(char *str);
  1100. /**
  1101. * @brief Гистерезис входящего напряжения
  1102. */
  1103. void SetVACinputAlarmHisteInt(float value);
  1104. #endif
  1105. /**
  1106. * @brief Верхняя граница температуры
  1107. */
  1108. void SetTemperatureAlarmHighRangeStr(char *str);
  1109. /**
  1110. * @brief Верхняя граница температуры
  1111. */
  1112. void SetTemperatureAlarmHighRangeInt(float value);
  1113. /**
  1114. * @brief Нижняя граница температуры
  1115. */
  1116. void SetTemperatureAlarmLowRangeStr(char *str);
  1117. /**
  1118. * @brief Нижняя граница температуры
  1119. */
  1120. void SetTemperatureAlarmLowRangeInt(float value);
  1121. /**
  1122. * @brief Гистерезис (температура)
  1123. */
  1124. void SetTemperatureAlarmHisteStr(char *str);
  1125. /**
  1126. * @brief Гистерезис (температура)
  1127. */
  1128. void SetTemperatureAlarmHisteInt(float value);
  1129. #if !(HARDWARE_BT6709 || HARDWARE_BT6709_MTS)
  1130. /**
  1131. * @brief Верхняя граница температуры
  1132. */
  1133. void SetTemperatureCabinetAlarmHighRangeStr(char *str);
  1134. /**
  1135. * @brief Верхняя граница температуры
  1136. */
  1137. void SetTemperatureCabinetAlarmHighRangeInt(float value);
  1138. /**
  1139. * @brief Нижняя граница температуры
  1140. */
  1141. void SetTemperatureCabinetAlarmLowRangeStr(char *str);
  1142. /**
  1143. * @brief Нижняя граница температуры
  1144. */
  1145. void SetTemperatureCabinetAlarmLowRangeInt(float value);
  1146. /**
  1147. * @brief Гистерезис (температура)
  1148. */
  1149. void SetTemperatureCabinetAlarmHisteStr(char *str);
  1150. /**
  1151. * @brief Гистерезис (температура)
  1152. */
  1153. void SetTemperatureCabinetAlarmHisteInt(float value);
  1154. #endif
  1155. /**
  1156. * @brief Верхняя граница нагрузки
  1157. */
  1158. void SetLoadAlarmHighRangeStr(char *str);
  1159. /**
  1160. * @brief Верхняя граница нагрузки
  1161. */
  1162. void SetLoadAlarmHighRangeInt(float value);
  1163. /**
  1164. * @brief Гистерезис (нагрузки)
  1165. */
  1166. void SetLoadAlarmHistStr(char *str);
  1167. /**
  1168. * @brief Гистерезис (нагрузки)
  1169. */
  1170. void SetLoadAlarmHistInt(float value);
  1171. void SetEmptyFuncStr(char *str);
  1172. #endif /* #ifndef PARAMETERS_H */
  1173. /********************************* (C) РОТЕК **********************************/