SageTV Community  

Go Back   SageTV Community > SageTV Development and Customizations > SageTV Clients Development

Notices

SageTV Clients Development This forum is for discussions relating to SageTV Open Source Clients Development.

Reply
 
Thread Tools Search this Thread Display Modes
  #101  
Old 09-19-2015, 09:17 AM
oddjob's Avatar
oddjob oddjob is offline
Sage Advanced User
 
Join Date: Aug 2004
Location: Chicago, IL
Posts: 184
sometimes, you just need to take a break.
Reply With Quote
  #102  
Old 09-19-2015, 09:24 AM
samgreco samgreco is offline
Sage Expert
 
Join Date: Jul 2004
Location: Villa Park, IL (Outside Chicago)
Posts: 611
Sounds like a job for someone on the inside. Gees, who do we know?....
Reply With Quote
  #103  
Old 09-19-2015, 09:46 AM
jm9843 jm9843 is offline
Sage Aficionado
 
Join Date: Oct 2003
Posts: 286
Quote:
Originally Posted by stuckless View Post
I'll start by saying that this is a RANT[]
Spot on. Google did some stupid things with the ADT-1. Not that it can recover your lost time but the only explanation for that ridiculous developer cable is that the ADT-1 was probably originally meant for consumer release but they pivoted and re-purposed it as a developer giveaway. And now, they've abandoned it for the Nexus Player as the de facto Android TV developer device.

That said, I hope you don't give up Sean. You do too much cool shit and are a big reason for the excitement around here.
Reply With Quote
  #104  
Old 09-19-2015, 09:46 AM
Fonceur's Avatar
Fonceur Fonceur is offline
Sage Icon
 
Join Date: Jan 2008
Location: DDO, QC
Posts: 1,915
Assuming that you find the special USB cable, on rooted Android device you only need to authorize with the cable the first time, then the adb wifi will work after... Then again, that requires some apps on the rooted device like su/adbConnect, so might not be how the native way would work on AndroidTV.
__________________
SageTCPServer (2.3.5): Open source TCP interface to the SageTV API
MLSageTV (3.1.8)/Sage Media Server (1.13): SageTV plugin for MainLobby/CQC
TaSageTV (2.58)/TaSTVRemote (1.14): Monitor/control SageTV with an Android device
TbSageTV (1.02)/STVRemote (1.11): Monitor/control SageTV with a PlayBook 2
TiSageTV (1.64)/TiSTVRemote (1.09): Monitor/control SageTV with an iPhone/iPod/iPad
Reply With Quote
  #105  
Old 09-19-2015, 10:13 AM
jm9843 jm9843 is offline
Sage Aficionado
 
Join Date: Oct 2003
Posts: 286
autostart wireless adb

I haven't verified it myself, but it's said that the following will autostart adb over WiFi (requires SU):

Code:
add the line
service.adb.tcp.port=5555
to build.prop
Reply With Quote
  #106  
Old 09-19-2015, 11:03 AM
samgreco samgreco is offline
Sage Expert
 
Join Date: Jul 2004
Location: Villa Park, IL (Outside Chicago)
Posts: 611
Quote:
Originally Posted by jm9843 View Post
That said, I hope you don't give up Sean. You do too much cool shit and are a big reason for the excitement around here.
Amen to that.
Reply With Quote
  #107  
Old 09-19-2015, 11:32 AM
MattHelm MattHelm is offline
Sage Icon
 
Join Date: Jun 2005
Location: Chicago, IL
Posts: 1,180
Quote:
Originally Posted by samgreco View Post
Quote:
Originally Posted by jm9843 View Post
That said, I hope you don't give up Sean. You do too much cool shit and are a big reason for the excitement around here.
Amen to that.
Ditto. I'm was very much looking forward to this!!! Is there anything we can help with??????????

I'm fighting a few things with Android myself. Mainly their refusal to get the SD card working correctly and GPS stuff. I've had to root every phone I've owned, and as a Verizon subscriber, that's getting harder and harder!
__________________
Server #1= AMD A10-5800, 8G RAM, F2A85-M PRO, 12TB, HDHomerun Prime, HDHR, Colossus (Playback - HD-200)
Server #2= AMD X2 3800+, 2G RAM, M2NPV-VM, 2TB, 3x HDHR OTA (Playback - HD-200)
Reply With Quote
  #108  
Old 09-19-2015, 04:06 PM
Gustovier Gustovier is offline
Sage Aficionado
 
Join Date: Nov 2010
Location: Chicago
Posts: 460
Sean,

I have an adt 1 around here that I believe is still on an older version that I rarely use. Let me know if this can be of use to you and I can get it over. PM me if needed
Reply With Quote
  #109  
Old 09-20-2015, 03:23 PM
stuckless's Avatar
stuckless stuckless is offline
SageTVaholic
 
Join Date: Oct 2007
Location: London, Ontario, Canada
Posts: 9,541
Red face Really Alpha MiniClient build

So.. Ranting is done... I managed to spend a few hours looking through boxes of old cables, and I did find the ADT1 usb cable, so I could set it into WiFi debugging mode, and push the App.

My initial plan was to use LibGDX (which I've used in the past for other projects), but I ran into rendering glitches. It was fast, but the rendering looked like crap. So, I ditched LibGDX

To show "something", I ended up using the Android Canvas, which is hardware accelerated and uses opengl under the hood, but sadly, performance is not good, but the rendering is very good. It would appear that I'll need to learn OpenGL (specifically OpenGL ES -- which is VERY different than the version of opengl that SageTV currently uses) in order to build a client that can render smoothly. (Particularly, the rendering is slow because each frame has to be scaled up to screen size)

But, in the mean time, if people would like to see what a MiniClient on their phone/tablet/tv might look like, here is an Alpha build. (you'll have to side load it)



If you are on an Android TV, then the DPAD UP/DOWN/LEFT/RIGHT should work, and A is Enter, and B is escape.

If you are on a Phone tablet, swiping up/down/left/right is like using keyboard up/down/left/right. Single tap will focus an item. Double tap will be like SELECT/ENTER.

Enjoy... and I can't promise I wont have another Google meltdown... because between fragments, sd cards (4x), permissions, img urls, and now the botched ADT... Another meltdown is almost a given

Last edited by stuckless; 09-20-2015 at 03:26 PM.
Reply With Quote
  #110  
Old 09-20-2015, 03:53 PM
nyplayer nyplayer is offline
SageTVaholic
 
Join Date: Sep 2005
Posts: 4,055
Quote:
Originally Posted by stuckless View Post
So.. Ranting is done... I managed to spend a few hours looking through boxes of old cables, and I did find the ADT1 usb cable, so I could set it into WiFi debugging mode, and push the App.

My initial plan was to use LibGDX (which I've used in the past for other projects), but I ran into rendering glitches. It was fast, but the rendering looked like crap. So, I ditched LibGDX

To show "something", I ended up using the Android Canvas, which is hardware accelerated and uses opengl under the hood, but sadly, performance is not good, but the rendering is very good. It would appear that I'll need to learn OpenGL (specifically OpenGL ES -- which is VERY different than the version of opengl that SageTV currently uses) in order to build a client that can render smoothly. (Particularly, the rendering is slow because each frame has to be scaled up to screen size)

But, in the mean time, if people would like to see what a MiniClient on their phone/tablet/tv might look like, here is an Alpha build. (you'll have to side load it)



If you are on an Android TV, then the DPAD UP/DOWN/LEFT/RIGHT should work, and A is Enter, and B is escape.

If you are on a Phone tablet, swiping up/down/left/right is like using keyboard up/down/left/right. Single tap will focus an item. Double tap will be like SELECT/ENTER.

Enjoy... and I can't promise I wont have another Google meltdown... because between fragments, sd cards (4x), permissions, img urls, and now the botched ADT... Another meltdown is almost a given

I loaded on the Nexus Player while watching this boring Eagles Cowboys game ... The rendering of the ui is very good ...sluggish like you stated... I can see my recordings and guide. The mouse works on it I was able to schedule a recording through the guide ... overall it is a great start.


PS Of course I tried to play a recording....

Last edited by nyplayer; 09-20-2015 at 03:55 PM.
Reply With Quote
  #111  
Old 09-20-2015, 04:28 PM
stuckless's Avatar
stuckless stuckless is offline
SageTVaholic
 
Join Date: Oct 2007
Location: London, Ontario, Canada
Posts: 9,541
Quote:
Originally Posted by nyplayer View Post
PS Of course I tried to play a recording....
I don't even know what that would do... I suspect it either crashed it or locked it since I've gutted all video related stuff for now, just to focus on the UI.
Reply With Quote
  #112  
Old 09-20-2015, 04:29 PM
nyplayer nyplayer is offline
SageTVaholic
 
Join Date: Sep 2005
Posts: 4,055
Quote:
Originally Posted by stuckless View Post
I don't even know what that would do... I suspect it either crashed it or locked it since I've gutted all video related stuff for now, just to focus on the UI.
Unable to render. Video I believe.

Ps I am sure you know that the Nexus Player round middle button did not select instead I used a mouse and double clicked.
Reply With Quote
  #113  
Old 09-20-2015, 07:51 PM
dinki's Avatar
dinki dinki is offline
Sage Expert
 
Join Date: Mar 2006
Posts: 643
UI preview worked great on Amazon Fire TV stick. Could not install on my Moto G phone but it may have been a bad download. I'll give it another try tomorrow. It's good to see that familiar interface on a modern device even if it isn't all that functional. Bravo on your efforts sir!
__________________
Intel Q6600 Quad 2.4GHZ, 8GB RAM, Win7 Pro SP1 64bit, 1 TB of Data
SageTV 9, Silicondust HDHomeRun x2 OTA
HD200
Reply With Quote
  #114  
Old 09-20-2015, 08:59 PM
Fuzzy's Avatar
Fuzzy Fuzzy is offline
SageTVaholic
 
Join Date: Sep 2005
Location: Jurupa Valley, CA
Posts: 9,957
The rendering looks great on my older Droid phone. What resolution is your current build generating the UI at? It honestly is not all that slow on my 1280x720 screen. There are of course navigation issues dealing with the small device - but just the simple directional swipes and double click seem to work great. Gemstone is quite unusable I've found without access to the options command, as it removes the 'Options' button from the lower taskbar.

Summary: Rendering is perfect, and somewhat sluggish - but I've used sagetv with much slower rendering over a proper placeshifter connection. If this had the ability to enter in a manual server address, I'd love to test this over a remote connection, which would make it instantly useful to me for remote recording management.
__________________
Buy Fuzzy a beer! (Fuzzy likes beer)

unRAID Server: i7-6700, 32GB RAM, Dual 128GB SSD cache and 13TB pool, with SageTVv9, openDCT, Logitech Media Server and Plex Media Server each in Dockers.
Sources: HRHR Prime with Charter CableCard. HDHR-US for OTA.
Primary Client: HD-300 through XBoxOne in Living Room, Samsung HLT-6189S
Other Clients: Mi Box in Master Bedroom, HD-200 in kids room
Reply With Quote
  #115  
Old 09-20-2015, 11:42 PM
tvmaster2's Avatar
tvmaster2 tvmaster2 is offline
SageTVaholic
 
Join Date: Jun 2005
Location: tarana
Posts: 3,364
Quote:
Originally Posted by nyplayer View Post
I loaded on the Nexus Player while watching this boring Eagles Cowboys game ... The rendering of the ui is very good ...sluggish like you stated... I can see my recordings and guide. The mouse works on it I was able to schedule a recording through the guide ... overall it is a great start.


PS Of course I tried to play a recording....
this mini-player is only for use with Sage v.9, and not Sage v.7, correct?
__________________
Sage 7 server = Gigabyte AMD quad-core - 2 gigs - integrated ATI HD4200 chipset - Seagate/Hitachi Deskstar - HD-PVR - Colossus - Win7 32 bit. HD200 networked. "If you've given up on Weird Al, you've given up on life" - Homer Simpson
Reply With Quote
  #116  
Old 09-21-2015, 05:40 AM
stuckless's Avatar
stuckless stuckless is offline
SageTVaholic
 
Join Date: Oct 2007
Location: London, Ontario, Canada
Posts: 9,541
Quote:
Originally Posted by nyplayer View Post
Ps I am sure you know that the Nexus Player round middle button did not select instead I used a mouse and double clicked.
I don't have a remote for my Nexus Player, only a game controller, so no I didn't know that... but I'm not surprised. I need to manually map controller/remote buttons to sagetv key codes and I'll need to do some research to find out what button the middle round button is.

Quote:
Originally Posted by dinki View Post
UI preview worked great on Amazon Fire TV stick. Could not install on my Moto G phone but it may have been a bad download. I'll give it another try tomorrow.
I think the min requirements are Android 4.4 + a phone that supports opengles 2.

Quote:
Originally Posted by Fuzzy View Post
The rendering looks great on my older Droid phone. What resolution is your current build generating the UI at? It honestly is not all that slow on my 1280x720 screen.
I'm rendering at 720x480 but even the upscaling on my phone (1920x1080) is quite good.

Quote:
Originally Posted by Fuzzy View Post
There are of course navigation issues dealing with the small device - but just the simple directional swipes and double click seem to work great. Gemstone is quite unusable I've found without access to the options command, as it removes the 'Options' button from the lower taskbar.
When you say it removed the options button, do you mean the Android UI options button, or in the gemstone UI there is an options button? What sort of gesture (or multi-touch function) could we use to send the sagetv options command?

Quote:
Originally Posted by Fuzzy View Post
If this had the ability to enter in a manual server address, I'd love to test this over a remote connection, which would make it instantly useful to me for remote recording management.
Up until yesterday, this was hardcoded to go to my server, so that first server selection page was just thrown in at the last minute to make it usuable for others I'll try to add a simple "Add Server" option in the next build.

Quote:
Originally Posted by tvmaster2 View Post
this mini-player is only for use with Sage v.9, and not Sage v.7, correct?
I think this can be used to connect to a V7 SageTV as well... (My server is running V9 so I can't say for sure)
Reply With Quote
  #117  
Old 09-21-2015, 05:53 AM
Fuzzy's Avatar
Fuzzy Fuzzy is offline
SageTVaholic
 
Join Date: Sep 2005
Location: Jurupa Valley, CA
Posts: 9,957
Quote:
Originally Posted by stuckless View Post
When you say it removed the options button, do you mean the Android UI options button, or in the gemstone UI there is an options button? What sort of gesture (or multi-touch function) could we use to send the sagetv options command?
On the stock STV, there is an 'Options' word at the bottom of the screen that brings up the options menu for that screen (see bottom right of here). This would be useful on a touch-only device that doesn't otherwise HAVE an options 'button'. Gemstone does not have this button, so there is no way currently in Gemstone with a touch only interface to bring up the Optinos menu to actually configure Gemstone. Really, it's something that needs to be fixed in Gemstone, not your app - though a potential good feature might be a 'special' keyboard type panel that could contain special sagetv function buttons.
__________________
Buy Fuzzy a beer! (Fuzzy likes beer)

unRAID Server: i7-6700, 32GB RAM, Dual 128GB SSD cache and 13TB pool, with SageTVv9, openDCT, Logitech Media Server and Plex Media Server each in Dockers.
Sources: HRHR Prime with Charter CableCard. HDHR-US for OTA.
Primary Client: HD-300 through XBoxOne in Living Room, Samsung HLT-6189S
Other Clients: Mi Box in Master Bedroom, HD-200 in kids room
Reply With Quote
  #118  
Old 09-21-2015, 06:32 AM
stuckless's Avatar
stuckless stuckless is offline
SageTVaholic
 
Join Date: Oct 2007
Location: London, Ontario, Canada
Posts: 9,541
Quote:
Originally Posted by Fuzzy View Post
On the stock STV, there is an 'Options' word at the bottom of the screen that brings up the options menu for that screen (see bottom right of here). This would be useful on a touch-only device that doesn't otherwise HAVE an options 'button'. Gemstone does not have this button, so there is no way currently in Gemstone with a touch only interface to bring up the Optinos menu to actually configure Gemstone. Really, it's something that needs to be fixed in Gemstone, not your app - though a potential good feature might be a 'special' keyboard type panel that could contain special sagetv function buttons.
I often refer to this post for keyboard shortcuts, since Phoenix also doesn't have an "options" button, and I have to use ctrl+o to bring up the options menu. I think mapping a 3 finger gesture (like swipe down with 3 fingers) to send "ctrl+o", might work.
Reply With Quote
  #119  
Old 09-21-2015, 06:47 AM
dinki's Avatar
dinki dinki is offline
Sage Expert
 
Join Date: Mar 2006
Posts: 643
Quote:
Originally Posted by stuckless View Post
I think the min requirements are Android 4.4 + a phone that supports opengles 2.
I'm on 4.4.4 so I guess this opengl es 2 is the problem. This is a phone dependent thing?

Quote:
I think this can be used to connect to a V7 SageTV as well... (My server is running V9 so I can't say for sure)
I connected to my v7 without problem
__________________
Intel Q6600 Quad 2.4GHZ, 8GB RAM, Win7 Pro SP1 64bit, 1 TB of Data
SageTV 9, Silicondust HDHomeRun x2 OTA
HD200
Reply With Quote
  #120  
Old 09-21-2015, 06:47 AM
stuckless's Avatar
stuckless stuckless is offline
SageTVaholic
 
Join Date: Oct 2007
Location: London, Ontario, Canada
Posts: 9,541
The android Canvas, much like the Java2d canvas is pretty snappy for drawing, but when you start to scale it, it gets laggy. Currently each rendered frame takes anywhere between 100-200ms to render, which is far too long, especially when you consider that sagetv typically has an animation duration of 200-300ms. So, if an animation in sagetv creates 5 frames and each of those frames takes 200ms each to render, then our 250ms animation just took a full second to render, and that's the sluggishness you are seeing in the UI today.

So my next challenge for this is to try and create a pure opengl ES2 renderer. My problem is that I haven't looked at opengl in years (probably since college)... and ES2 uses shader functions, and vertex buffer objects, and I've never looked at either of these. So combining my lack of knowledge in opengl with the fact that the opengl code that sagetv is using currently has no direct mapping to opengl ES... this next step is going to be slow But moving to opengl is the only way we are going to get buttery smooth transition, like we have on the HD300.

If anyone that has experience with VBOs and Android OpenGL ES and they want to help or work with me, then it would be appreciated. To be honest, to get this working in opengl based on where the code is now, is minimal effort for anyone that understands opengl. I've written the load bitmap into a texture function (Android provided a nice utility for that), but I have no idea how I'm supposed to map a loaded texture to a region of the screen using VBOs.

Android has a GLSurfaceView that manages the offscreen buffering from what I can tell, so getting this work, should be fairly straight forward. In the mean time, I'll be reading article after article on opengl, vbos, and android opengl es
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Finally, a fully functional SageTV client on android and iphone! mkanet SageTV v7 Customizations 12 01-12-2013 12:22 AM
SageTV Placeshifter for Android nyle SageTV Placeshifter 5 12-31-2011 10:40 AM
Sage should get an android client running on this Deacon Crusher Hardware Support 1 09-29-2010 11:30 AM
Android client? equalize SageTV Placeshifter 1 07-22-2010 09:37 AM


All times are GMT -6. The time now is 12:54 AM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2019, vBulletin Solutions, Inc.
Copyright 2003-2005 SageTV, LLC. All rights reserved.