Page 1 of 2
Screen Mirroring
Posted: Thu Dec 10, 2020 1:55 pm
by trevix
I have a LC App, for iPHone and Android, that needs to screen mirror its content to a TV. Smart or not.
Google ChomeCast and EZcast 2, HDMI devices that allow this using wifi, require an external app for the mirroring.
After reading tons of pages on the argument, I found that there are many incompatible standards but not a universal solution for both platforms.
Even doing it with cable is a mess.
Is there any way that I can enable my LC App for some direct screen mirroring of any sort?
I did not find any reference on this on the forum.
Re: Screen Mirroring
Posted: Sat Dec 12, 2020 9:19 am
by richmond62
I don't think LiveCode can send signals to the operating system of
whichever platform it is operating on to change the setting of that operating system.
Having said that (and feeling slightly foolish) you might like to look at
shell commands.
https://livecode.fandom.com/wiki/Shell
"The commandLine must be a valid shell command on the current operating system."
https://awesomeopensource.com/project/a ... /replaykit
Re: Screen Mirroring
Posted: Sat Dec 12, 2020 12:53 pm
by trevix
Well...is all well above my knowledge.
Just for the sake of it, I think that Screen Mirroring of mobile device to TVSets is going to be a big thing.
It's a tough subject, given the standard war that is going on (MiraCast, MHL, SLIMPORT, DNLA, AIRPLAY).
Even using wire, it is complicated by the number of different USB connectors that this damn hardware manufacturer are pulling out year after year.
Re: Screen Mirroring
Posted: Sat Dec 12, 2020 12:59 pm
by richmond62
Well...is all well above my knowledge.
Ha, Ha: unfortunately both You and I belong to an extremely unexclusive club.

Re: Screen Mirroring
Posted: Sat Dec 12, 2020 1:20 pm
by trevix
I wonder if you can come up with some ideas for solving this problem on my App (iOS and Android).
It's an App used to do Tennis, Padel and Ping Pong scoring.
Before starting the match, you launch the app (it's called "Segnapunto") in your mobile phone and, using small hardware bluetooth button, you advance the score (that is also declared by a loud voice).
The idea of mirroring to a TV set, is to enable a Tennis club to have a big score board where players can see the score and listen to it by the speaker of the TV (much louder then a phone. We now use a bluetooth speaker).
1) Most of the TV, nowadays, are smart, in the sense that they can display a browser: could it be possible from LC, to compose a web page of its screen that gets transmitted in real time using a local networked to the TV browser?
2) What about instead if, attached to the HDMI of the TV, there is a fixed device (mobile,Windows, else) set by the Club.
Could it be possible to have two LC Apps, one on the personal phone of the player and one fixed on the TV set, to synchronise their display content trough local network. I could just send small commands from one App to the other, one being a client nd one being a server. Is it faseable?
Thanks for any suggestion
Re: Screen Mirroring
Posted: Sat Dec 12, 2020 1:53 pm
by richmond62
Well, if it's any help at all, I'd like to suggest a totally simple and goofy alternative:
I have a laptop (running Xubuntu something-or-other) that has an HDMI-out socket.
My wife and I tend to use it to watch films streamed over the internet by connecting it via
an HDMI cable to a widescreen TV.
So, why not make a 'normal' (i.e. for desktop) standalone for Windows/Linux/Macintosh,
run it on a laptop mirroring via a cable to a widescreen telly?
Re: Screen Mirroring
Posted: Sat Dec 12, 2020 2:40 pm
by trevix
We earn money with the downloads our App and sell of our buttons.
Also, using thier device,they carry their score stats, unfinished match, etc.
Beside Players need to start the game, correct the score, navigate preferences. A computers needs a mouse.All- in-one desktop touch ould be too expensive and non appropriate for outdoor use (even TV but easier to solve).
Re: Screen Mirroring
Posted: Sat Dec 12, 2020 3:00 pm
by richmond62
We earn money with the
Aha.
A lot better than I have ever done: this year my Devawriter has brought me $50.

Re: Screen Mirroring
Posted: Sat Dec 12, 2020 6:39 pm
by jacque
Android has screen mirroring built in for Chromecast. The easiest way would be to use that from an Android phone (I'm not sure how iOS does it.) But it does require wifi, do you have access to wifi during a game?
Re: Screen Mirroring
Posted: Sat Dec 12, 2020 7:08 pm
by trevix
Yes. I have ChomeCast and it works fine from Android ( given that you downloaded Google Home and there is a Internet Wifi).
The bad thing is that it does not work with direct Wifi. So you need an internet connection. Most of the playing courts, for my experience, don't have Wifi.
I am waiting for EZCast, another mirror dongle that, hopefully can do Wifi direct.
On iOS ChomeCast works if you download a specific Mirror App (like "Replica" $$). Cumbersome for a player that want to go there, connect and play: My App, Google Home, Replica.
In teory, google has an SDK for ChromeCast,but probably is very hard, if impossible, to implement it in LC
Re: Screen Mirroring
Posted: Sun Dec 13, 2020 11:38 am
by simon.schvartzman
Just an idea: what if together with the button you include a Rapsberry Pi that interacts with your App through Bluetooth?
That should be a turnkey solution and there is no need for a SmartTV and/or Wifi.
Hope it makes sense,
Best
Re: Screen Mirroring
Posted: Sun Dec 13, 2020 3:35 pm
by trevix
But can now LC compile and install an App on the Rasperry? I thought it was still pending...
Re: Screen Mirroring
Posted: Sun Dec 13, 2020 6:11 pm
by jacque
I want to be sure I understand the goal. Right now a score is announced and users manually update the score in their copy of your app. Do you want to:
1. Show the score on a large TV screen. Users would still update their app manually, or
2. Show the score on the TV and have it also update every user copy of the app
I think you want #1 because you need wifi to update remote devices. Is that right?
Re: Screen Mirroring
Posted: Sun Dec 13, 2020 6:33 pm
by trevix
This:
1. Show the score on a large TV screen. Users would still update their app manually
(using the remote bluetooth controller)
The TV set is not mean to be interactive: it must only show the phone screen and play the sound it receives.
That is: "screen mirror".
But since"Screen Mirror" is so complex to set up for users, I was asking if there were other ways to do an similar thing.
The Raspberry is a great idea (if LC can install an App on it) because the only thing needed would be to setup a client/server connection and send command form the Phone App to the Raspberry App, using the local network:
A Bluetooth Button >
B PhoneApp (advance the score and, working as a client, send a command to > C Raspberry App (same as PhoneApp but works as a server): repeat the action and display image and sound on the TV set (using HDMI).
This way I could even sell the Rasberry as a mean for having a score board on Tennis Clubs $$.
I have see that there is a Rasberry section on the Forum, but from the last message it appears that there is not a LC for Raspberry yet and it may not ever exist.
Sure, I could run the thing on a windows computer but the difference in price is quite big.
Re: Screen Mirroring
Posted: Sun Dec 13, 2020 8:54 pm
by simon.schvartzman
Hi Trevix, your are right as far as I know there is no LC for Rapsberry but I guess (I've never developed anything for the RPi) it shouldn't be too difficult to achieve your goal. After all the only thing the RPi should be doing is reading the data through Bluetooth and displaying it.