Raspi cannot connect to cayenne


#1

What dashboard are you using? (Web, iOS, Android)
I am using the web dashboard.


What OS? (Jessie, Wheezy)
Wheezy


What Model Pi?
Raspberry Pi Model B (Rev 2.0, 512Mb)


Please describe the bug / issue. Attaching any relevant screenshots would be very helpful!

I can install just fine, but the pi never connects to the dashboard.

I see this error in /var/log/myDevices.log:

2016-06-14 16:10:21 - myDevices - ERROR - TestDownload Failed
Traceback (most recent call last):
  File "/usr/local/lib/python3.2/dist-packages/myDevices-0.1.19517-py3.2.egg/myDevices/cloud/download_speed.py", line 47, in TestDownload
    request.urlretrieve(url, download_path)
  File "/usr/lib/python3.2/urllib/request.py", line 151, in urlretrieve
    return _urlopener.retrieve(url, filename, reporthook, data)
  File "/usr/lib/python3.2/urllib/request.py", line 1602, in retrieve
    block = fp.read(bs)
ValueError: read of closed file

#2

Can you run down through this post and report back? Troubleshooting Pi Showing Up as Offline in Dashboard


IOS vs WWW frontend [Helped: on corporate network]
#3

Yes,

I already ran through all of those items.

Interestingly, the iPhone app is working, but it shows as “offline” from work.

Are there any special ports that need to be opened on the browser side?


#4

I don’t have an iPhone to test with, but I would think you most likely have port 8181 blocked at the router. @bestes can confirm but since the iPhone and Android apps work locally they probably don’t need to go to the cloud server and they send/receive all data on the LAN.

Can you post the output from the post I linked?


#5

As @ats1080s mentioned, it may be issue with the network you are on at work. I’ve talked with Cayenne team and that error should not affect ability to connect to Cayenne dashboard.

Can you update us after trying on your home network? Posting the output would also be helpful.

-B


#6

It’s clearly something at my work.

I can connect just fine from home.

This brings up more questions about how the dashboard works.

I assume that the raspi reaches out to cayenne/mydevices servers and reports it’s stats periodically over port 8181, and then my browser connects to cayenne/mydevices web server to read the values over port 443.
I would assume that there’s some AJAX call to do that, and uses some HTML5 object to show the gauge.

What I don’t understand is what would be getting blocked at work.
Does it use a different port than 80 or 443 to connect to cayenne.mydevices.com, or does it use some other hostname to pull that data?

I guess another thing to check would be IPS, so see if something is being caught there. I’ll double-check those logs tomorrow.


#7

Hi @baldwintm_iot,

I’m going to move this topic to Helped category :slight_smile: Hope you don’t mind.

So your assumptions are correct. We use 443 to cayenne.mydevices.com, but we open websockets at 5001/2, so that might be where it’s blocking at your work.

Hope this helps :slight_smile:
-B


#8

@bestes,
That was the answer that I needed!

Thanks for having the right information at the right time!


#9

My pleasure!

-B