Skip to content

ENABLING NET MQTT LOG DEBUG #64821

Answered by jukkar
zafersn asked this question in Q&A
Nov 5, 2023 · 1 comments · 2 replies
Discussion options

You must be logged in to vote

The following worked with latest upstream:

west build -b native_posix -d build/mqtt-sample zephyr/samples/net/mqtt_publisher -- -DCONFIG_NET_SHELL=y -DCONFIG_MQTT_LOG_LEVEL_DBG=y -DCONFIG_NET_LOG=y -DCONFIG_NATIVE_UART_0_ON_STDINOUT=y
./build/mqtt-sample/zephyr/zephyr.exe

and then I am seeing

[00:00:00.120,000] <inf> net_mqtt_publisher_sample: mqtt_connect: -110 <ERROR>
[00:00:00.630,000] <dbg> net_mqtt_sock_tcp: mqtt_client_tcp_connect: (main): Created socket 0

where the mqtt library prints debug messages. There should be no difference between 3.5 and current development head in this respect.

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@zafersn
Comment options

@jukkar
Comment options

jukkar Nov 13, 2023
Collaborator

Answer selected by zafersn
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants