SageTV Community  

Go Back   SageTV Community > SageTV Development and Customizations > SageTV Customizations
Forum Rules FAQs Community Downloads Today's Posts Search

Notices

SageTV Customizations This forums is for discussing and sharing user-created modifications for the SageTV application created by using the SageTV Studio or through the use of external plugins. Use this forum to discuss customizations for SageTV version 6 and earlier, or for the SageTV3 UI.

Reply
 
Thread Tools Search this Thread Display Modes
  #81  
Old 11-19-2005, 01:06 PM
ToxMox's Avatar
ToxMox ToxMox is offline
Sage Icon
 
Join Date: Oct 2003
Location: NJ
Posts: 1,980
Hey Bob,
Would you mind doing me a favor and attaching a few files here for me?
First attach one or both of your properties files from the SageTV directory. (sage.properties & sageclient.properties if running service mode)
Could you also at a command prompt paste this line and hit enter(this will show a list of all files in your Sage directory structure and output it to a file):
Code:
dir /s "c:\Program Files\SageTV" > C:\sagedirs.txt
Then attach "sagedirs.txt" from the root of your C: drive that this will create.
Thanks.
Reply With Quote
  #82  
Old 11-19-2005, 01:52 PM
dranockcir dranockcir is offline
Sage Advanced User
 
Join Date: Jul 2004
Location: Jupiter, FL
Posts: 137
Quote:
Originally Posted by deria
...but does it work?

I think I may have picked the wrong plugin to port first. As nearly as I can tell, there has been only one download. Without knowing if this one actually works (ie: whether or not the framework is solid and my porting method is reliable) its going to be hard for me to move on to my other plugins. I can only speculate as to why there are no real downloads (either the plugin is uninteresting, the warning scared people away, the installation process was too hard, etc.). Hopefully some people will at least try it, though, because I can't really proceed until some people do and report back their success/failure.

Hi deria,

I downloaded and installed this, followed the instructions and it works great. Thanks for making it available, nice addition and I got a first hand try at messin' with Studio.

Rick
Reply With Quote
  #83  
Old 11-19-2005, 02:26 PM
deria deria is offline
Sage Aficionado
 
Join Date: Nov 2005
Posts: 408
Quote:
Originally Posted by dranockcir
Hi deria,

I downloaded and installed this, followed the instructions and it works great. Thanks for making it available, nice addition and I got a first hand try at messin' with Studio.

Rick
Thank god it works for -someone- other than me. I'm glad to hear it worked right off the bat for you. I just wish I knew why it doesn't work for half the people that try it.
Reply With Quote
  #84  
Old 11-19-2005, 02:27 PM
BobPhoenix BobPhoenix is offline
SageTVaholic
 
Join Date: Oct 2004
Posts: 3,152
Quote:
Originally Posted by nielm
(if it helps, running sage as a user with admin privs, and unpacked the files as the same user)

Bob, in Studio, can you enter in the Tools->expession evaluator :
Code:
java_lang_Class_forName("SystemMonitorPlugin")
this should indicate whether Sage can find the class or not...
If "Results Null" means what I think it means then it looks like it isn't finding the class.

Specs:
Win2K pro Administrator account on a Virtual PC session.

Just got the dual boot setup going to see if it will work on a real computer with XP Home.

BobP.
Reply With Quote
  #85  
Old 11-19-2005, 02:31 PM
deria deria is offline
Sage Aficionado
 
Join Date: Nov 2005
Posts: 408
Hi Bob,

I think that Nielm's and Toxmox's suggestions are both good ones. If you have time, could you try them both (particularly Nielm's suggestion of running that command to check if SageTV can see the class. That's a very good idea.

Nielm: What version of java do you have? The one that came with SageTV, or a more recent one? I'm not sure if it matters, but I'm curious because BobPhoenix has the one that came with SageTV and none of my systems do (they all have the latest one).
Reply With Quote
  #86  
Old 11-19-2005, 02:36 PM
deria deria is offline
Sage Aficionado
 
Join Date: Nov 2005
Posts: 408
Heh, you're fast Bob. I think you're right that in this case "result: null" would indicate a failure. I tried it on my ssytem where the plugin has no trouble working and I get "result: class SystemMonitorPlugin". Did you get any other error messages when you typed the command, or did it just immediately come back with result: null?

As an aside, can you try doing the same test with Filemon running and email me the result? That might tell us where SageTV (well, I guess "java" would be a more appropriate label than SageTV) is looking for the class.
Reply With Quote
  #87  
Old 11-19-2005, 02:36 PM
BobPhoenix BobPhoenix is offline
SageTVaholic
 
Join Date: Oct 2004
Posts: 3,152
Quote:
Originally Posted by ToxMox
Hey Bob,
Would you mind doing me a favor and attaching a few files here for me?
First attach one or both of your properties files from the SageTV directory. (sage.properties & sageclient.properties if running service mode)
Could you also at a command prompt paste this line and hit enter(this will show a list of all files in your Sage directory structure and output it to a file):
Code:
dir /s "c:\Program Files\SageTV" > C:\sagedirs.txt
Then attach "sagedirs.txt" from the root of your C: drive that this will create.
Thanks.
Archive is enclosed. Note this was with a SageTV Client so no Sage.Properties to included. I hope you see something because I far as I can tell it's a normal Win2K install and a normal SageTV Client.

BobP.

Last edited by BobPhoenix; 02-10-2006 at 06:43 PM.
Reply With Quote
  #88  
Old 11-19-2005, 02:44 PM
nielm's Avatar
nielm nielm is offline
SageTVaholic
 
Join Date: Oct 2003
Location: Belgium
Posts: 4,496
Did some more playing...

If SystemMonitorJNI.dll is not present, then...
new_SystemMonitorPlugin() returns null, and reports Catbert Method Lookup errors in the log..

java_lang_Class_forName("SystemMonitorPlugin") also returns null, but gives some more info in the logging... Note that this only occurs the first time after startup, and if you have not already done a new_SystemMonitorPlugin() ...

Code:
Sat 11/19 21:32:01.400 Caused by: java.lang.UnsatisfiedLinkError: no SystemMonitorJNI in java.library.path
Sat 11/19 21:32:01.401  at java.lang.ClassLoader.loadLibrary(Unknown  Source)
Sat 11/19 21:32:01.401  at java.lang.Runtime.loadLibrary0(Unknown Source)
Sat 11/19 21:32:01.401  at java.lang.System.loadLibrary(Unknown Source)
Sat 11/19 21:32:01.401  at SystemMonitorPlugin.<clinit>(SystemMonitorPlugin.java:5)
Sat 11/19 21:32:01.402  at java.lang.Class.forName0(Native Method)
If BasicSystemMonitor.dll is not present, then Sage can find and load the SystemMonitor class, and the first DLL, but crashes whenever the system monitor screen is launched...

... So from the symtoms seen so far, it is also possible that Bob's system cannot load the either the SystemMonitor class, or the SystemMonitorJNI.dll

Maybe for general use of JNI that studio always references a 'clean' Java class that then loads a JNI class, and can wrap and report JNI initialising errors such as LoadLibrary...
__________________
Check out my enhancements for Sage in the Sage Customisations and Sageplugins Wiki
Reply With Quote
  #89  
Old 11-19-2005, 02:47 PM
BobPhoenix BobPhoenix is offline
SageTVaholic
 
Join Date: Oct 2004
Posts: 3,152
Quote:
Originally Posted by deria
Heh, you're fast Bob. I think you're right that in this case "result: null" would indicate a failure. I tried it on my ssytem where the plugin has no trouble working and I get "result: class SystemMonitorPlugin". Did you get any other error messages when you typed the command, or did it just immediately come back with result: null?

As an aside, can you try doing the same test with Filemon running and email me the result? That might tell us where SageTV (well, I guess "java" would be a more appropriate label than SageTV) is looking for the class.
I can't take credit for being fast I was already doing it before you posted. Here is the filemon log I zipped it plus only launched it immediately before I issue NIELM's java in studio. However I think you just may have hit on the solution. Do you want me to install the latest Java? I haven't been installing the latest because of reported problems with FSE (if I remember correctly) and the latest version.

BobP.

Last edited by BobPhoenix; 02-10-2006 at 06:43 PM.
Reply With Quote
  #90  
Old 11-19-2005, 02:50 PM
ToxMox's Avatar
ToxMox ToxMox is offline
Sage Icon
 
Join Date: Oct 2003
Location: NJ
Posts: 1,980
Bob,
I see nothing wrong in the files I asked you to attach so the problem isn't there. I agree that trying the new Java is a good idea.
Here is a post by Jeff which shows how you can control which Java Sage uses so you can go back if you wish. Just keep both installs.
http://forums.sagetv.com/forums/show...26&postcount=7
Reply With Quote
  #91  
Old 11-19-2005, 02:56 PM
deria deria is offline
Sage Aficionado
 
Join Date: Nov 2005
Posts: 408
According to Filemon, Bob's system is opening, reading, and closing the .class file. It really does look like tis the subsequent "finding" of SystemMonitorJNI.dll thats failing. Based on Filemon its never even looking at it.

I'd say try the latest Java and see what happens. I've installed the trial version on another computer I have and I'll leave the version of java that gets installed with sage on it and then try the plugin.
Reply With Quote
  #92  
Old 11-19-2005, 02:58 PM
ToxMox's Avatar
ToxMox ToxMox is offline
Sage Icon
 
Join Date: Oct 2003
Location: NJ
Posts: 1,980
I just installed this as well and it worked right away for me too. Didn't even have to restart Sage. I am not using the latest Java but it is a 1.5 based ver (1.5.0_02).

Sidenote for anyone not wanting to mess with the Studio parts of the instructions. If you have nielm's Dynamic Menu import installed you can simply add the System Monitor menu via the Dynamic Menus after you import the System Monitor STVi.
Reply With Quote
  #93  
Old 11-19-2005, 03:07 PM
BobPhoenix BobPhoenix is offline
SageTVaholic
 
Join Date: Oct 2004
Posts: 3,152
Quote:
Originally Posted by deria
According to Filemon, Bob's system is opening, reading, and closing the .class file. It really does look like tis the subsequent "finding" of SystemMonitorJNI.dll thats failing. Based on Filemon its never even looking at it.

I'd say try the latest Java and see what happens. I've installed the trial version on another computer I have and I'll leave the version of java that gets installed with sage on it and then try the plugin.
Bingo!! It works with Java 1.5 but not with 1.4.2 on my Virtual PC session. Reason to upgrade the Java and test to see if I have any of the problems with SageTV and 1.5 that have been posted.

BobP.

Last edited by BobPhoenix; 11-19-2005 at 03:12 PM.
Reply With Quote
  #94  
Old 11-19-2005, 03:08 PM
deria deria is offline
Sage Aficionado
 
Join Date: Nov 2005
Posts: 408
Aha.

On my third computer (built from spare parts this morning!) I can finally reproduce the problem. I left the old version of Java, and it failed. I'll play around a bit and see what happens before I try the new version of Java.


I'll be interested to hear if the new version of java solves the problem for Bob.
Reply With Quote
  #95  
Old 11-19-2005, 04:10 PM
deria deria is offline
Sage Aficionado
 
Join Date: Nov 2005
Posts: 408
I'm behind the times. I missed your post above Bob.

I'm pleased to hear that it works with the newer version of Java. I'm hazy on why it wouldn't also work with the older version -- I was under the impression that once compiled there should be no trouble running it in any Java environment of your choosing. I guess not. I'm going to install the J2SE SDK 1.4.2_10 on my other system and see if compiling the .class file there results in it working on 1.4.x systems.
Reply With Quote
  #96  
Old 11-19-2005, 04:17 PM
BobPhoenix BobPhoenix is offline
SageTVaholic
 
Join Date: Oct 2004
Posts: 3,152
Quote:
Originally Posted by deria
I'm behind the times. I missed your post above Bob.

I'm pleased to hear that it works with the newer version of Java. I'm hazy on why it wouldn't also work with the older version -- I was under the impression that once compiled there should be no trouble running it in any Java environment of your choosing. I guess not. I'm going to install the J2SE SDK 1.4.2_10 on my other system and see if compiling the .class file there results in it working on 1.4.x systems.
OK and thanks to ToxMox for reminding me how to switch Java versions I can test it for you again.

BobP.
Reply With Quote
  #97  
Old 11-19-2005, 04:22 PM
nielm's Avatar
nielm nielm is offline
SageTVaholic
 
Join Date: Oct 2003
Location: Belgium
Posts: 4,496
Quote:
Originally Posted by deria
I'm behind the times. I missed your post above Bob.

I'm pleased to hear that it works with the newer version of Java. I'm hazy on why it wouldn't also work with the older version -- I was under the impression that once compiled there should be no trouble running it in any Java environment of your choosing. I guess not. I'm going to install the J2SE SDK 1.4.2_10 on my other system and see if compiling the .class file there results in it working on 1.4.x systems.
I believe Java 1.5 has a different internal bytecode format to java 1.4.2, which is not backward compatible -- probably related to extra Java 1.5 language features... I compile all my stuff with Eclipse set to java 1.4.2 format...

(I am also running in java 1.5)
__________________
Check out my enhancements for Sage in the Sage Customisations and Sageplugins Wiki
Reply With Quote
  #98  
Old 11-19-2005, 04:33 PM
deria deria is offline
Sage Aficionado
 
Join Date: Nov 2005
Posts: 408
Well, I think this problem is solved now.

Here is what I found; a Java 1.4.x class will run fine under both Java 1.4.x and Java 1.5.x but a Java 1.5.x class will -only- run on Java 1.5.x (as Nielm mentions in his post above).

I'm also going to include instructions regarding copying BasicSystemMonitor.dll to c:\windpws\system32 if for some reason it does not work in the default SageTV directory.

I'll also change the archive format so that the files aren't in a folder by default and so that the .stvi is placed automatically in a useful location within the SageTV tree so that people don't have to navigate to find it.

Finally, instead of posting in a message thread I'll put the download on the Sage customizations site.

Bob, here is a .class file I compiled with 1.4.2_10. If you can try this on your 1.4.x installation, you should be able to use the disk monitor without having to risk messing up your FSE experience.
Attached Files
File Type: zip java_1_4_2_10_class.zip (851 Bytes, 192 views)
Reply With Quote
  #99  
Old 11-19-2005, 04:49 PM
BobPhoenix BobPhoenix is offline
SageTVaholic
 
Join Date: Oct 2004
Posts: 3,152
Quote:
Originally Posted by deria
Bob, here is a .class file I compiled with 1.4.2_10. If you can try this on your 1.4.x installation, you should be able to use the disk monitor without having to risk messing up your FSE experience.
Works perfectly now. Just to make sure I uninstalled 1.5 so that I only had 1.4 Java installed. Then I reinstalled 1.5 and proved for myself that it works there as well. Now you can move on to more important things.

Edit: Forgot to mention I also deleted the copies of the DLL's in the Windows\System32 directory and the NativeLibPath registry setting before I did this test

BobP.

Last edited by BobPhoenix; 11-19-2005 at 05:00 PM.
Reply With Quote
  #100  
Old 11-19-2005, 05:08 PM
salsbst's Avatar
salsbst salsbst is offline
SageTVaholic
 
Join Date: Jun 2003
Posts: 2,592
What a nasty way JRE has of telling you that you have a version mismatch! Just report that methods aren't found. Yikes.
Reply With Quote
Reply


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

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


All times are GMT -6. The time now is 02:48 AM.


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