Complete the code to import the MQTT client library.
import [1]
The paho.mqtt.client module is the standard Python library for MQTT communication.
Complete the code to create an MQTT client instance named 'client'.
client = [1]()The MQTT client is created by calling paho.mqtt.client.Client().
Fix the error in the code to connect the client to the MQTT broker at 'broker.hivemq.com' on port 1883.
client.[1]('broker.hivemq.com', 1883)
The correct method to connect the client to the broker is connect().
Fill both blanks to subscribe the client to the topic 'home/room1/temperature' with QoS level 1.
client.[1]('[2]', 1)
Use subscribe method with the topic 'home/room1/temperature' to receive messages on that topic.
Fill all three blanks to publish the message '22.5' to the topic 'home/room2/humidity' with QoS 0.
client.[1]('[2]', [3], qos=0)
Use publish method with the topic 'home/room2/humidity' and message '22.5' to send data.