Разобрался с подключением устройств по RS485, но я наблюдаю странное поведение в ВЕБ-интерфейсе.
При открытии страницы http://wiren-board/#/devices я вижу дублирование устройств.
На странице отображается:
menu | wb-mr11 id-3
| wb-mr11 id-1
| wb-mr11 id-2
| wb-mr11 id-1
До статьи не добрался, но обновил образ флешки.
Обновился: апдейт, апгрейд.
Возникает ошибка с linux-latest. Unpacking linux-image-4.1.15-imxv5-x0.1 (from …/linux-image-4.1.15-imxv5-x0.1_4.1-imxv5-x0.1+wb20160301144946_armel.deb) … dpkg: error processing /var/cache/apt/archives/linux-image-4.1.15-imxv5-x0.1_4.1-imxv5-x0.1+wb20160301144946_armel.deb (–unpack):
trying to overwrite ‘/boot/dtbs/imx23-wirenboard28.dtb’, which is also in package linux-image-3.19.0-imxv5-x0.1 3.19-imxv5-x0.1+wb20160207172608* dpkg-deb: error: subprocess paste was killed by signal (Broken pipe) Errors were encountered while processing:
/var/cache/apt/archives/linux-image-4.1.15-imxv5-x0.1_4.1-imxv5-x0.1+wb20160301144946_armel.deb* E: Sub-process /usr/bin/dpkg returned an error code (1)
Удаление пакета не помогает. root@wirenboard:/home# apt-get -f remove linux-image-3.19.0-imxv5-x0.1 Reading package lists… Done Building dependency tree Reading state information… Done You might want to run ‘apt-get -f install’ to correct these: The following packages have unmet dependencies: linux-latest : Depends: linux-image-4.1.15-imxv5-x0.1 (>= 4.1-imxv5-x0.1+wb20160301144946) but it is not going to be installed
Сделайте apt-get -f install чтоб исправились зависимость.
Потом удаляете разом все пакеты старого ядра (они друг от друга зависят, поэтому по одиночке не удаляются) и ставите новое: apt-get remove linux-{firmware-,}image-3.19-imxv5-x0.1 linux-latest apt-get install linux-latest
Добрый день!
Столкнулся с подобной проблемой. Имею WB5 и WB-MR11. На борде стоит последняя прошивка, при подключении релейного модуля оно появляется в девайсах (вэб интерфейс), но почему то горит красным цветом, и не передает команды. Пробовал добавить ручками, изменив конфиг в SDDC, слейв айди автоматом там не ставится, как написано выше, надо делать руками. В общем таким образом я добавил себе три устройства, но ни одно из них почему то не может нормально индетифицироваться. Пробовал удалять кеш, как написано в инструкции, в итоге ситуация не изменилась. Подскажите пожалуйста, в какую сторону копать данную проблему? Спасибо.
Jun 7 04:11:17 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read discrete @ 8 [slave_id is 1(0x1)]
Jun 7 04:11:17 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read discrete @ 9 [slave_id is 1(0x1)]
Jun 7 04:11:18 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read discrete @ 10 [slave_id is 1(0x1)]
Jun 7 04:11:18 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read input @ 32 [slave_id is 1(0x1)]
Jun 7 04:11:19 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read input @ 33 [slave_id is 1(0x1)]
Jun 7 04:11:19 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read input @ 34 [slave_id is 1(0x1)]
Jun 7 04:11:20 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read input @ 35 [slave_id is 1(0x1)]
Jun 7 04:11:20 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read input @ 36 [slave_id is 1(0x1)]
Jun 7 04:11:21 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read input @ 37 [slave_id is 1(0x1)]
Jun 7 04:11:21 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read input @ 38 [slave_id is 1(0x1)]
Jun 7 04:11:22 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read input @ 39 [slave_id is 1(0x1)]
Jun 7 04:11:22 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read input @ 40 [slave_id is 1(0x1)]
Jun 7 04:11:23 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read input @ 41 [slave_id is 1(0x1)]
Jun 7 04:11:23 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read input @ 42 [slave_id is 1(0x1)]
Jun 7 04:11:24 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read input @ 121 [slave_id is 1(0x1)]
Jun 7 04:11:24 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read coil @ 0 [slave_id is 1(0x1)]
Jun 7 04:11:25 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read coil @ 1 [slave_id is 1(0x1)]
Jun 7 04:11:25 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read coil @ 2 [slave_id is 1(0x1)]
Jun 7 04:11:26 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read coil @ 3 [slave_id is 1(0x1)]
Jun 7 04:11:26 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read coil @ 4 [slave_id is 1(0x1)]
Jun 7 04:11:27 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read coil @ 5 [slave_id is 1(0x1)]
Jun 7 04:11:27 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read coil @ 6 [slave_id is 1(0x1)]
Jun 7 04:11:28 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read coil @ 7 [slave_id is 1(0x1)]
Jun 7 04:11:28 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read coil @ 8 [slave_id is 1(0x1)]
Jun 7 04:11:29 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read coil @ 9 [slave_id is 1(0x1)]
Jun 7 04:11:29 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read coil @ 10 [slave_id is 1(0x1)]
Jun 7 04:11:30 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read holding @ 8 [slave_id is 1(0x1)]
Jun 7 04:11:30 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read discrete @ 0 [slave_id is 1(0x1)]
Jun 7 04:11:31 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read discrete @ 1 [slave_id is 1(0x1)]
Jun 7 04:11:31 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read discrete @ 2 [slave_id is 1(0x1)]
Jun 7 04:11:32 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read discrete @ 3 [slave_id is 1(0x1)]
Jun 7 04:11:32 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read discrete @ 4 [slave_id is 1(0x1)]
Jun 7 04:11:33 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read discrete @ 5 [slave_id is 1(0x1)]
Jun 7 04:11:33 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read discrete @ 6 [slave_id is 1(0x1)]
Jun 7 04:11:34 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read discrete @ 7 [slave_id is 1(0x1)]
Jun 7 04:11:34 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read discrete @ 8 [slave_id is 1(0x1)]
Jun 7 04:11:35 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read discrete @ 9 [slave_id is 1(0x1)]
Jun 7 04:11:35 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read discrete @ 10 [slave_id is 1(0x1)]
Jun 7 04:11:36 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read input @ 32 [slave_id is 1(0x1)]
Jun 7 04:11:36 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read input @ 33 [slave_id is 1(0x1)]
Jun 7 04:11:37 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read input @ 34 [slave_id is 1(0x1)]
Jun 7 04:11:37 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read input @ 35 [slave_id is 1(0x1)]
Jun 7 04:11:38 wirenboard user.notice serial: TRegisterHandler::Poll(): warning: Serial protocol error: failed to read input @ 36 [slave_id is 1(0x1)]
На устройствах есть наклейки, на наклейках написан заводской slave_id. Вы его вписываете в соответствующей поле в веб-интерфейсе при добавлении девайса.
Сейчас у меня отображается четыре устройства MR11, три с тем slave_id которое я указывал произвольно, и одно которое написано на наклейке. Те устройства в которых были указаны произвольные значения slave_id так и остались “висеть”. mqtt-delete-retained их не удаляет, в конфигурационных файлах их нет, ребут так же не помог. Эти устройства (неправильные) теперь всегда будут отображаться?
Да, Вы оказались правы!
команда была следующей:
mqtt-delete-retained ‘/devices/wb-mr11/#’
изменил на:
mqtt-delete-retained ‘/devices/wb-mr11_22/#’
то есть дописал тот id который присваивал ранее, устройства удалились.
Спасибо.
Подниму похожую тему.
Есть огромная куча устройств в ветке /devices/oregon_xxxx
При попытке удаления, первые два устройства подряд удаляться почти со 100% вероятностью (т.е. удаляю первое устройство, все норм, удаляю второе устройство - тоже норм, удаляю третье или пятое - повис), остальные как получиться, повисает на данном этапе и прерывается по Ctrl+C. Процесс mqtt-delete-retained грузит проц до 75%. После прерывания по Ctrl+C даю команду еще раз, просто повторяю её и все норм, удалено. Что я делаю не так? Лог ниже.
root@wirenboard:~# mqtt-delete-retained '/devices/oregon_rx_2b95_95_5/#'
/devices/oregon_rx_2b95_95_5/meta/name
/devices/oregon_rx_2b95_95_5/controls/low_battery
/devices/oregon_rx_2b95_95_5/controls/low_battery/meta/readonly
/devices/oregon_rx_2b95_95_5/controls/low_battery/meta/type
/tmp/1485258184.8914656/retain_hack
/devices/oregon_rx_2b95_95_5/controls/low_battery/meta/readonly
/devices/oregon_rx_2b95_95_5/controls/low_battery/meta/type
/devices/oregon_rx_2b95_95_5/meta/name
/devices/oregon_rx_2b95_95_5/controls/low_battery
done!
^CTraceback (most recent call last):
File "/usr/bin/mqtt-delete-retained", line 88, in <module>
rc = client.loop()
File "/usr/lib/python2.7/dist-packages/mosquitto.py", line 725, in loop
rc = self.loop_write(max_packets)
File "/usr/lib/python2.7/dist-packages/mosquitto.py", line 986, in loop_write
rc = self._packet_write()
File "/usr/lib/python2.7/dist-packages/mosquitto.py", line 1380, in _packet_write
write_length = self._sock.send(packet.packet[packet.pos:])
KeyboardInterrupt
root@wirenboard:~#
и повтор