Using multiple Chromecast to display same content for unattended TV - chromecast

We have a number of TVs where we want to display dynamic content. This is very similar to the built in Chromecast application that displays photos and art from Google, the major difference is that we have a mixture of photos and videos, and want to display for instance a whole video clip, then a few photos for 30 sec. each, then another video, then more photos, and finally when all is done, cycle through the whole thing again. We want to do the setup once for each Chromecast/TV, then let it run for days or even weeks.
One option could be a web server displaying the whole sequence repetitively on a specific web page url, and then have the Chromecast display its assigned web page. I looked at the development docs. and I suspect that I will need to develop a Chrome Sender application and use the standard receiver application on the Chromecast. It is not clear for me if the sender (Chrome) needs to run all the time, or once the setup is done, the Chromecast knows which url to display and can then be left alone for days.
We hope to replace dedicated servers and software that connect to the various TVs, and the Chromecast offering customization could be a very inexpensive solution.
Maybe this does not make sense, let me know!

The sender can be a chrome sender or a native app on an Android or iOS device; as for the receiver, you would need to write a custom receiver; that receiver, which is basically an HTML5 page, can receive the whole schedule (urls, etc) at the very beginning, or it can fetch the schedule dynamically from a certain server, etc. Once the receiver starts, your sender doesn't need to stay connected but if for whatever reason your chromecast is rebooted, or loses connectivity, etc, your sender would need to start your application on the chromecast again; there is no magical way for chromecast to start your app automatically.

Related

Is it possible for a 3rd party app to video call a teams user?

I would like a Teams user to video call an other Teams user using external hardware (usb camera) and using mobile devices (android first).
What can Teams apps do?
...
Collaborate on items in external systems. One of the core scenarios
for a custom Teams app is to bring information or items into Teams
from some other place, and have a conversation around it. You can push
information into Teams, enable your users to search for and pull it on
demand, or make it available in an embedded web view.
Source
I guess I could develop a small web application and a server which could act as a bridge.
Android app streams a video to my webserver, teams web app loads video stream from my server. Could that work?
I've found some other people asking similar things, and they did not get an answer.
https://techcommunity.microsoft.com/t5/Microsoft-Teams/SDK-for-Microsoft-Teams/m-p/261008
The easiest would be, if teams had a real sdk, but it seems to me, that it only has support for very limited "plugins".
Currently This is not supported in Teams.

Broadcast events in Firefox OS

I am wondering if there is a way for a Firefox OS app to broadcast an event to all other apps and for the interested apps to hook on that event and trigger a corresponding action.
An example of use case I have in mind: the Camera app broadcasts the event "picture taken" and another app hooks on this event and take some action on the new picture that has been taken (for example, uploads it to a server).
There's not currently a web API in Firefox OS to broadcast events to all open and/or interested apps.
For your particular use-case of apps being notified when a new photo is taken by Camera, the best approach is probably to open DeviceStorage for "pictures" and listen to "change" events.
Documentation for this is at:
https://developer.mozilla.org/en-US/docs/Web/API/DeviceStorage
Alternatives exist but are more restricted functionally, and available in fewer releases and contexts:
The system can broadcast messages, but only certified apps can listen. https://developer.mozilla.org/en-US/docs/Web/API/Navigator.mozSetMessageHandler
The InterAppCommunication API allows web applications to message one or more other apps, but in a more tightly coupled way than a general broadcast. However this API is not yet standardized, and is only available to certified apps. https://bugzilla.mozilla.org/show_bug.cgi?id=876397
Access to system preferences is coming soon for non-certified apps, and maybe could be used to do this, but that's a hacky way of accomplishing messaging and data sharing. https://developer.mozilla.org/en-US/docs/Web/API/SettingsManager
Note: For every example here, your app would have to be running for it to work. There's no mechanism for waking an app up when a specific action or event occurs. Web Activities is the closest API for event-specific app loading. Timers API is for non-specific app loading.
From this article[1]:
App authors can build an app that will handle one or more activities. That means that the app will be callable by another app to perform some specific actions defined by the activity. For example, let's pretend we want to build a photo manager. It could be used by another application to pick a photo. As an activity handler our app will become part of the other application's workflow.
[1] https://developer.mozilla.org/en-US/docs/Web/API/Web_Activities

Can my chromecast SENDER application launch any activity on the receiver?

specifically when using cast_api.addReceiverListener("YouTube"..... can I launch any activty besides youtube?
I don't want to write my own receiver application, what are the builtin receiver applications I can activate?
Is there a built in application to launch an arbitrary URL?
You cannot launch any application that you want. Currently, your device needs to be whitelisted for an application and outside of your own app that you may have registered through the whitelisting process, there are very few apps that are "openly" available to you, such as YouTube.
At the moment, if you want to do anything "interesting", even playing back a simple media file, you need to write your own receiver.
Finally, there is no application to launch an arbitrary URL; you need to write your own receiver and app to achieve that (unless you mirror your Chromecast tab).

broadcasting data to mobile devices

I working on a project were mobile users can receive alerts based on diferent factors, the server side will be implemented using the MVC framework.
My question is regarding the client side; what would be the most efficient way to send the alerts to the clients? is there any way to broadcast the alerts to each device or do I have to set up some system where each device pulls the data from the server on an interval of mins/seconds? I am afraid pulling the data every X secs/mins would create an unnesesary overhead on the mobile devices.
One way would be using SMS but SMS gateway services are expensive and not on my budget right now.
I haven't personally tried it, but this service might work for you:
http://www.airgramapp.com/api
It is free for limited use. Downside is it appears to be a separate install on the mobile device. This might means less control of the content of the message or its look. Upside is it looks quick and easy if you just need a proof of concept at this point.

Windows Phone 7 - how to send files from/to the app?

I'm trying to write the most basic application for windows phone 7 and want to be able to send files (specifically XML in case that changes anything) to my app. Currently I have a WCF service setup so I can send push notifications through it. The problem is that there is a limit on the amount of raw data I can send via a push notification.
My solution to this is to send the initial push notification (either tile or raw) to alert my application that I want to send a file to it and then make the app somehow communicate with a server (everything is on my personal computer btw - I'm just trying to figure out how things work) - from which the app will recieve/download the files.
What is the easiest way to accomplish this? Note that I'm not concerned with security or anything like that.
Clarification - the question is essentialy: how do I transfer files from/to a server to/from the phone? Assume everything else was handled - the app is up and running and the user has given or will give permissions to every possible thing he may give his permission to.
Unfortunately, the total size of a push notification (including HTTP headers) is 1kb. This means that it can't be used to send large amounts of data.
Instead of sending the whole file, send a notification (raw or toast—as appropriate) which should be treated by the application as a trigger to go and retrieve the new file/data/whatever from the server. It may also be worth checking for new messages when your app starts. However, if when you start the app it will notify the server that it is ready to receive raw notifications and such messages will be sent indicating new content is available, it may be unnecessary to add this extra check.
To transfer files to/from the phone you will need to use either HttpWebRequest or WebClient as this is the only way to use HTTP on the device and HTTP is the only protocol currently available to transfer data.
While WebClient may appear to be easier to use than HttpWebRequest it is less flexible and will automatically perform it's callback on the UI thread and if you're downloading files in the background you almost certainly don't want this.
There is no way to transfer files to/from a conencted PC and have them exclusively available to your app.
First of all: you won't be able to do this approach automatically - the user will have to open your app to do that because WP7 SDK doesn't allow your app to run on background/start automatically once a push notification is received.
The only way to communicate with your server, at this point in time, is web services. If I were you, I would check for new information available once the app is started, if there is new info, I would call one or more web services which would return me all the information that I need.
If you want, you can use a timer to check for information periodically.
As I said, it will only work while your app is running (check the app lifecycle if you don't know it yet), WP7 doesn't allow apps to run in background, that is a serious limitation IMHO.
Good Luck,
Oscar
Maybe a little bit off topic but when I was thinking about file sharing in my WP7 app, I found two approaches:
Integrate an app with Dropbox
Use advanced explorer for WP7
You can use the WebClient class and the DownloadStringAsync method in order to download data from a web service .
A good example of this is Scott Guthrie's Twitter app from MIX10 .
George

Resources