Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Messages - mc-T2

Pages: 1 [2] 3 4 ... 17
Announcements / Hackaday coin cell contest!
« on: December 01, 2017, 01:49:51 pm »
Hello everyone,

Just wanted to let you know that ( is running a coin-cell challenge! There are multiple prizes and categories for showcasing what you can do with electronics and a coin-cell!

This is a perfect contest for the mcModule devices because, as you know, they are already powered by a coin cell battery!

Check out the link to the contest to see the details and how to submit a project:

Good luck and we hope to see some cool projects!


mc-Gateway / Re: beacondata API
« on: November 09, 2017, 10:44:24 am »
here is the attached document to make it easier. This document is also available on our website ( )

mc-Gateway / Re: Gateway connected but the mc205 isn't
« on: October 25, 2017, 04:04:49 pm »
Ok yes, you are working with an older version of mcOS (firmware) that could be causing this issue.

Please update the device to the newest version using your mcDongle and mcOTA. You can check out this video that gives you an idea of the process.

The video is a little older and we use the mcMod120 as the example but the process is the same. You need to download the newest firmware file from our website ( and then download mcOTA ( . You will then connect to the device using the mcDongle and mcOTA which then allows you to update the firmware using the newest version you just downloaded.

*Keep in mind, when you press 'search' in mcOTA, you then need to power the device to make it 'discoverable' to the mcDongle. You can either plug the 205 into USB or put the jumper on the battery pins to power the device

After you update the device, try to connect to the device through the gateway and let us know how it goes

mc-Gateway / Re: Gateway connected but the mc205 isn't
« on: October 25, 2017, 09:44:16 am »
Can you tell us what version of firmware is on the mcDemo205?

You can tell when you go to the device menu and have the option to connect to the mcDemo205 device. Take a screenshot of the device menu with the mcDemo205 device - We'd like to see the version of firmware that is on the device.

If it is not at the latest version (mcOS v0.9.615), you will need to update the device using your mcDongle and the mcOTA application.

mc-Platform General / Re: Any plans to work with the Blynk platform?
« on: October 23, 2017, 03:37:20 pm »
Does Blynk use webhooks for getting data into their cloud?

mc-Gateway / Re: Gateway connected but the mc205 isn't
« on: October 23, 2017, 01:38:26 pm »
Hi geeklv,

seems like the network side of things is up to date and working (if the gateway is connected to Losant).

when you go into mcStudio and then select the gateway from your list, what happens?
Are you able to see the gateway in the device list?
If so, it doesn't connect when you press 'connect gateway'?

You must have been able to connect to the gateway at some point to configure it the MQTT settings.

Also, you need to connect to the mcDemo205 device at least once to register the device with the gateway. This authorizes the gateway to relay the information from the 205 - If you don't register the device to the gateway it will not be able to send information to losant.
To do this, connect to the gateway. You will shortly see the mcDemo205 device show up in the device list (ensure the mcDemo205 is powered). Select the device and click' connect device'. When the device is connected, you can either disconnect the device or hit the reset button on the toolbar in mcStudio. The device will then be registered to the gateway

Let us know if this helps

Hi geeklv, and thanks for your question.

Yes, the mcDemo205 can be programmed to send Sigfox messages without physically pressing the button. We do list an example in the documentation where you can press the button to send a Sigfox message (i assume that his the example you are working with?).

However, you can program the device to send information on regular intervals to the cloud using the Sigfox network. Check through the documentation for other examples and here are some additional suggestions:

1) There are some users on the forum that have uploaded scripts that you can use for your 205 (check out Nick_W's posts)

2) I have attached a couple of scripts that you can use

a) SIGFOX GPS - this example allows you to send a GPS signal on a regular interval. You can modify the code to send the GPS signal whenever it is appropriate for you (every 10 minutes, every hour, every day, etc.)

b) 205TempSigfox - This allows you to send the temperature from the device to the cloud using Sigfox. Again, you can modify the intervals.

Hope that helps

mc-Gateway / Re: Updated gateway now connection problems
« on: October 19, 2017, 10:23:05 am »
Hi lukevikas,


1) Power cycling - This is just either pressing the reset button the gateway OR unplugging the gateway from power and then plugging it back in. Basically, you are resetting the gateway.

2) Re-Configuring - You can enter the SSID within the gateway configuration in mcStudio. If you want to change the confifguration, you can connect via WPS and then go and enter the SSID OR connect with ethernet and then change the SSID for your WIFI. Check out this video to help:

Hope that helps,
let us know if you have any other questions

MQTT / Re: Trouble sending/receiving data to CloudMQTT
« on: October 03, 2017, 12:12:42 pm »
Can you try leaving the client ID blank within the gateway configuration and also, subscribe to the exact topic (mcThings/Testing) in the application and see if that works.

As you can see from the video, this does work!  :) just need to figure out where this is going wrong for you

MQTT / Re: Trouble sending/receiving data to CloudMQTT
« on: October 03, 2017, 11:24:19 am »
Hi Babramovitch,

Yes, that video was put together using an older version of mcStudio (when the gateway configuration did not include all the features as it does today).

Client ID - You have the same client ID in your gateway settings as you do in your app settings - this could be the problem. They need to be unique (not the same) otherwise they can't 'talk' to eachother. Try changing the client ID either in the gateway config or on the app to something different and try it out.

As for WIFI, You can connect the gateway using WPS or, you can enter the SSID and Password into the gateway configuration (you need to connect the gateway to either WPS or ethernet first to be able enter those details). If you are already connected to WIFI (most likely through WPS), then you don't need to enter the SSID and password info - the gateway will remember the WPS details and continue to connect to that network until you change it

Everything else appears to be good - let us know if changing the client ID allows this to work for you

mc-Demo205 / Re: how I can to write and read data in the flash memory?
« on: August 16, 2017, 09:44:52 am »

We will be documenting the Log functions in the next release - it will be updated within the documentation.

Glad that you have the temperature information going into Losant, this means that you have that side of things setup properly. And also good that you were able to update the device and mcStudio to the latest version.

I believe that you are using the GPS function and Log function:

if a GPS acquisition is ongoing, the log read has to wait for that to finish. Currently (this is changing when we do the warm start) both the logging and gps share a single SPI bus so they can't both happen at the same time.... This might lead to some less that elegant behaviours when debugging... for example if it takes too long for the GPS to finish mcStudio might stop and think the device is not responding...
The system will recover itself. So basically the execution of that line will be suspended until the gps acquisition is done.

Try loading the code directly into the device and see how everything works. It sounds like the issue you are having resides strictly within the debugging of the code and could be affected by what we mention above

Hope that helps,

mc-Demo205 / Re: how I can to write and read data in the flash memory?
« on: August 04, 2017, 09:39:57 am »

1) Have you setup Losant properly? By that I mean, have you setup the device properly within Losant and entered the correct device ID into your code for the device?
2) Have you configured your gateway properly to direct the information to your account within Losant?
3) You do need to ensure that you are in range of the gateway so that you can send the information out
4) When you first power the device, you need to ensure that it is in range of the mcGateway for a period of time so that it can capture the current time from the gateway. If you don't do this, the device will still try to capture GPS data however it will not know the time and hence, the data will not be relevant as there will be no time stamp along with it

To help, check out the below walk-through for setting up Losant:

You can also check out this video that describes the configuration and setup within Losant. The example in this video does not use the above code but should give you a good idea of how to setup and configure your equipment and their cloud to receive data:

Hope that helps, let us know how your progress

mc-Demo205 / Re: how I can to write and read data in the flash memory?
« on: August 02, 2017, 03:14:28 pm »
There is a log function that is not yet described in our documentation. In an upcoming release, we will be releasing this information within the new documentation for mcStudio and the mcDemo205. That said, we do have some code that you can modify for your use to log information into the flash of the device. The below code is for an example using our partner, Losant, so you may want to modify this for your needs. The code is meant to log GPS coordinates and temperature and then, when in range of a gateway, you would press SW1 and the information would then be transferred to the Losant cloud to populate onto a map onto a dashboard.

here is the code and there are also some additional notes below:

Code: [Select]
Class gpsTracker
    Shared Locations As ListOfObject
    Const GPS_TIMEOUT_uS As Integer = 120000000 '120s
    'Const GPS_TIMEOUT_uS As Integer = 1000000 '1s
    Const GPS_MIN_SATS As Integer = 3 '3 sattelites minimum
    Const LosantDeviceID As String = "YOUR LOSANT DEVICE ID"
    Const LosantTopic As String = "losant/" + LosantDeviceID + "/state"
    Shared Event Boot()
        Locations = New ListOfObject()
    End Event
    Shared Event StartLocationAcquisition() RaiseEvent Every 7 Minutes
        Led2 = True
        Led2 = False
        Device.StartGPS(GPS_TIMEOUT_uS, GPS_MIN_SATS)
    End Event
    Shared Event LocationDelivery()
        Dim lat As Float = Device.GetLatitude()
        Dim lon As Float = Device.GetLongitude()
        Dim tmp As Float = TempSensor.GetTemp()
        If lat.IsNaN() Or lon.IsNaN() Then
            Dim entry As ListOfByte = New ListOfByte()
            Log.Write(0, entry)
        End If
    End Event
    Shared Event SW1FallingEdge()
        Led3 = True
        Led3 = False
        Dim count As Integer = 0
        Dim offset As Integer = 0
        Dim lo As ListOfObject
        lo = Log.Read(offset)
        While lo <> Nothing
            Dim o As Object
            o = lo(0)
            offset = o.Cast(Integer)
            o = lo(1)
            Dim dtm As DateTime = o.Cast(DateTime)
            o = lo(2)
            Dim type As Integer = o.Cast(Integer)
            o = lo(3)
            Dim entry As ListOfByte = o.Cast(ListOfByte)
            Dim tmp As Float = entry.ExtractFloat(0)
            Dim lat As Float = entry.ExtractFloat(4)
            Dim lon As Float = entry.ExtractFloat(8)
            Dim jDate As Json = New Json()
            jDate.Add("$date", dtm)
            Dim jData As Json = New Json()
            jData.Add("temperature", tmp)
            Dim locStr As String = lat.ToString() + "," + lon.ToString()
            jData.Add("location", locStr)
            Dim jPayload As Json = New Json()
            jPayload.Add("time", jDate)
            jPayload.Add("data", jData)
            While Not Lplan.Publish2(LosantTopic, jPayload.ToListOfByte)
            End While
            count += 1
            If count = 30 Then
                count = 0
            End If
            lo = Log.Read(offset)
        End While
    End Event
End Class

Additional notes -

1) you'll also want to add the temperature sensor library and the below GPS library if you want to use the code above with Losant:
Code: [Select]
Class GpsLocation
    Public Latitude As Float
    Public Longitude As Float
    Public Timestamp As DateTime
    Public Sub New(lat As Float, lon As Float, dtm As DateTime)
        Latitude = lat
        Longitude = lon
        Timestamp = dtm
    End Sub
End Class

2) I believe the flash will keep storing until you have enough data to start overwriting. If you do want to clear the flash, you can include or run the below function on a new script
Code: [Select]
3) if you are interested in working with the above code for a test, keep in mind that the device needs to be powered and in-range of an mcGateway for a suggested 30 minutes to ensure that the device grabs the time from the gateway. This is so that you can associated a time with the GPS coordinates

4) And, if you are going to use the above code and leave it unmodified to work with Losant, you'll notice at the end of the code that we have a time delay. This is due to how the Losant platform works which can only consumer a certain amount of data every 30 seconds. The time delay allows the device to send out a batch of data then wait and keep sending to ensure that Losant receives all the messages.

Hope that helps!

Hi Bill,

Very interesting use-case. A video would be a great way to explore this however, we are in the midst of a couple of projects that are taking most of our time currently - we will not be able to make a video to help here.

That said, if you could provide some additional information, maybe someone from the community could help you out with some programming or suggestions for your use-case. It would help if:
- you could provide details on exactly how you envision your setup (alerts, what do you want the water heater to do and when, etc)
- provide information (maybe even pictures) of the hardware/equipment you have and what you would like to do
- any other details that might help some of the mcThings users to help you out

As you work through the project, our team and other users can help to answer questions here on the forum


Can you post a screen shot of the device menu (showing your gateway IP) please?

Also, a screenshot of the error would help too


Pages: 1 [2] 3 4 ... 17