Перейти к содержанию

Навигация

WB-MIR v2 - Modbus IR Remote Control/en: различия между версиями

Новая страница: «== Images and drawings of the device == <!--{{WBPicturesNoDrawing|1}}--> {{WBPictures|1}}»
(Новая страница: «{| class="wikitable" ! style="font-weight: bold;" | Module ! style="font-weight: bold;" | Signature |- | WB-MIR | WBMIR'0x00' |}»)
(Новая страница: «== Images and drawings of the device == <!--{{WBPicturesNoDrawing|1}}--> {{WBPictures|1}}»)
 
(не показано 8 промежуточных версий этого же участника)
Строка 308: Строка 308:
|}
|}


Для получения сигнатуры нужно выполнить команду READ_HOLDING_REGISTERS по адресу 200 (длина 6 регистров). Запись в эту область памяти не поддерживается, при попытке записи в недопустимое место возвращается ошибка 3. Пустые места в тексте сигнатуры забиваются значением 0x00.  
To get the signature of a device you need to run command READ_HOLDING_REGISTERS at 200 (length of 6 registers). Writing to this area of memory is not supported, and error 3 is returned when attempting to write to an invalid location. Empty spaces in the signature text are clogged with the value 0x00.  
Начиная с регистра 220 записана дата сборки прошивки, в формате "число'''x00'''время'''x00'''" в виде строки (пример: 'Jan 27 2017 17:01:13'). Длина записи — 21 регистр.
Starting from register 220, the firmware build date is recorded, in the format ''number'''x00'''time'''x00''''' as a string (example: 'Jan 27 2017 17:01:13'). The length of the record is 21 registers.


== Управление модулем из web-интерфейса ==
== Module management from the web interface ==
[[File:WB-MIR-2-WEB_Cut.png|1039px|thumb|center|Веб-интерфейс модуля WB-MIR v2]]
[[File:WB-MIR-2-WEB_Cut.png|1039px|thumb|center|WB-MIR v2 Web interface]]
Для подключения модуля WB-MIR v2 используется шаблон '''WB-MIR v2''', который предоставляет полный набор к функциям модуля из веб-интерфейса, включая обучение.
To connect the WB-MIR v2 module, use the '''WB-MIR v2''' template, which provides a complete set of module functions from the web interface, including learning.




Рассмотрим основные органы управления модулем и их назначение.
Consider the main controls of the module and their purpose.


<div class="mw-translate-fuzzy">
{| class="wikitable"
{| class="wikitable"
! Название элемента управления
! The name of the control
!Назначение
!Appointment
|-
|-
|Input Voltage||Напряжение питания модуля
|Input Voltage||module supply voltage
|-
|-
|Learn to RAM||Запись ИК-сигнала в оперативный буфер (см. раздел [[#Оперативный режим|Оперативный режим]]). Для обучения контрол переводится в положение ON, после обучения — OFF.   
|Learn-to-RAM||Write the IR signal in the operational buffer (see section [[#Operational mode|Operational mode]]). For learning, the control is transferred to ON position, after learning — OFF.   
|-
|-
|Play from RAM||Воспроизведение ИК-сигнала из оперативного буфера (см. раздел [[#Оперативный режим|Оперативный режим]]).
|Play from RAM||Play the IR signal from the operating buffer (see [[#Operating mode|Operating mode]]).
|-
|-
|Learn to ROMx||Запись ИК-сигнала в соотв. ячейку ПЗУ (см. раздел [[#Постоянный режим|Постоянный режим]]). Для обучения контрол переводится в положение ON, после обучения — OFF.
|Learn to ROMx||IR signal Recording ACC. the cell of the ROM (see section [[#DC mode|DC mode]]). For learning, the control is transferred to ON position, after learning — OFF.
|-
|-
|Play from ROMx||Воспроизведение ИК-сигнала из соотв. ячейки ПЗУ (см. раздел [[#Постоянный режим|Постоянный режим]]). Для обучения контрол переводится в положение ON, после обучения — OFF.
|Play from ROMx||Play IR signal from resp. ROM cells (see [[#Constant mode|Constant mode]]]). For training, the control is transferred to THE on position, after training — OFF.
|-
|-
|ROMx -> RAM||Копирование данных из соотв. ячейки ПЗУ в оперативный буфер для редактирования (см. раздел [[#Постоянный режим|Постоянный режим]]). Для редактирования контрол переводится в положение ON, после редактирования — OFF.
|ROMx -> RAM||Copy data from ACC. ROM cells to the online buffer for editing (see [[#Constant mode|Constant mode]]). For editing, control is transferred to ON position, after editing — OFF.
|-
|-
|Internal/External Temperature Sensor||Температура внутреннего/внешнего цифрового датчика. Если датчик отсутствует или неисправен, его название выделяется красным цветом.
|Internal/External Temperature Sensor||Internal/external digital temperature sensor. If the sensor is missing or defective, its name is highlighted in red.
|-
|-
|Serial NO||Серийный номер модуля WB-MIR, может потребоваться при обращении в техподдержку.
|Serial NO||the Serial number of the WB-MIR module may be required when contacting technical support.
|-
|-
|Reset all ROM||Сброс содержимого всех ячеек памяти. '''Будьте внимательны, очистка ПЗУ будет выполнена без запроса на подтверждение!'''
|Reset all ROM||Resets the contents of all memory locations. '''Be careful, ROM cleaning will be done without asking for confirmation!'''
|-
|-
|}
|}
</div>


== Управление модулем из командной строки ==
== Command-line device management ==
Программное обеспечение контроллера Wiren Board включает в себя утилиту modbus_client для работы с устройствами, подключенными к выходам RS-485, по протоколу Modbus, подробное описание команды находится на странице [[Modbus-client]]. Доступ к командной строке описан в статье [[SSH]].
The Wiren Board controller software includes  modbus_client utility to work with devices connected to the RS-485 outputs, via Modbus Protocol, the detailed description of the command is on the page [[Modbus-client/en| Modbus client]]. Access to the command line is described in [[SSH/en| SSH]].


=== Пример чтения регистров ===
=== Register reading example ===
Проверим, верно ли, что мы подключились именно к модулю нужного типа. (Модуль wb-mqtt-serial должен быть предварительно остановлен). По адресу 200 хранится уникальная сигнатура длиной в 6 регистров. Прочтем 6 регистров, начиная с адреса 200, и преобразуем полученный ответ из шестнадцатеричных цифр в символьную строку:
Let's check whether it is true that we are connected to the module of the desired type. (Module wb-mqtt-serial needs to be stopped). At address 200, a unique signature of 6 registers is stored. Let's read 6 registers, starting with the address 200, and convert the received answer from hexadecimal digits into a character string:


<syntaxhighlight lang="bash">echo  -e `modbus_client --debug -mrtu -pnone -s2 /dev/ttyAPP1 \
<syntaxhighlight lang="bash">echo  -e `modbus_client --debug -mrtu -pnone -s2 /dev/ttyAPP1 \
Строка 352: Строка 354:
grep Data | sed -e 's/0x00/\\\x/g' -e 's/Data://' -e 's/\s//g'` </syntaxhighlight>
grep Data | sed -e 's/0x00/\\\x/g' -e 's/Data://' -e 's/\s//g'` </syntaxhighlight>


В результате выполнения команды получаем строку, например '''WBMIR'''. В этом примере модуль WB-MIR имеет Modbus-адрес 1.
As a result of the command, we receive string  '''WBMIR'''. The WB-MIR module in the example has Modbus address 1.


== Обновление прошивки устройства ==
== Device firmware update ==
Начиная с новых версий микропрограмм устройства поддерживается функционал обновления прошивки (микропрограммы) по протоколу Modbus. Это дает возможность расширять функциональные возможности устройств и устранять ошибки в микропрограммном обеспечении непосредственно на месте монтажа. Подробнее о перепрошивке устройств рассказано в статье [[WB-MCU-Flasher|Загрузка прошивок на устройства Wiren Board]]. Список версий прошивок, поддерживающих обновление, а также устройств, для которых эта функция реализована, можно найти в статье [[Firmware_Changelog]].
Starting with the new firmware versions of the device, the firmware update functionality (firmware) via the Modbus Protocol is supported. This makes it possible to extend the functionality of the devices and eliminate errors in the firmware directly at the installation site. Read more about flashing devices described in the article [[WB-MCU-Flasher|Download firmware to Wiren Board devices]]. A list of firmware versions that support the update, as well as devices for which this feature is implemented, can be found in [[Firmware_Changelog/en| Firmware Changelog]].




== Изображения и чертежи устройства ==
== Images and drawings of the device ==
<!--{{Wbincludes:WBPicturesNoDrawing|1}}-->
<!--{{Wbincludes:WBPicturesNoDrawing|1}}-->
{{Wbincludes:WBPictures|1}}
{{Wbincludes:WBPictures|1}}
12 063

правки