Vcon.io ESP8266 config for Protocol Bridge Mode (MQTT)

#1

Hi guys,

I am trying to config a ESP8266 with VCON to receive a json from an Arduino e post messages to MQTT like the example posted for ESP32.

Is it possible to Configure an ESP8266 to use protocol bridge mode (MQTT) with VCON ?
Is there a procedure on how to config this ?
I tried to use the procedure for ESP32 but esp8266 is not publishing.
I suspect serial protocol bridge not active, but I dont know how to check this.
My arduino is sending same json I used with ESP32 with sucess, but ESP8266 dont publish.

I did the following steps:

mos flash https://mdash.net/downloads/ccm/ccm.esp8266.zip
mos wifi WIFI_NETWORK WIFI_PASSWORD
mos config-set dash.token=XXXX
mos config-set ccm.host.rpc.enable=false
mos config-set mqtt.enable=true mqtt.server=broker.hivemq.com:1883
mos config-set ccm.host.ota.chip_type=AVR spi.enable=true ccm.host.ota.avr.miso_pin=12 ccm.host.ota.avr.mosi_pin=13 ccm.host.ota.avr.sclk_pin=14 ccm.host.ota.avr.rst_pin=5

Some one have any directions about what could be the problem or a procedure to config ESP8266 for this.

I will appreciate any directions.

Thank you
Regards
José Luiz

#2

The configuration you have shown does not configure VCON in any of the modes.
You’re disabling RPC bridge by setting ccm.host.rpc.enable=false , and you do not configure the transparent UART mode.

What do you want do achieve?

#3

Hi Ism, thanks for reply.

I would like to config ESP8266 with VCON Protocol Bridge for MQTT, so the ESP8266 receive a Json like below and publish on MQTT.

{“id:1, ”method”:”MQTT.Pub”, ”params”:{“topic”:”test’, ”message”:”hello”}}

Please can you explain how to setup this for ESP8266 ?

I will appreciate you help.

Thank You

José Luiz

#4

Try this:

  1. Follow the https://vcon.io/docs/#esp32--esp8266-setup to register ESP8266 on mDash

  2. Configure protocol bridge:

mos --port wss://API_KEY@mdash.net/api/v2/devices/DEVICE_ID/rpc config-set mqtt.enable=true mqtt.server=broker.hivemq.com:1883 debug.stdout_uart=1 debug.stderr_uart=1 ccm.host.rpc.enable=true ccm.host.rpc.uart.unit_no=0 ccm.host.ota.chip_type=AVR ccm.host.ota.avr.miso_pin=12 ccm.host.ota.avr.mosi_pin=13 ccm.host.ota.avr.sclk_pin=14 ccm.host.ota.avr.rst_pin=5

Note: ESP8266 has only one bi-directional UART, therefore you cannot use mos tool over serial port after step1. Always use --port wss://..... Also, when you reboot ESP8266, or issue any other mos command over serial - like flash, you might need to push and hold Arduino reset button.

#5

Hi Ism,
I follow your procedure and every thing works fine.
Again thank you very much by you support !

Best regards

José Luiz