# How can i use mqtt in lvgl

**URL:** <http://forum.squareline.io/t/how-can-i-use-mqtt-in-lvgl/153>\
**Category:** How to\
**Created:** [March 18, 2022, 7:05pm UTC](http://forum.squareline.io/t/how-can-i-use-mqtt-in-lvgl/153 "2022-03-18T19:05:25Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![SquareLine\_Support](http://forum.squareline.io/user_avatar/forum.squareline.io/squareline_support/32/47_2.png) [@SquareLine\_Support](http://forum.squareline.io/u/SquareLine_Support)\
**Post date:** [March 21, 2022, 9:13am UTC](http://forum.squareline.io/t/how-can-i-use-mqtt-in-lvgl/153/2 "2022-03-21T09:13:08Z")

</div>

Hi,

MQTT exists “next to” LVGL so they shouldn’t cause bugs in each other.

To react on an MQTT message in LVGL, just call `lv_arc_set_value()` or similar function when you get a message.

Note that LVGL is not thread safe so please read this section of LVGL’s docs:  
[https://docs.lvgl.io/master/porting/os.html](https://docs.lvgl.io/master/porting/os.html)

---

_[View the full topic](http://forum.squareline.io/t/how-can-i-use-mqtt-in-lvgl/153)._
