How to use protocol bridge (MQTT) to publish data on Google IoT

Hi guys,

I am trying to publish MQTT data on Google IoT using VCON.
I have a Arduino UNO that collects sensor data and send by serial a Json message (below) to ESP8266 runing VCON firmware.

{"id":6,"method":"MQTT.Pub","params":{"topic":"atlaspred-topic","message":"0A0532392E30371207393235372E30301A07343939382E30302204352E31372A04312E30303204312E32333A04302E3030"}}

PS: message use protobuffer

I have configured ESP8266 using commands bellow:

mos flash https://mdash.net/downloads/ccm/ccm.esp8266.zip --port SERIAL_PORT
mos wifi WIFI_NETWORK WIFI_PASSWORD
mos config-set dash.token=TOKEN
mos gcp-iot-setup --gcp-project atlaspred --gcp-region us-central1 --gcp-registry iot-registry
mos --port wss://AP_KEY@mdash.net/api/v2/devices/device15/rpc gcp-iot-setup --gcp-project atlaspred --gcp-region us-central1 --gcp-registry iot-registry
mos --port wss://API_KEY@mdash.net/api/v2/devices/device15/rpc config-set mqtt.enable=true 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

On the google side I use the following commands:

gcloud auth application-default login
gcloud projects create atlaspred
gcloud projects add-iam-policy-binding atlaspred --member=serviceAccount:cloud-iot@system.gserviceaccount.com --role=roles/pubsub.publisher
gcloud config set project atlaspred
gcloud pubsub topics create atlaspred-topic
gcloud pubsub subscriptions create --topic atlaspred-topic iot-subscription
gcloud iot registries create iot-registry --region us-central1 --event-notification-config=topic=atlaspred-topic

The problem is that ESP8266 is not publishing data on Google IoT Core.

I will appreciate any directions on what can I check to solve this .

Thank You

Best Regards

Jose Luiz

Hi Jose.

  1. When you show the commands you execute, please hide the sensitive information like API keys. They give root access to your account.
  2. In order to get MQTT.Pub working, you need to set up the MQTT server. You can start with the public MQTT server first, and make sure it is working:
mos --port wss://AP_KEY@mdash.net/api/v2/devices/device15/rpc config-set mqtt.enable=true mqtt.server=broker.hivemq.com:1883

Then use http://www.hivemq.com/demos/websocket-client/ to test your MQTT.Pub.

Please confirm that that setup works. When done, we can reconfigure VCON to use Google IoT.

Hi Ism, thank you for reply.

I have tested with hivemq and it works.

Now I am trying with Google Iot but i cant see messages on Google console.

I think i am doing something wrong on ESP8266 side.

I will appreciate some help about configuration on ESP8266 for Google IoT.

To publish on Google IoT do I use MQTT.Pub method ?

Which mqttserver I have to config in this case ?

Thank you

Regards
Jose Luiz

Yes you need to use the MQTT.Pub method.
Please debug the VCON module. Setup UDP logging on VCON:

mos --port wss://AP_KEY@mdash.net/api/v2/devices/device15/rpc config-set debug.level=3 debug.udp_log_addr=YOUR_WORKSTATION_IP:1234

On your workstation, run UDP listener:

nc -u -l 1234

Trigger MQTT.Pub. Catch the logs and share them here.
Also, share the gcp configuration section of your VCON.

Hi Ism,

Thank You for your support !

This is the gcp config:

  "gcp": {
    "ca_cert": "gcp-lts-ca.pem",
    "device": "ccm_C26FD9",
    "enable": true,
    "enable_commands": true,
    "enable_config": false,
    "key": "gcp-ccm_C26FD9.key.pem",
    "project": "atlaspred",
    "region": "us-central1",
    "registry": "iot-registry",
    "server": "mqtt.2030.ltsapis.goog:8883",
    "token_ttl": 3600
  },

And below are debug messages:

ccm_C26FD9 766 1582646015.325 2|mgos_mqtt_conn.c:219    MQTT0 event: 202
ccm_C26FD9 767 1582646015.329 2|mgos_mqtt_conn.c:271    MQTT0 CONNACK 0
ccm_C26FD9 768 1582646015.336 2|mgos_mqtt_conn.c:208    MQTT0 sub /devices/ccm_C26FD9/commands/# @ 1
ccm_C26FD9 769 1582646015.340 2|mgos_mqtt_conn.c:350    MQTT0 queue drained
ccm_C26FD9 770 1582646015.502 2|mgos_mqtt_conn.c:219    MQTT0 event: 209
ccm_C26FD9 771 1582646019.690 2|mg_rpc.c:482            0x3fff0fa4 GOT FRAME (180): {"id":615,"method":"MQTT.Pub","params":{"topic":"projects/atlaspred/topics/atlaspred-topic","message":"0A04302E30301201301A01302204302E30302A05302E3030303204302E30303A04302E3030"}}
ccm_C26FD9 772 1582646019.696 2|mg_rpc.c:376            '615' '' '' 'MQTT.Pub'
ccm_C26FD9 773 1582646019.702 2|mgos_rpc.c:373          Called 'MQTT.Pub', acl for it: '*'
ccm_C26FD9 774 1582646019.707 2|mg_rpc.c:293            MQTT.Pub via UART UART0
ccm_C26FD9 775 1582646019.723 2|mgos_mqtt_conn.c:199    MQTT0 pub -> 34 projects/atlaspred/topics/atlaspred-topic @ 0 (74): [0A04302E30301201301A01302204302E30302A05302E3030303204302E30303A04302E3030]
ccm_C26FD9 776 1582646019.733 2|mg_rpc.c:612            0x3fff0fa4 SEND FRAME (43): {"id":615,"src":"ccm_C26FD9","result":null} -> 1
ccm_C26FD9 777 1582646019.739 2|mg_rpc.c:508            0x3fff0fa4 FRAME SENT (1)
ccm_C26FD9 778 1582646019.760 2|mg_rpc.c:482            0x3fff0fa4 GOT FRAME (135): {"id":616ccm_C26FD9 785 1582646019.971 2|mgos_mqtt_conn.c:253    MQTT0 Disconnect
ccm_C26FD9 786 1582646019.977 2|mgos_mqtt_conn.c:543    MQTT0 connecting after 2156 ms
ccm_C26FD9 787 1582646022.140 2|mgos_mqtt_conn.c:467    MQTT0 connecting to mqtt.2030.ltsapis.goog:8883
ccm_C26FD9 788 1582646022.148 2|mg_net.c:911            0x3fff259c mqtt.2030.ltsapis.goog:8883 -,-,gcp-lts-ca.pem
ccm_C26FD9 789 1582646022.157 2|mgos_vfs.c:283          gcp-lts-ca.pem -> /gcp-lts-ca.pem pl 1 -> 1 0x3fff0344 (refs 1)
ccm_C26FD9 790 1582646022.167 2|mgos_vfs.c:377          open gcp-lts-ca.pem 0x0 0x1b6 => 0x3fff0344 gcp-lts-ca.pem 1 => 257 (refs 1)
ccm_C26FD9 791 1582646022.173 2|mgos_vfs.c:410          close 257 => 0x3fff0344:1 => 0 (refs 0)
ccm_C26FD9 792 1582646022.180 2|mg_net.c:911            0x3fff26f4 udp://201.6.2.82:53 -,-,-
ccm_C26FD9 793 1582646022.186 2|mg_net.c:779            0x3fff26f4 udp://201.6.2.82:53
ccm_C26FD9 794 1582646022.193 2|mg_net.c:794            0x3fff26f4 udp://201.6.2.82:53 -> 0
ccm_C26FD9 795 1582646022.214 2|mg_net.c:779            0x3fff259c tcp://64.233.181.206:8883
ccm_C26FD9 796 1582646022.376 2|mg_net.c:794            0x3fff259c tcp://64.233.181.206:8883 -> 0
ccm_C26FD9 797 1582646022.542 2|mg_ssl_if_mbedtls.c:31  0x3fff259c ciphersuite: TLS-ECDHE-ECDSA-WITH-AES-128-GCM-SHA256
ccm_C26FD9 798 1582646022.557 2|mgos_vfs.c:283          gcp-lts-ca.pem -> /gcp-lts-ca.pem pl 1 -> 1 0x3fff0344 (refs 1)
ccm_C26FD9 799 1582646022.567 2|mgos_vfs.c:377          open gcp-lts-ca.pem 0x0 0x1b6 => 0x3fff0344 gcp-lts-ca.pem 1 => 257 (refs 1)
ccm_C26FD9 800 1582646022.574 2|mgos_vfs.c:536          fstat 257 => 0x3fff0344:1 => 0 (size 1676)
ccm_C26FD9 801 1582646022.593 2|mgos_vfs.c:410          close 257 => 0x3fff0344:1 => 0 (refs 0)
ccm_C26FD9 802 1582646022.598 2|SW ECDSA verify curve 3 hash_len 32 sig_len 72
ccm_C26FD9 803 1582646023.177 2|mgos_vfs.c:283          gcp-lts-ca.pem -> /gcp-lts-ca.pem pl 1 -> 1 0x3fff0344 (refs 1)
ccm_C26FD9 804 1582646023.187 2|mgos_vfs.c:377          open gcp-lts-ca.pem 0x0 0x1b6 => 0x3fff0344 gcp-lts-ca.pem 1 => 257 (refs 1)
ccm_C26FD9 805 1582646023.194 2|mgos_vfs.c:536          fstat 257 => 0x3fff0344:1 => 0 (size 1676)
ccm_C26FD9 806 1582646023ccm_C26FD9 813 1582646025.114 2|mgos_mqtt_conn.c:227    MQTT0 TCP connect ok (0)
ccm_C26FD9 814 1582646025.432 2|mgos_gcp.c:184          ID : projects/atlaspred/locations/us-central1/registries/iot-registry/devices/ccm_C26FD9
ccm_C26FD9 815 1582646025.452 2|mgos_gcp.c:185          JWT: eyJ0eXAiOiJKV1QiLCJhbGciOiJFUzI1NiJ9.eyJhdWQiOiJhdGxhc3ByZWQiLCJpYXQiOjE1ODI2NDYwMjUsImV4cCI6MTU4MjY0OTYyNX0.qSJ0KMtC7HHd7MBlcptBBcpT_Qo3Hyn3SN6zJYTkEbyetovoscQEI3k31nAP-RqN2UjROmXTE8pNzsezbeTSGQ
ccm_C26FD9 816 1582646025.457 2|mgos_gcp.c:186          JWT Refresh Timeout: 3570000
ccm_C26FD9 817 1582646025.646 2|mgos_mqtt_conn.c:219    MQTT0 event: 202
ccm_C26FD9 818 1582646025.650 2|mgos_mqtt_conn.c:271    MQTT0 CONNACK 0
ccm_C26FD9 819 1582646025.657 2|mgos_mqtt_conn.c:208    MQTT0 sub /devices/ccm_C26FD9/commands/# @ 1
ccm_C26FD9 820 1582646025.661 2|mgos_mqtt_conn.c:350    MQTT0 queue drained
ccm_C26FD9 821 1582646025.821 2|mgos_mqtt_conn.c:219    MQTT0 event: 209
ccm_C26FD9 822 1582646029.693 2|mg_rpc.c:482            0x3fff0fa4 GOT FRAME (308): {"id":616,"method":"MQTT.Pub","params":{"topic":"projects/atlaspred/topics/atlaspred-topic","message":"0A04302E30301201301A01302{"id":617,"method":"MQTT.Pub","params":{"topic":"projects/atlaspred/topics/accm_C26FD9 823 1582646029.702 2|tlaspred-topic","message":"0A04302E30301201301A01302204302E30302A05302E3030303204302E30303A04302E3030"}}
ccm_C26FD9 824 1582646029.709 2|mg_rpc.c:376            '616' '' '' 'MQTT.Pub'
ccm_C26FD9 825 1582646029.715 2|mgos_rpc.c:373          Called 'MQTT.Pub', acl for it: '*'
ccm_C26FD9 826 1582646029.719 2|mg_rpc.c:293            MQTT.Pub via UART UART0
ccm_C26FD9 827 1582646029.734 2|mg_rpc.c:612            0x3fff0fa4 SEND FRAME (90): {"id":616,"src":"ccm_C26FD9","error":{"code":500,"message":"Expecting topic and message"}} -> 1
ccm_C26FD9 828 1582646029.740 2|mg_rpc.c:508            0x3fff0fa4 FRAME SENT (1)
ccm_C26FD9 829 1582646029.759 2|mg_rpc.c:482            0x3fff0fa4 GOT FRAME (135): {"iccm_C26FD9 836 1582646029.968 2|mgos_mqtt_conn.c:253    MQTT0 Disconnect
ccm_C26FD9 837 1582646029.973 2|mgos_mqtt_conn.c:543    MQTT0 connecting after 1887 ms
ccm_C26FD9 838 1582646031.868 2|mgos_mqtt_conn.c:467    MQTT0 connecting to mqtt.2030.ltsapis.goog:8883
ccm_C26FD9 839 1582646031.876 2|mg_net.c:911            0x3fff23e4 mqtt.2030.ltsapis.goog:8883 -,-,gcp-lts-ca.pem
ccm_C26FD9 840 1582646031.885 2|mgos_vfs.c:283          gcp-lts-ca.pem -> /gcp-lts-ca.pem pl 1 -> 1 0x3fff0344 (refs 1)
ccm_C26FD9 841 1582646031.895 2|mgos_vfs.c:377          open gcp-lts-ca.pem 0x0 0x1b6 => 0x3fff0344 gcp-lts-ca.pem 1 => 257 (refs 1)
ccm_C26FD9 842 1582646031.901 2|mgos_vfs.c:410          close 257 => 0x3fff0344:1 => 0 (refs 0)
ccm_C26FD9 843 1582646031.908 2|mg_net.c:911            0x3fff2fcc udp://201.6.2.82:53 -,-,-
ccm_C26FD9 844 1582646031.913 2|mg_net.c:779            0x3fff2fcc udp://201.6.2.82:53
ccm_C26FD9 845 1582646031.921 2|mg_net.c:794            0x3fff2fcc udp://201.6.2.82:53 -> 0
ccm_C26FD9 846 1582646031.940 2|mg_net.c:779            0x3fff23e4 tcp://64.233.181.206:8883
ccm_C26FD9 847 1582646032.107 2|mg_net.c:794            0x3fff23e4 tcp://64.233.181.206:8883 -> 0
ccm_C26FD9 848 1582646032.272 2|mg_ssl_if_mbedtls.c:31  0x3fff23e4 ciphersuite: TLS-ECDHE-ECDSA-WITH-AES-128-GCM-SHA256
ccm_C26FD9 849 1582646032.287 2|mgos_vfs.c:283          gcp-lts-ca.pem -> /gcp-lts-ca.pem pl 1 -> 1 0x3fff0344 (refs 1)
ccm_C26FD9 850 1582646032.297 2|mgos_vfs.c:377          open gcp-lts-ca.pem 0x0 0x1b6 => 0x3fff0344 gcp-lts-ca.pem 1 => 257 (refs 1)
ccm_C26FD9 851 1582646032.304 2|mgos_vfs.c:536          fstat 257 => 0x3fff0344:1 => 0 (size 1676)
ccm_C26FD9 852 1582646032.323 2|mgos_vfs.c:410          close 257 => 0x3fff0344:1 => 0 (refs 0)
ccm_C26FD9 853 1582646032.329 2|SW ECDSA verify curve 3 hash_len 32 sig_len 72
ccm_C26FD9 854 1582646032.908 2|mgos_vfs.c:283          gcp-lts-ca.pem -> /gcp-lts-ca.pem pl 1 -> 1 0x3fff0344 (refs 1)
ccm_C26FD9 855 1582646032.918 2|mgos_vfs.c:377          open gcp-lts-ca.pem 0x0 0x1b6 => 0x3fff0344 gcp-lts-ca.pem 1 => 257 (refs 1)
ccm_C26FD9 856 1582646032.925 2|mgos_vfs.c:536          fstat 257 => 0x3fff0344:1 => 0 (size 1676)
ccm_C26FD9 857 1582646032ccm_C26FD9 864 1582646034.848 2|mgos_mqtt_conn.c:227    MQTT0 TCP connect ok (0)
ccm_C26FD9 865 1582646035.165 2|mgos_gcp.c:184          ID : projects/atlaspred/locations/us-central1/registries/iot-registry/devices/ccm_C26FD9
ccm_C26FD9 866 1582646035.185 2|mgos_gcp.c:185          JWT: eyJ0eXAiOiJKV1QiLCJhbGciOiJFUzI1NiJ9.eyJhdWQiOiJhdGxhc3ByZWQiLCJpYXQiOjE1ODI2NDYwMzQsImV4cCI6MTU4MjY0OTYzNH0.llHibjUzp0hdTu-jt3MReZiXHi5vxJO0MG-A06XlDZeFmhNNwvaJ9pS9HjzYiOd9Wmjwr5lnJOqtBFbwfOWHVw
ccm_C26FD9 867 1582646035.190 2|mgos_gcp.c:186          JWT Refresh Timeout: 3570000
ccm_C26FD9 868 1582646035.384 2|mgos_mqtt_conn.c:219    MQTT0 event: 202
ccm_C26FD9 869 1582646035.388 2|mgos_mqtt_conn.c:271    MQTT0 CONNACK 0
ccm_C26FD9 870 1582646035.395 2|mgos_mqtt_conn.c:208    MQTT0 sub /devices/ccm_C26FD9/commands/# @ 1
ccm_C26FD9 871 1582646035.400 2|mgos_mqtt_conn.c:350    MQTT0 queue drained
ccm_C26FD9 872 1582646035.560 2|mgos_mqtt_conn.c:219    MQTT0 event: 209
ccm_C26FD9 873 1582646039.694 2|mg_rpc.c:482            0x3fff0fa4 GOT FRAME (308): {"id":618,"method":"MQTT.Pub","params":{"topic":"projects/atlaspred/topics/atlaspred-topic","message":"0A04302E30301201301A01302{"id":619,"method":"MQTT.Pub","params":{"topic":"projects/atlaspred/topics/accm_C26FD9 874 1582646039.703 2|tlaspred-topic","message":"0A04302E30301201301A01302204302E30302A05302E3030303204302E30303A04302E3030"}}
ccm_C26FD9 875 1582646039.710 2|mg_rpc.c:376            '618' '' '' 'MQTT.Pub'
ccm_C26FD9 876 1582646039.715 2|mgos_rpc.c:373          Called 'MQTT.Pub', acl for it: '*'
ccm_C26FD9 877 1582646039.720 2|mg_rpc.c:293            MQTT.Pub via UART UART0
ccm_C26FD9 878 1582646039.735 2|mg_rpc.c:612            0x3fff0fa4 SEND FRAME (90): {"id":618,"src":"ccm_C26FD9","error":{"code":500,"message":"Expecting topic and message"}} -> 1
ccm_C26FD9 879 1582646039.741 2|mg_rpc.c:508            0x3fff0fa4 FRAME SENT (1)
ccm_C26FD9 880 1582646039.760 2|mg_rpc.c:482            0x3fff0fa4 GOT FRAME (135): {"iccm_C26FD9 887 1582646039.969 2|mgos_mqtt_conn.c:253    MQTT0 Disconnect
ccm_C26FD9 888 1582646039.975 2|mgos_mqtt_conn.c:543    MQTT0 connecting after 2019 ms
ccm_C26FD9 889 1582646042.002 2|mgos_mqtt_conn.c:467    MQTT0 connecting to mqtt.2030.ltsapis.goog:8883
ccm_C26FD9 890 1582646042.010 2|mg_net.c:911            0x3fff259c mqtt.2030.ltsapis.goog:8883 -,-,gcp-lts-ca.pem
ccm_C26FD9 891 1582646042.019 2|mgos_vfs.c:283          gcp-lts-ca.pem -> /gcp-lts-ca.pem pl 1 -> 1 0x3fff0344 (refs 1)
ccm_C26FD9 892 1582646042.029 2|mgos_vfs.c:377          open gcp-lts-ca.pem 0x0 0x1b6 => 0x3fff0344 gcp-lts-ca.pem 1 => 257 (refs 1)
ccm_C26FD9 893 1582646042.035 2|mgos_vfs.c:410          close 257 => 0x3fff0344:1 => 0 (refs 0)
ccm_C26FD9 894 1582646042.042 2|mg_net.c:911            0x3fff26f4 udp://201.6.2.82:53 -,-,-
ccm_C26FD9 895 1582646042.047 2|mg_net.c:779            0x3fff26f4 udp://201.6.2.82:53
ccm_C26FD9 896 1582646042.054 2|mg_net.c:794            0x3fff26f4 udp://201.6.2.82:53 -> 0
ccm_C26FD9 897 1582646042.075 2|mg_net.c:779            0x3fff259c tcp://64.233.181.206:8883
ccm_C26FD9 898 1582646042.236 2|mg_net.c:794            0x3fff259c tcp://64.233.181.206:8883 -> 0
ccm_C26FD9 899 1582646042.401 2|mg_ssl_if_mbedtls.c:31  0x3fff259c ciphersuite: TLS-ECDHE-ECDSA-WITH-AES-128-GCM-SHA256
ccm_C26FD9 900 1582646042.416 2|mgos_vfs.c:283          gcp-lts-ca.pem -> /gcp-lts-ca.pem pl 1 -> 1 0x3fff0344 (refs 1)
ccm_C26FD9 901 1582646042.426 2|mgos_vfs.c:377          open gcp-lts-ca.pem 0x0 0x1b6 => 0x3fff0344 gcp-lts-ca.pem 1 => 257 (refs 1)
ccm_C26FD9 902 1582646042.433 2|mgos_vfs.c:536          fstat 257 => 0x3fff0344:1 => 0 (size 1676)
ccm_C26FD9 903 1582646042.451 2|mgos_vfs.c:410          close 257 => 0x3fff0344:1 => 0 (refs 0)
ccm_C26FD9 904 1582646042.457 2|SW ECDSA verify curve 3 hash_len 32 sig_len 72
ccm_C26FD9 905 1582646043.038 2|mgos_vfs.c:283          gcp-lts-ca.pem -> /gcp-lts-ca.pem pl 1 -> 1 0x3fff0344 (refs 1)
ccm_C26FD9 906 1582646043.048 2|mgos_vfs.c:377          open gcp-lts-ca.pem 0x0 0x1b6 => 0x3fff0344 gcp-lts-ca.pem 1 => 257 (refs 1)
ccm_C26FD9 907 1582646043.055 2|mgos_vfs.c:536          fstat 257 => 0x3fff0344:1 => 0 (size 1676)
ccm_C26FD9 908 1582646043ccm_C26FD9 915 1582646044.988 2|mgos_mqtt_conn.c:227    MQTT0 TCP connect ok (0)
ccm_C26FD9 916 1582646045.306 2|mgos_gcp.c:184          ID : projects/atlaspred/locations/us-central1/registries/iot-registry/devices/ccm_C26FD9
ccm_C26FD9 917 1582646045.326 2|mgos_gcp.c:185          JWT: eyJ0eXAiOiJKV1QiLCJhbGciOiJFUzI1NiJ9.eyJhdWQiOiJhdGxhc3ByZWQiLCJpYXQiOjE1ODI2NDYwNDQsImV4cCI6MTU4MjY0OTY0NH0.6gmKDafi3E9KIGs4XUqzuO91i7YMV-Yzpxide-T0ksnSBVINu-EcJS9u0qiPbLfj7vtzp5reVpfC0ycZP8XuDQ
ccm_C26FD9 918 1582646045.331 2|mgos_gcp.c:186          JWT Refresh Timeout: 3570000

Google IoT seem to drop a connection after your attempt to publish to projects/atlaspred/topics/atlaspred-topic. Please use a gcloud tool to publish and see whether that works or not.

Hi Ism,

Is the Json i am using ok for cloud publishing ?

{“id”:6,“method”:“MQTT.Pub”,“params”:{“topic”:“atlaspred-topic”,“message”:“0A0532392E30371207393235372E30301A07343939382E30302204352E31372A04312E30303204312E32333A04302E3030”}}

Error message says:
“error”:{“code”:500,“message”:“Expecting topic and message”}} -> 1

Thank You

Yes the JSON looks good.
Not sure why VCON replies with the error message. Can you try hivemq MQTT server with the same topic/message?

Hi Ism,

I got this on Google logs:

Expand all | Collapse all{
insertId: “pt50brffbx0il”
jsonPayload: {
eventType: “PUBLISH”
protocol: “MQTT”
resourceName: “projects/atlaspred/locations/us-central1/registries/iot-registry/devices/2798386857612831”
serviceName: “cloudiot.googleapis.com
status: {
code: 3
description: “INVALID_ARGUMENT”
message: “PUBLISH: Invalid MQTT publish topic: ‘projects/atlaspred/topics/atlaspred-topic’.”
}
}
labels: {
device_id: “ccm_C26FD9”
}
logName: “projects/atlaspred/logs/cloudiot.googleapis.com%2Fdevice_activity”
receiveTimestamp: “2020-02-25T17:10:47.253246372Z”
resource: {
labels: {
device_num_id: “2798386857612831”
device_registry_id: “iot-registry”
location: “us-central1”
project_id: “atlaspred”
}
type: “cloudiot_device”
}
severity: “ERROR”
timestamp: “2020-02-25T17:10:46.243489919Z”
}

Right, so the issue is not with VCON.
The issue is with Google IoT. Please check out what topics can be used for publishing, and use only allowed topics.