Author Topic: mc-Studio not connecting to my devices  (Read 1104 times)

gaston

  • Newbie
  • *
  • Posts: 26
    • View Profile
mc-Studio not connecting to my devices
« on: December 22, 2016, 04:09:25 pm »
I had put aside this whole mcThings about 2 months ago bercause I could not get a reliable and consistent environment.

Last night, I went back at it. Update all softwares and programs to the latest version. I reinitailized only 2 of my 15 mcModule 110. Just a few  for testing purpose.
I discover  this great documentation how to used mcThings with Losant. For a newbie and not programmer like me, this is gold.
https://www.losant.com/blog/getting-started-with-mc-things-and-losant

I was able to create a program and run it seeing the result in Losant.
However today, I am back at square one. McStudio cannot connect to my devices, I open both TOOLS Device Maintenance and Connection as weel as Received Beacon.
I can see my two device in Recieved Beacon being received many time while Connecting cannot fidn them and connect.
I would have though that if McStudio can see my devices in Beacon it should also be able to see them in Maintenance as well.

Any suggestion where should I go from here?

Share on Facebook Share on Twitter


mc-John

  • Global Moderator
  • Full Member
  • *****
  • Posts: 212
    • View Profile
Re: mc-Studio not connecting to my devices
« Reply #1 on: December 28, 2016, 02:56:48 pm »
Some questions:
Do you have one or more gateways?
Did you load a working program, like blinky?
Do you see if the device resets?
Does the problem disappear if you try to connect and then power the device that you try to connect down and up again?
Can you make a screenshot of the device maintanance screen?

Thx
 

mc-T2

  • Administrator
  • Sr. Member
  • *****
  • Posts: 252
  • mc-Things! The opportunities are endless!
  • Location: Canada
    • View Profile
Re: mc-Studio not connecting to my devices
« Reply #2 on: January 03, 2017, 09:25:27 am »
Just to followup - We did release new firmware recently that fixes some connection issues that we were seeing within the mcThings platform.
Can you please download the new updates (including the new mcOTA application - required)
Thanks
Need more mc-Modules, mc-Gateways or other mc-Things? Check out our product page: www.mcthings.com/products. mc-Development kits are available too!
Check out a live Dashboard using mcThings and Losant! Click here: https://goo.gl/ST43hB

SK

  • Newbie
  • *
  • Posts: 18
    • View Profile
Re: mc-Studio not connecting to my devices
« Reply #3 on: February 23, 2017, 06:05:19 pm »
I recently installed the new version of Studio and updated my device firmware but now I can't connect my device.

I go Tools -> Device -> Connect Testboard Gateway -> My device doesn't appear and I've waited 20min.

What can I do?

SK

  • Newbie
  • *
  • Posts: 18
    • View Profile
Re: mc-Studio not connecting to my devices
« Reply #4 on: February 23, 2017, 07:17:10 pm »
I reinstalled Studio and connected to device before opening up my project. It seems to have worked but very unstable. Pls fix!

mc-Abe

  • Full Member
  • ***
  • Posts: 167
    • View Profile
    • mc-Things
Re: mc-Studio not connecting to my devices
« Reply #5 on: February 24, 2017, 04:42:45 am »
Could you provide a bit more information on the scenario that caused the problem for you? Can you reproduce this problem? If so, step by step instructions for us to reproduce your problem would be great.

SK

  • Newbie
  • *
  • Posts: 18
    • View Profile
Re: mc-Studio not connecting to my devices
« Reply #6 on: February 25, 2017, 03:52:45 am »
I updated the Studio on Friday (17th Feb) and then the firmware on my Demo 205 on Wednesday (22nd Feb). Then when I created a new project and tried to connect, the Testboard gateway connected but then couldn't find my device.
I closed the studio and then re-opened and tried again but it still didn't work.
I closed the project and then studio and then reopened it (so it would open without any projects already on it) and tried to connect but it didn't work. I kept trying 4 or 5 more times and even waited 20-30 min for it to find my device.
I checked my FTDI drivers but they were the latest version so as a last resort I uninstalled and then reinstalled the same latest version of studio and then immediately connected my device before opening any projects. This worked and I have had no further problems with connecting so far.

I'm not sure what made it finally work.  :-\

Cochrane

  • Newbie
  • *
  • Posts: 10
    • View Profile
Re: mc-Studio not connecting to my devices
« Reply #7 on: March 02, 2017, 12:36:36 am »
I'm also having issues getting Studio to connect to my Gateway. I cant see any beacons or devices other than the two test items in the devices list.
I've done an OTA update on the Gateway, which said it worked, but I don't really know if the USB one is taking? There doesn't seem to be any real validation that its taken, and since I cant see my device, I cant find out if it did.

As I'm a newbie to the IOT devices, and just started using Arduinos a few months ago, I find the updates on the devices and gateway not that simple. Especially the USB portion. Not that it's hard, it's just not convenient for mass market. OTA would be great if I could just hit every device I have and update all at once. (sorry,  :-[ frustrated...and just my 2cents)

When I do the USB update, I push RESET with USB stick in, then press and hold USER when the green light comes on. I hold it until it goes solid, and then the light on my USB comes on. Then I release and wait for quite a while. The light always seems to be flashing.

How long should it take? seconds, minutes?
How do I confirm?

Thanks!

mc-T2

  • Administrator
  • Sr. Member
  • *****
  • Posts: 252
  • mc-Things! The opportunities are endless!
  • Location: Canada
    • View Profile
Re: mc-Studio not connecting to my devices
« Reply #8 on: March 02, 2017, 11:08:03 am »
Hey Cochrane,

USB gateway update - It looks like you might be doing this improperly. When you put your USB into the mcGateway, you need to press and hold the reset switch (keeping the power off on the device) and before you let the power button go, also hold down the user switch. Then release the power switch (which will then power the gateway) and continue to hold the user switch for a couple of seconds and then release.

Essentially, this puts the mcGateway in a bootloader mode which allows it to read the BIN file on the USB stick and then complete the update. Here are the steps from our mcGateway walk-through guide https://static1.squarespace.com/static/5644f11fe4b0d6ca7d80d351/t/576c4a37e4fcb5bcdb3a3316/1466714681893/mcGateway+Quick+Start+Guide+%28002%29.pdf (page 6):

Quote
In order to update the Application processor, follow the steps below:
1. Place the “mcGw110.bin” file obtained from the website on a USB flash drive formatted with a FAT32
filesystem. Make sure to not change the name of the file from “mcGw110.bin”.
2. Connect the USB flash drive to the USB port.
3. Either power cycle or reset your mc-Gateway while holding down the “USER SW” and continue to hold
down the “USER SW”.
4. The bootloader will show a fast blinking pattern using the green “STATUS” LED while it looks to see
whether the “USER SW” is pressed or not.
5. The bootloader will confirm that it has seen the “USER SW” pressed by showing 3 or 4 slow blinks using
the green “STATUS” LED. At this point you can release the “USER SW”.

Can you try this and let us know if you are still having issues?

Seeing the gateway in mcStudio - The gateway and the PC you are using do need to be on the same subnet so they can communicate with eachother properly. We have seen some users who have this issue and correct it through their network (sometimes it is a router issue). If the Gateway is ont he same subnet, you should be able to see it within mcStudio and then you can ensure that the new firmware is updated within the device menu screen.

Hope that helps!
Need more mc-Modules, mc-Gateways or other mc-Things? Check out our product page: www.mcthings.com/products. mc-Development kits are available too!
Check out a live Dashboard using mcThings and Losant! Click here: https://goo.gl/ST43hB

Cochrane

  • Newbie
  • *
  • Posts: 10
    • View Profile
Re: mc-Studio not connecting to my devices
« Reply #9 on: March 03, 2017, 12:16:49 am »
Thanks very much T2. I tried that, and still not sure if it took.
I still can't see it on the network. I've tried doing it through a wired connection and then I did a WIFI connection using the WPS button. The router said it connected, but I cant see it in studio. I'm sure I'm just doing something wrong, but not sure what.

I cant tell if its a subnet thing as I don't know what the settings of the gateway are, but Id assume they are auto assigned once it connects to the network either via Ethernet or WIFI?

mc-T2

  • Administrator
  • Sr. Member
  • *****
  • Posts: 252
  • mc-Things! The opportunities are endless!
  • Location: Canada
    • View Profile
Re: mc-Studio not connecting to my devices
« Reply #10 on: March 03, 2017, 10:08:32 am »
Hey Cochrane,
The reason why the PC and the mcGateway need to be on the same subnet is because they communicate over UDP.
Do you have multiple routers in your network? Can you describe your network setup so that we can try and help please?
Thanks!
Need more mc-Modules, mc-Gateways or other mc-Things? Check out our product page: www.mcthings.com/products. mc-Development kits are available too!
Check out a live Dashboard using mcThings and Losant! Click here: https://goo.gl/ST43hB

Cochrane

  • Newbie
  • *
  • Posts: 10
    • View Profile
Re: mc-Studio not connecting to my devices
« Reply #11 on: March 03, 2017, 04:42:55 pm »
I Have a Telus internet connection with a modem/router (Lets call this Network1)
I Have an additional router that I use for a secondary WIFI network. (Lets Call it : Network2)
My PC is WIFI connected to the Network2 Router
My mcGateway was WPS connected to the same Network2 WIFI that the PC is connected to.

I've also tried a Hardwire conenction to the mcGateway on Network1 and the PC WIFI conencted to Network1.

Neither of them worked unfortuantely.

Is there a way to see the values or settings on the mcGateway? I can see the version, etc through the mcDongle when I connect to it, but nothing else.

mc-T2

  • Administrator
  • Sr. Member
  • *****
  • Posts: 252
  • mc-Things! The opportunities are endless!
  • Location: Canada
    • View Profile
Re: mc-Studio not connecting to my devices
« Reply #12 on: March 06, 2017, 03:26:10 pm »
Hey Cochrane,

Hmm, there must be something within the network that is causing this communication issue. As mentioned, the PC and the gateway speak using UDP and hence they need to be on the same subnet.
Troubleshooting - This is hard as we don't know if there are any settings that you have changed within the routers (sometimes the default settings can cause blockages too). BTW - I have the same setup, using TELUS provided equipment, but only one network (your network #1) and everything works fine without any network changes at all. I wonder if there is something on the setup of the other network that is causing this
Can you try the following:

- Can you confirm that you see a solid Amber light on the gateway when it is connected to the network (Either ethernet or WIFI). This light indicates that you have a network connection.

- is it possible to take down 'Network 2' for the purposes of testing. If you can take network 2 offline and then try to connect to the gateway using your PC and the gateway on network #1. If this works, you should see the gateway show up in the device menu as a device that you can connect to. If this works (and it should as this would be the same setup I have), then it would suggest that there is an issue with the other network that is hampering the communication between the gateway and your PC for some reason.

Gateway versions:
You can see the Host processor version (LPLAN Version) using mcOTA however, you cannot see the application processor version (GWVersion) until you can see the gateway within the device menu in mcStudio. Note - the below picture shows where you would see the GWVersion and the picture is out of date. You should be at GWVersion 0.6-367 and LpLanVersion 0.8-421 

Let us know about the above
Thanks
Need more mc-Modules, mc-Gateways or other mc-Things? Check out our product page: www.mcthings.com/products. mc-Development kits are available too!
Check out a live Dashboard using mcThings and Losant! Click here: https://goo.gl/ST43hB

Cochrane

  • Newbie
  • *
  • Posts: 10
    • View Profile
Re: mc-Studio not connecting to my devices
« Reply #13 on: March 07, 2017, 10:30:00 pm »
Thanks again for the replies and assistance.

I seem to have it working now. I think there is an issue when the PC is connected to WIFI and the gateway connected to Ethernet.
I hardwired the PC into the network1 and then WPS connected the gateway and badda-bing-badda boom.

I could tell that something was different too, as soon as I opened mcStudio, the Windows Firewall blocker came up, and I allowed, and everything seems good so far.

Thanks very much for your time!
Like Like x 1 View List

mc-T2

  • Administrator
  • Sr. Member
  • *****
  • Posts: 252
  • mc-Things! The opportunities are endless!
  • Location: Canada
    • View Profile
Re: mc-Studio not connecting to my devices
« Reply #14 on: March 08, 2017, 01:51:26 pm »
Hey Cochrane,
Glad you a have everything working now!
We are looking forward to checking out the cool projects you are going to put together!
Remember to check us out on Hackster.io (feel free to sign up and join our hub as a member so we can gain some more exposure on the website!)

Thanks!
Need more mc-Modules, mc-Gateways or other mc-Things? Check out our product page: www.mcthings.com/products. mc-Development kits are available too!
Check out a live Dashboard using mcThings and Losant! Click here: https://goo.gl/ST43hB