Author Topic: re-Post "Finding my way around McThings"  (Read 430 times)


  • We Connect Things To The Internet... That Can't Be Plugged In.
  • Administrator
  • Jr. Member
  • *****
  • Posts: 68
    • View Profile
re-Post "Finding my way around McThings"
« on: June 06, 2016, 11:00:20 am »
jeroens1din General4
Finding my wat around McThings
Just received the package (thanks) and was wondering how best to get started. Is there any documentation. Like configuring the Router, MQTT settings etc? Could not find anything.
My plan is to create a zoned temperature setup with 8-10 zones and was thinking to use an MQTT local server to report the current temp to in 5-10 minutes interval…Like

Hello. What you explain is a very simple setup I could guide you through the steps, but the problem is right now the firmware, and some MQTT bugs. Do you have a local MQTT broker installed in your network right now?Like
By the way, there is also a bug in the temperature code so I have not yet managed to get the temperature from the mcModule, as soon as the abow bugs is handled then I could help you with this user case.Like

That would be great. Not yet planning to install on local network (raspberry Pi)Like

Ahh okey, I would normally recommend mosquitto as broker but if I should install a broker today I would actually install I have not yet tested this broker but I like what I have read about it. And I have planned to test this myself next week.

Share on Facebook Share on Twitter


  • Sr. Member
  • ****
  • Posts: 287
  • Location: Sweden
    • View Profile
Re: re-Post "Finding my way around McThings"
« Reply #1 on: June 07, 2016, 03:32:38 am »
If you download mcStudio V0.7-891+ then it is possible to use the temperatur sensor.
I cant get MQTT running with version V0.6-355 of the mcRouter so right now i recommend using V0.6-354.

1: Start mcStudio and click Tools / Devices, Connect to your gateway and then click Gateway Config. Enter your MQTT broker IP address and port and save the config.
2: Connect to one of your mcModules.
3: create a new project and a simple code like this will do a reading from the temperatur sensor and then publish the result to your MQTT broker with topic mcThings/Temperature/BasementA and the temperatur as the payload.

Code: [Select]
Class MQTTTest
    Shared Event sendMQTT() RaiseEvent Every 1 Minutes
        LedRed = True
        Dim payload As ListOfByte = New ListOfByte()
        Dim TempC As Float = TempSensor.GetTemp
        Dim TempString As String = TempC.ToString()
        Lplan.Publish("mcThings/Temperature/BasementA", payload)
        LedRed = False
    End Event
End Class

4: click File / Add Library Code and select Temp Sensor.
5: Save / Build / Run the application and your mcModule will start sending MQTT messages with the temperatur to the broker.
6: when you are happy with the function click Save / build/ Load the program in the device, to save the code so that it will continue to run when you stop the debugging

mcThings have published information videos on some of the parts mentioned above, please take a look at it and i think things fill fall into place for you.

And if you have any questions, just let us know.

Like Like x 1 View List