Все переводы

Введите имя сообщения для показа всех доступных переводов.

Сообщение

Найдено 2 перевода.

СообщениеТекущий текст
 ист. английский (en){{note|info| '''Attention!''' The instructions consider an example in which the devices operate at a speed of '''115200 8N2'''. In your case, the connection settings may be different.}}
To update the firmware:
#Connect to the controller twice via [[SSH |SSH]], you should have two windows open: the first to create a socat tunnel, the second to send commands to the device.
#Stop wb-mqtt-serial:
#:<syntaxhighlight lang="bash"> 
systemctl stop wb-mqtt-serial 
</syntaxhighlight> 
#In the first window, start the redirect:
#:<syntaxhighlight lang="bash"> 
socat -d -d -d -x PTY,raw,b115200,parenb=0,cstopb=2,cs8,link=/dev/ttyRS485-5 tcp:192.168.0.7:23
</syntaxhighlight> 
#:if you have a stable release up to and including wb-2207, instead of the b115200 parameter, use <code>ispeed=115200,ospeed=115200</code> .
#In the second window, change the device port speed to 9600 kbps:
#:<syntaxhighlight lang="bash"> 
modbus_client --debug -mrtu -b115200 -pnone -s2 /dev/ttyRS485-5 -a58 -t0x06 -r110 96
</syntaxhighlight> 
#In the first window, terminate the socat connection with <kbd>Ctrl</kbd> + <kbd>C</kbd> .
#In [[socat#Configuring a gateway for firmware updates | gateway settings]] set the port speed to 9600 kbps.
#In the first window, restart socat forwarding with the new connection parameters:
#:<syntaxhighlight lang="bash"> 
socat -d -d -d -x PTY,raw,b9600,parenb=0,cstopb=2,cs8,link=/dev/ttyRS485-5 tcp:192.168.0.7:23
</syntaxhighlight> 
#:if you have a stable release up to and including wb-2207, instead of the b9600 parameter, use <code>ispeed=9600,ospeed=9600</code> .
#In the second window, run the device firmware update, for example, with the wb-mcu-fw-flasher utility ([[WB_Modbus_Devices_Firmware_Update#Manual_update|full instructions]]):
#:<syntaxhighlight lang="bash"> 
wb-mcu-fw-flasher -j -d /dev/ttyRS485-5 -a25 -f ./firmware.wbfw
</syntaxhighlight> 
#After finishing the firmware, return the old speed of 115200 kbps to the device:
#:<syntaxhighlight lang="bash"> 
modbus_client --debug -mrtu -b9600 -pnone -s2 /dev/ttyRS485-5 -a58 -t0x06 -r110 1152
</syntaxhighlight> 
#In the first window, break the socat connection with <kbd>Ctrl</kbd> + <kbd>C</kbd> .
#In the gateway settings, change the port speed from 9600 kbps to 115200 kbps.
#Connect the gateway to the controller via Ethernet.
#Run wb-mqtt-serial
#:<syntaxhighlight lang="bash"> 
systemctl start wb-mqtt-serial
</syntaxhighlight>
 ист. русский (ru){{note|info| '''Внимание!''' В инструкции рассмотрен пример, в котором устройства работают на скорости '''115200 8N2'''. В вашем случае настройки соединения могут быть другими.}}
Чтобы обновить прошивку:
#Дважды подключитесь к контроллеру по [[SSH |SSH]], у вас должно быть открыто два окна: первое для создания тоннеля socat, второе для отправки команд устройству.
#Остановите wb-mqtt-serial:
#:<syntaxhighlight lang="bash">
systemctl stop wb-mqtt-serial 
</syntaxhighlight>
#В первом окне запустите перенаправление:
#:<syntaxhighlight lang="bash">
socat -d -d -d -x PTY,raw,b115200,parenb=0,cstopb=2,cs8,link=/dev/ttyRS485-5 tcp:192.168.0.7:23
</syntaxhighlight>
#:если у вас стабильный релиз до wb-2207 включительно, вместо параметра b115200, используйте <code>ispeed=115200,ospeed=115200</code>.
#Во втором окне измените скорость порта устройства на 9600 кбит/с:
#:<syntaxhighlight lang="bash">
modbus_client --debug -mrtu -b115200 -pnone -s2 /dev/ttyRS485-5 -a58 -t0x06 -r110 96
</syntaxhighlight>
#В первом окне разорвите соединение socat клавишами <kbd>Ctrl</kbd>+<kbd>C</kbd>.
#В [[socat#Настройка шлюза для обновления прошивки | настройках шлюза]] установите скорость порта 9600 кбит/с.
#В первом окне снова запустите перенаправление socat с новыми параметрами соединения:
#:<syntaxhighlight lang="bash">
socat -d -d -d -x PTY,raw,b9600,parenb=0,cstopb=2,cs8,link=/dev/ttyRS485-5 tcp:192.168.0.7:23
</syntaxhighlight>
#:если у вас стабильный релиз до wb-2207 включительно, вместо параметра b9600, используйте <code>ispeed=9600,ospeed=9600</code>.
#Во втором окне запустите обновление прошивки устройства, например, утилитой wb-mcu-fw-flasher ([[WB_Modbus_Devices_Firmware_Update#Ручное_обновление|полная инструкция]]):
#:<syntaxhighlight lang="bash">
wb-mcu-fw-flasher -j -d /dev/ttyRS485-5 -a25 -f ./firmware.wbfw
</syntaxhighlight>
#После окончания прошивки верните в устройстве старую скорость 115200 кбит/с:
#:<syntaxhighlight lang="bash">
modbus_client --debug -mrtu -b9600 -pnone -s2 /dev/ttyRS485-5 -a58 -t0x06 -r110 1152
</syntaxhighlight>
#В первом окне разорвите соединение socat клавишами <kbd>Ctrl</kbd>+<kbd>C</kbd>.
#В настройках шлюза измените скорость порта с 9600 кбит/с на 115200 кбит/с.
#Подключите шлюз к контроллеру по Ethernet.
#Запустите wb-mqtt-serial
#:<syntaxhighlight lang="bash">
systemctl start wb-mqtt-serial
</syntaxhighlight>