MQTT/en: различия между версиями

Новая страница: «'''Solution:''' # Register on http://cloudmqtt.com/ # Go to your account on http://cloudmqtt.com/ to view settings: server, port, username, password. # Go to the…»
(Новая страница: «'''Task''': set up forwarding of all MQTT messages to the popular free cloud MQTT broker http://cloudmqtt.com/ and back.»)
(Новая страница: «'''Solution:''' # Register on http://cloudmqtt.com/ # Go to your account on http://cloudmqtt.com/ to view settings: server, port, username, password. # Go to the…»)
Строка 177: Строка 177:
'''Task''': set up forwarding of all MQTT messages to the popular free cloud MQTT broker http://cloudmqtt.com/ and back.
'''Task''': set up forwarding of all MQTT messages to the popular free cloud MQTT broker http://cloudmqtt.com/ and back.


'''Решение:'''
'''Solution:'''
# Зарегистрируйтесь на http://cloudmqtt.com/
# Register on http://cloudmqtt.com/
# Зайдите в свой аккаунт на http://cloudmqtt.com/ и посмотрите настройки: сервер, порт, логин, пароль.
# Go to your account on http://cloudmqtt.com/ to view settings: server, port, username, password.
# Зайдите на контроллер и добавьте в конец файла ''/etc/mosquitto/mosquitto.conf'' следующие строки:
# Go to the controller and add the following lines to the end of the  ''/etc/mosquitto/mosquitto.conf'' file :
#: <syntaxhighlight lang="bash">
#: <syntaxhighlight lang="bash">
connection cloudmqtt
connection cloudmqtt
Строка 191: Строка 191:
topic # both
topic # both
</syntaxhighlight>
</syntaxhighlight>
#: (последняя строка говорит, что нужно пересылать все сообщения (метасимвол '''#''', смотрите описание выше) в обе ('''both''') стороны (с брокера контроллера на облачный брокер и обратно)
#:(the last line says that you want to forward all messages ('''#''' metasymbol, see description above) in either ('''both''') side (broker cloud controller to the broker and back)
#: Более подробное описание всех опций смотрите на https://mosquitto.org/man/mosquitto-conf-5.html.
#:For a more detailed description of all options, see  https://mosquitto.org/man/mosquitto-conf-5.html.
# Перезапустите mosquitto, выполнив в консоли
# Restart mosquitto by running the following in console
#: <syntaxhighlight lang="bash">
#: <syntaxhighlight lang="bash">
service mosquitto restart
service mosquitto restart
</syntaxhighlight>
</syntaxhighlight>
12 063

правки