PDA

View Full Version : nDroid v1.3.x (Beta) support thread



bgowland
2011-04-01, 05:11 AM
I've uploaded v1.3 of the nDroid client and nDroidService components to the nDroid wiki page (http://www.gbpvr.com/nwiki/pmwiki.php?n=Utility.NDroid)

I'll try and detail changes later when I can remember them but they include...


Installer for the nDroidService (please see post #2 for uninstalling previous version)
Primitive 'Now Showing' page (all shows, current time-slot) - NOTE, attempting to set recordings from this will fail.
Early start to 'Status' page - general info, currently limited to software versions and last download dates
Re-sizing of buttons on dialogs to make them easier to use (much more work needed for the UI elements)
Loads of low-level stuff I can't remember
Added a touch of colour :D

bgowland
2011-04-01, 05:12 AM
It's important to uninstall v1.1.x of nDroidService when upgrading to v1.3


Find the folder where nDroidService is installed
Run UninstallService.bat
Check 'Services' to make sure it has been uninstalled before proceeding with the v 1.3 install

After the above, the folder containing the v1.1 installation can be safely deleted.

Nistrod
2011-04-01, 09:08 AM
Ooooooh - pretty!
Looking good.

I wont pester you about my wishlist - patience, grasshopper!

bgowland
2011-04-01, 10:06 AM
Ooooooh - pretty!
Looking good. Just thought I'd throw it in there for a touch of colour. :)


I wont pester you about my wishlist - patience, grasshopper!Similar to the last update, I've been concentrating on stability and it's hopefully better.

I needed to get this release out so I could sit back for a moment to think about various wishes/comments. Just one more step and I'll be able to focus properly.

agerdin
2011-04-01, 06:57 PM
bgowland,

Installing the service with no problem but it will not start. I am getting the following error when trying to start it from a CMD window:


System error 193 has occurred.
*** is not a valid Win32 application.

And the following error when starting from services.msc:


Could not start the nDroid Service on local computer
Error 193: 0xc1

Any thoughts?

\\Agerdin

bgowland
2011-04-01, 08:29 PM
Can you zip and attach the log files. They're now located in a separate folder to the program files...

C:\Documents and Settings\All Users\Application Data\Beetec Services\nDroid Service\logs (for XP)
C:\Users\public\Beetec Services\nDroid Service\logs (for Vista and Windows 7)

agerdin
2011-04-01, 10:54 PM
logs attached as requested

\\Agerdin

bgowland
2011-04-01, 11:06 PM
Hmm, not sure. The service is starting but seems to drop out without logging an error. Are there any entries in your Windows Application log?

agerdin
2011-04-01, 11:18 PM
Hmm, not sure. The service is starting but seems to drop out without logging an error. Are there any entries in your Windows Application log?

Only thing logged is under Event Viewer\System where I get an error for everytime I am trying to start the service.


The nDroid Service service failed to start due to the following error:
nDroid Service is not a valid Win32 application.

For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp.

Which is the same as before.

\\Agerdin

\\Agerdin

bgowland
2011-04-01, 11:23 PM
Did you make sure that you uninstalled the previous version of the service (as described in post #2 of ths thread)?

Open a command prompt and try running...


sc qc "nDroid Service"

...then post what the result is.

agerdin
2011-04-01, 11:24 PM
I am also getting the following:

sc create "nDroid Service" start= auto binPath= %1"\nDroidService.exe"


[SC] CreateService FAILED 1073:
The specified service already exists.
sc query nDroid Service

SERVICE_NAME: nDroid Service
TYPE : 10 WIN32_OWN_PROCESS
STATE : 1 STOPPED
(NOT_STOPPABLE,NOT_PAUSABLE,IGNORES_SHUTDOWN)
WIN32_EXIT_CODE : 0 (0x0)
SERVICE_EXIT_CODE : 0 (0x0)
CHECKPOINT : 0x0
WAIT_HINT : 0x0
\\Agerdin

bgowland
2011-04-01, 11:28 PM
I think our posts overlapped - see my post http://forums.gbpvr.com/showthread.php?49717-nDroid-v1.3.x-(Beta)-support-thread&p=408418#post408418

agerdin
2011-04-01, 11:32 PM
Did you make sure that you uninstalled the previous version of the service (as described in post #2 of ths thread)?

Open a command prompt and try running...


sc qc "nDroid Service"

...then post what the result is.

Yes, I followed the uninstall instructions of the old service.

sc qc "nDroid Service"

[SC] GetServiceConfig SUCCESS

SERVICE_NAME: nDroid Service
TYPE : 10 WIN32_OWN_PROCESS
START_TYPE : 2 AUTO_START
ERROR_CONTROL : 1 NORMAL
BINARY_PATH_NAME : C:\Documents and Settings\All Users\Application Dat
a\NPVR\Tools\nDroid Service\nDroidService.exe
LOAD_ORDER_GROUP :
TAG : 0
DISPLAY_NAME : nDroid Service
DEPENDENCIES :
SERVICE_START_NAME : LocalSystem

bgowland
2011-04-01, 11:40 PM
[SC] GetServiceConfig SUCCESS

SERVICE_NAME: nDroid Service
TYPE : 10 WIN32_OWN_PROCESS
START_TYPE : 2 AUTO_START
ERROR_CONTROL : 1 NORMAL
BINARY_PATH_NAME : C:\Documents and Settings\All Users\Application Dat
a\NPVR\Tools\nDroid Service\nDroidService.exe
LOAD_ORDER_GROUP :
TAG : 0
DISPLAY_NAME : nDroid Service
DEPENDENCIES :
SERVICE_START_NAME : LocalSystem

Other than the path, that looks the same I see for my installation. :confused:

Let me check something...

bgowland
2011-04-01, 11:54 PM
OK, I'm a bit stuck on this. Could you try uninstalling (use Control Panel Add/Remove Programs) then run the installer again? There's a slight possibility something went wrong with the installation the first time.

If that doesn't work I'll have to attach a new version with some more logging in it.

mvallevand
2011-04-02, 12:21 AM
C:\Users\public\Beetec Services\nDroid Service\logs (for Vista and Windows 7)

I don't see this folder on Vista, and there are other Vista UAC issues,

First the config program gives this.



See the end of this message for details on invoking
just-in-time (JIT) debugging instead of this dialog box.

************** Exception Text **************
System.UnauthorizedAccessException: Access to the path 'C:\ProgramData\Beetec Services\nDroid Service\nDroidSettings.xml' is denied.
at uk.co.beetec.csharp.nDroid.XmlSettings.Save() in C:\Documents and Settings\gbpvr\My Documents\Visual Studio 2008\Projects\nDroidService\nDroidConfig\XmlSettin gs.cs:line 158
at uk.co.beetec.csharp.nDroid.SettingsForm.btnSave_Cl ick(Object sender, EventArgs e) in C:\Documents and Settings\gbpvr\My Documents\Visual Studio 2008\Projects\nDroidService\nDroidConfig\SettingsF orm.cs:line 29
at System.Windows.Forms.Control.OnClick(EventArgs e)
at System.Windows.Forms.Button.OnClick(EventArgs e)
at System.Windows.Forms.Button.OnMouseUp(MouseEventAr gs mevent)
at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ButtonBase.WndProc(Message& m)
at System.Windows.Forms.Button.WndProc(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.O nMessage(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.W ndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)



Also your two batch files in the Start Menu are not UAC aware so they won't control the services but they run so quickly you can't see the error.

Running any of these as administrator solves the issues.

Martin

bgowland
2011-04-02, 12:41 AM
I don't see this folder on Vista, and there are other Vista UAC issuesOK, I made some assumptions for Vista/W7 as I don't have either to test on.

I'll look at this closer. Thanks.

bgowland
2011-04-02, 01:40 AM
@Martin: Does everything else appear to work correctly, e.g., the service starts/runs OK and you're able to connect from your device?

I have a possible fix for the 'data' directory issue and I'll upload a test version ASAP but if there are other Vista issues I'd rather try to address them at the same time.

Cheers,
Brian

mvallevand
2011-04-02, 01:57 AM
I didn't actually try and connect since there was no data directory with zip files but the service started. For UAC reasons I think the XML file should be in the data directory if you are going to have one.

Martin

bgowland
2011-04-02, 02:06 AM
I didn't actually try and connect since there was no data directory with zip filesGood point. :)


For UAC reasons I think the XML file should be in the data directory if you are going to have one.That's what I was aiming for but misinterpreted the use of the installer's env variables. Can you confirm that C:\users\public\ allows all users read/write access on Vista without UAC problems? That was my assumption and where I was intending the data files to go.

mvallevand
2011-04-02, 02:24 AM
User\Public is okay although the NPVR XP and Win7/Vista data folders aren't really Windows standards.

Martin

bgowland
2011-04-02, 06:53 AM
I've uploaded a new version of the installer which should hopefully fix issues with Vista/Windows7 data installation folders.

If you've tried v1.3 and you're having problems on Vista/W7, use the installer you have to un-install before downloading/installing with the new installer. To do this go to Control Panel -> Add/Remove Programs -> Remove.

mvallevand
2011-04-02, 07:30 AM
Ok, this installed fine on the PC and on the tablet after a few minutes of populating and extracting I got the new UI, but I can't see any shows. I have emailed you the logs with lots of errors

Martin

bgowland
2011-04-02, 09:55 AM
Thanks - I've got an angle on this and managed to trap what is happening....but I don't know why. It seems to be confusing two channels, i.e., trying to display data for Ch. X when it should be showing Ch. Y - I'll look closer at this later.

bgowland
2011-04-02, 09:16 PM
I've updated the nDroid client to include better error checking when importing EPG data.

Little else has changed so if you're not seeing problems with v1.3.6 don't worry about installing this version.

mvallevand
2011-04-03, 04:17 PM
Brian, I still don't see data with the 1.3.7 client.

Martin

bgowland
2011-04-03, 07:13 PM
Brian, I still don't see data with the 1.3.7 client.Yes, I got your email - that SQL error you're seeing isn't one I saw when I tried with your EPG data. I was seeing other exceptions though which I fixed for 1.3.7 hoping it would fix your problem.

Could you email the full set of zip files please? Scheduled_recording.zjp, channel.zip and sevendayxml.zip and I'll try again.

mvallevand
2011-04-03, 07:16 PM
Zips sent.

Martin

bgowland
2011-04-03, 09:36 PM
Zips sent.

MartinOK, I've worked out what those SQL-related exceptions are and they're a side-effect of whatever is failing earlier.

Are you able to get the logcat output from the DB import stage or is the buffer overflowing?

What I'd need is see is if there are errors during the DB table creation and import. Are you able to get back that far in the logcat?

mvallevand
2011-04-03, 09:45 PM
Are you able to get the logcat output from the DB import stage or is the buffer overflowing?

What I'd need is see is if there are errors during the DB table creation and import. Are you able to get back that far in the logcat?

It overflows quickly when it starts up. I think I see some inserts briefly, but I've never been able to pause it earlier to see what happens at the beginning or when the inserts stop.

Martin

bgowland
2011-04-03, 10:00 PM
I'll put together a version which logs the DB import stuff to a text file on the SD card and post it ASAP. The zip files you sent me are working fine here so I'm not sure what's failing at your end.

pwrmac7100
2011-04-09, 01:37 AM
I am getting the same error as agerdin. I never had a previous version of nDroid, so there was nothing to uninstall. I ran you command and got the below result:

C:\Documents and Settings\Winston>sc qc "nDroid Service"
[SC] GetServiceConfig SUCCESS

SERVICE_NAME: nDroid Service
TYPE : 10 WIN32_OWN_PROCESS
START_TYPE : 2 AUTO_START
ERROR_CONTROL : 1 NORMAL
BINARY_PATH_NAME : C:\Program Files\Beetec Services\nDroid Service\nDr
oidService.exe
LOAD_ORDER_GROUP :
TAG : 0
DISPLAY_NAME : nDroid Service
DEPENDENCIES :
SERVICE_START_NAME : LocalSystem

bgowland
2011-04-09, 03:14 AM
I am getting the same error as agerdin.I might have an angle on this...

Check to see if you have a file/folder called Program on your C: drive. If you have and it isn't important then delete it then try starting the nDroid Service.

pwrmac7100
2011-04-11, 01:46 AM
Sorry for the delay. I did have a file called 'Program' on C:. I deleted the file and the service started. Care to offer an explanation?

bgowland
2011-04-11, 04:56 AM
Sorry for the delay. I did have a file called 'Program' on C:. I deleted the file and the service started. Care to offer an explanation?Good news on the service starting. :)

As for an explanation, if you're a teccy this sort of explains it...Weird but solved! (http://blog.brainlitter.com/archive/2008/10/28/error-193-0xc1-weird-but-solved.aspx)

Basically a bug/feature (call it what you like) which allows registering a service without quotes for the path. Example, your sc qc output...


BINARY_PATH_NAME : C:\Program Files\Beetec Services\nDroid Service\nDroidService.exe

No quotes but a space after the C:\Program part of the path. It appears this is allowable and doesn't cause problems unless there really is a file/folder called 'C:\Program' at which point Windows thinks that's the service and tries to start it. If it was installed to C:\Some Folder\ndroidService.exe it would be fine unless there was a file called 'C:\Some'.

Nice huh?...or not as the case may be, especially as I was using the native 'sc create' command to register it...way to go MS! Sigh!

I've just been working on a new version of the installer which uses my original service installer approach and puts quotes where they're needed. Hopefully it will prevent future problems.

Cheers,
Brian

pwrmac7100
2011-04-12, 01:04 AM
very interesting...and somewhat funny

bgowland
2011-04-12, 01:30 AM
very interesting...and somewhat funnyFunny in the bizarre sense of the word. :) The more I think about it, the more my mind boggles as to how they could let such partial functionality exist. Oh well.

fuzzweed
2011-06-16, 07:14 AM
Feedback:
1) Most importantly, it installed and worked first time - great stuff!
2) If the server address is set wrong on the initial settings page there's no way (that I could see) to correct with out un/reinstalling the app as it launches into an error page. Could be a problem with dynamically signed IP addresses.
3) Would swipe left/ right to change channel (app page, not the tv!) be a possibility for a future release?
Thanks for coming up with the idea for this and making it work, I can see it being quite a useful little addon for gbpvr.

Server Win7
Droid Zte Blade, 2.2 Froyo rooted

bgowland
2011-06-16, 08:17 PM
1) Most importantly, it installed and worked first time - great stuff!Great! :)


2) If the server address is set wrong on the initial settings page there's no way (that I could see) to correct with out un/reinstalling the app as it launches into an error page. Could be a problem with dynamically signed IP addresses.If you press the MENU button there's an option for 'Network Settings'...or are you unable to get that far before it crashes?

BTW, you should be able to reset everything without un-installing by simply using Settings -> Applications -> Manage Applications then select nDroid and use the 'Clear data' button. That should take it back to a 'first run' state next time you launch it.


3) Would swipe left/ right to change channel (app page, not the tv!) be a possibility for a future release?I've thought about this (I think somebody may have mentioned it previously but can't remember). It may be of some use to navigate between channels close together but only in addition to the current pop-up channel selector - swiping lots of channels would be slow (obviously). It's on a 'possibly maybe' list.


Thanks for coming up with the idea for this and making it work, I can see it being quite a useful little addon for gbpvr.Thanks for the feedback.

It's been on a back-burner for a while as it was beginning to get over complex (from a code point of view). I've started work on another version which initially won't have much more functionality but should be a lot more stable and solve a few major issues I'd identified behind the scenes.

Cheers,
Brian

txinga
2011-07-05, 10:17 PM
Nifty looking app. I cannot see any program data though. The install seemed to go smoothly. My DroidX downloaded the content from the server over wifi just fine, but no program data. I do see the channels. The client will connect via wifi or 3g.

Here are my log files.

Thanks,

txinga

bgowland
2011-07-05, 10:34 PM
Everything looks fine at the server end. Best guess is the nDroid client isn't processing the EPG import correctly.

If you email me the zip files from the "...\nDroid Service\data\zip" folder I can try and reproduce things. My email address is available through my Profile here.

Just out of interest, what version of Android are you running?

Cheers,
Brian

txinga
2011-07-05, 11:07 PM
Well, Hmm... I guess I shoulda waited a little longer. Just looked at my DroidX again and it's all there. Woohoo!

I'm running 2.3.3 on Verizon.

bgowland
2011-07-05, 11:37 PM
Well, Hmm... I guess I shoulda waited a little longer. Just looked at my DroidX again and it's all there. Woohoo!

I'm running 2.3.3 on Verizon.OK, good news. I have had a few occasions myself where the guide data doesn't appear immediately - exiting and going back in again normally fixes it. I'm guessing that might have been the problem although I haven't worked out why it happens yet.

Useful to know you're using 2.3.3 thanks - there shouldn't be any compatibility issues there.

Cheers,
Brian

BrettB
2011-07-17, 04:56 PM
Brian,

I was just wondering if you've had a chance to do any more work on this project?

- Brett

bgowland
2011-07-17, 10:30 PM
Hi Brett,

Thanks for the continued interest - it's still ongoing but I had some bouts of 'writer's block' over the past few months which have slowed me down. I've been looking at it again over the past few days but I'm not sure when there'll be another update - hopefully soon-ish but no definite time frame.

Cheers,
Brian

tieke
2011-10-18, 12:21 AM
A very useful app, and so close to working for me, but selected programs don't record. Haven't had nDroid server previously installed, so no problem there (client version 1.3.7, service 1.3.4109.8816 according to phone).

Installed service on 32-bit win 7 server, everything appears fine - can browse listings on phone (xperia mini, running android 2.3.3) but when I go to record a program the phone hangs on "Setting - please wait.." for quite a time. Eventually listing shows up on phone as recording (in red), but on the server, the show doesn't appear in pending recordings, and if a guide update is made from the phone, the program is no longer coloured red.

Firewall is disabled, and sc qc "nDroid Service" results in standard:

SERVICE_NAME: nDroid Service
TYPE : 10 WIN32_OWN_PROCESS
START_TYPE : 2 AUTO_START
ERROR_CONTROL : 1 NORMAL
BINARY_PATH_NAME : C:\Program Files\Beetec Services\nDroid Service\nDr
oidService.exe
LOAD_ORDER_GROUP :
TAG : 0
DISPLAY_NAME : nDroid Service
DEPENDENCIES :
SERVICE_START_NAME : LocalSystem

Logs are attached - there's a few errors in the helper log. Have I missed something obvious in my setup?

cheers,

tieke

bgowland
2011-10-19, 12:23 AM
A very useful app, and so close to working for me, but selected programs don't record. Haven't had nDroid server previously installed, so no problem there (client version 1.3.7, service 1.3.4109.8816 according to phone).Thanks for the positive response - I do hope it will be of use but I'm also aware the currently available version has its failings. (Must try harder :) ).

From your logs I can see the record requests being received, for example...
18/10/2011 12:02:58.562 request: System.Net.HttpListenerRequest
18/10/2011 12:02:58.562 hrhkey.Key: x-ndroid-action hrhkey.Value: record
18/10/2011 12:02:58.562 hrhkey.Key: x-ndroid-oid hrhkey.Value: 1937813
18/10/2011 12:02:58.562 hrhkey.Key: x-ndroid-channeloid hrhkey.Value: 7148
18/10/2011 12:02:58.562 hrhkey.Key: x-ndroid-starttime hrhkey.Value: 2011-10-18 03:00:00
18/10/2011 12:02:58.562 hrhkey.Key: x-ndroid-title hrhkey.Value: The Best... 80s Tunes
18/10/2011 12:02:58.562 hrhkey.Key: x-ndroid-rectype hrhkey.Value: ro
18/10/2011 12:02:58.562 hrhkey.Key: Connection hrhkey.Value: Keep-Alive
18/10/2011 12:02:58.562 hrhkey.Key: Accept-Encoding hrhkey.Value: gzip
18/10/2011 12:02:58.562 hrhkey.Key: Host hrhkey.Value: 203.97.221.14:8790
18/10/2011 12:02:58.562 User authenticated

The nDroid service actually uses NEWA to schedule the recordings and the last line above (user authenticated) normally means the requests was handled correctly by NEWA. Admittedly it's a bit vague and I'll try to add more descriptive logging to the next version.

I'm not sure what the issue is as the ndroid service obviously 'thinks' it was successful and has replied to the phone with a success code (hence why it turns red in the nDroid listing on the phone). Can you try setting a recording and then check the web.log file in the NPVR\logs folder - this is where NEWA logs various things. You should see something like the following...
2011-10-19 00:09:26.807 [DEBUG][4] Got Web Request (127.0.0.1): /public/services/ScheduleService.asmx
2011-10-19 00:09:26.807 [INFO][4] webServiceAuthentication credential found
2011-10-19 00:09:26.822 [INFO][4]
2011-10-19 00:09:26.822 [INFO][4]
2011-10-19 00:09:26.822 [INFO][4] *********************
2011-10-19 00:09:26.822 [INFO][4] * Validating Incomming Web Service
2011-10-19 00:09:26.822 [INFO][4] *
2011-10-19 00:09:26.838 [INFO][4] *
2011-10-19 00:09:26.838 [INFO][4] *
2011-10-19 00:09:26.838 [INFO][4] Checking Server time....
2011-10-19 00:09:26.838 [INFO][4] nowTime (Server-Local) = 19/10/2011 00:09:26
2011-10-19 00:09:26.838 [INFO][4] nowTime (Server-UTC) = 18/10/2011 23:09:26
2011-10-19 00:09:26.838 [INFO][4] Credential time string (from request) = 18/10/2011 23:09:26
2011-10-19 00:09:26.838 [INFO][4] Credential time converted (Local) = 19/10/2011 00:09:26
2011-10-19 00:09:26.838 [INFO][4] Credential time converted to DateObject = 18/10/2011 23:09:26
2011-10-19 00:09:26.838 [INFO][4] Span time seconds (calc = server-utc - credential-utc) = 0
2011-10-19 00:09:26.838 [INFO][4] User verified
2011-10-19 00:09:26.838 [INFO][4] nowTime (Server) = 19/10/2011 00:09:26
2011-10-19 00:09:26.838 [INFO][4] *
2011-10-19 00:09:26.838 [INFO][4] *
2011-10-19 00:09:26.838 [INFO][4] *********************
2011-10-19 00:09:26.838 [INFO][4]
2011-10-19 00:09:26.838 [INFO][4]
2011-10-19 00:09:27.041 [INFO][4] @@@@@
2011-10-19 00:09:27.041 [INFO][4] Found matching recording
2011-10-19 00:09:27.041 [INFO][4] @@@@@Out of interest, which version of NEWA are you using?

Cheers,
Brian

tieke
2011-10-20, 11:22 AM
Thanks for that - looks like it could well be an NEWA thing - was previously working, but for some reason now isn't. Will fault-find that end of things first.
cheers,
tieke

bgowland
2011-10-20, 08:48 PM
Thanks for that - looks like it could well be an NEWA thing - was previously working, but for some reason now isn't. Will fault-find that end of things first.Did you miss the last line of my post asking which version of NEWA you are using?

I haven't tested with the latest version (I'm still running the NEWA which came with npvr 2.2.6). If you updated NEWA and UJB has made changes that might affect things, that may explain it although I don't know how likely that is. I'll install the latest NEWA and test it out.

Cheers,
Brian

bgowland
2011-10-20, 10:22 PM
OK, I've tested with the latest version of NEWA and everything looks fine to me. I'll hopefully be uploading a new version of the nDroidService to the wiki tonight so it might be worth installing it and taking things from there. Watch out for a Community Announcement post.

Cheers,
Brian

tieke
2011-10-21, 09:14 AM
Problem fixed - reinstalled NPVR over top of the current install and now everything working. I had previously tried both the 2.2.6 default NEWA version and the latest version but they had just stopped working. All good now, and everything working with your new ndroid release - thanks for the app, will be very useful.

cheers,
tieke

bgowland
2011-10-21, 10:32 AM
All good now, and everything working with your new ndroid release - thanks for the app, will be very useful.OK, that's good news. There are still plenty of things to iron out and things I'd like to add (working on it at the moment).

Cheers,
Brian