Motorola V3 Mobile Phone

Post here to indicate any hardware you have used and which is known to work with ZoneMinder. Not for questions.
Post Reply
User avatar
voronwe
Posts: 193
Joined: Tue Jan 18, 2005 12:40 am
Location: Copenhagen Denmark

Motorola V3 Mobile Phone

Post by voronwe »

Hey all

I have just tested ZoneMinder with the latest WURFL installed and my Mobile Phone : Motorola V3

And this does not work at the moment, if anyone else have this working please direct me to a solotion.
Best Regards
Tom Stage
User avatar
zoneminder
Site Admin
Posts: 5215
Joined: Wed Jul 09, 2003 2:07 pm
Location: Bristol, UK
Contact:

Post by zoneminder »

What is it that doesn't work on it? I initially developed the interface on a V600 so I would have thought it a Razr wouldn't be all that different.

Phil
User avatar
voronwe
Posts: 193
Joined: Tue Jan 18, 2005 12:40 am
Location: Copenhagen Denmark

Post by voronwe »

Hi Phill

I get the following error in the WURFL Log file :

Code: Select all

Mon, 16 May 2005 17:49:41 +0200 [voronwe.dk 24275][constructor] Class Initiated
Mon, 16 May 2005 17:49:41 +0200 [voronwe.dk 24275][GetDeviceCapabilitiesFromAgent] searching for MOT-c350
Mon, 16 May 2005 17:49:41 +0200 [voronwe.dk 24275][GetDeviceCapabilitiesFromAgent] cache enabled, WURFL is not loaded, now loading
Mon, 16 May 2005 17:49:41 +0200 [voronwe.dk 24275][GetDeviceCapabilitiesFromAgent] loading WURFL from cache
Mon, 16 May 2005 17:49:41 +0200 [voronwe.dk 24275][GetDeviceCapabilitiesFromAgent] Searching in the agent database
Mon, 16 May 2005 17:49:41 +0200 [voronwe.dk 24275][GetDeviceCapabilitiesFromAgent] WARNING: I couldn't find the device in my list, the headers are my last chance
Mon, 16 May 2005 17:49:41 +0200 [voronwe.dk 24275][_WriteFastAgentToId] Created temp file wurfl/agent2id.php44288c1159f53e7.48811313 
Mon, 16 May 2005 17:49:41 +0200 [voronwe.dk 24275][_WriteFastAgentToId] Done caching user_agent to wurfl_id
Mon, 16 May 2005 17:49:41 +0200 [voronwe.dk 24275][_GetFullCapabilities] searching for generic
Mon, 16 May 2005 17:49:41 +0200 [voronwe.dk 24275][_GetDeviceCapabilitiesFromId] reading id:generic
Mon, 16 May 2005 17:49:41 +0200 [voronwe.dk 24275][_GetDeviceCapabilitiesFromId] ERROR: the id generic is not present in wurfl_agents
Mon, 16 May 2005 17:50:35 +0200 [voronwe.dk 24274][constructor] Class Initiated
Mon, 16 May 2005 17:50:35 +0200 [voronwe.dk 24274][GetDeviceCapabilitiesFromAgent] searching for MOT-V3/0E.40.3CR MIB/2.2.1 Profile/MIDP-2.0 Configuration/CLDC-1.0
Mon, 16 May 2005 17:50:35 +0200 [voronwe.dk 24274][GetDeviceCapabilitiesFromAgent] cache enabled, WURFL is not loaded, now loading
Mon, 16 May 2005 17:50:35 +0200 [voronwe.dk 24274][GetDeviceCapabilitiesFromAgent] loading WURFL from cache
Mon, 16 May 2005 17:50:35 +0200 [voronwe.dk 24274][GetDeviceCapabilitiesFromAgent] Searching in the agent database
Mon, 16 May 2005 17:50:35 +0200 [voronwe.dk 24274][GetDeviceCapabilitiesFromAgent] WARNING: I couldn't find the device in my list, the headers are my last chance
Mon, 16 May 2005 17:50:35 +0200 [voronwe.dk 24274][_WriteFastAgentToId] Created temp file wurfl/agent2id.php44288c14bb9f544.47943468 
Mon, 16 May 2005 17:50:35 +0200 [voronwe.dk 24274][_WriteFastAgentToId] Done caching user_agent to wurfl_id
Mon, 16 May 2005 17:50:35 +0200 [voronwe.dk 24274][_GetFullCapabilities] searching for generic
Mon, 16 May 2005 17:50:35 +0200 [voronwe.dk 24274][_GetDeviceCapabilitiesFromId] reading id:generic
Mon, 16 May 2005 17:50:35 +0200 [voronwe.dk 24274][_GetDeviceCapabilitiesFromId] ERROR: the id generic is not present in wurfl_agents
Mon, 16 May 2005 17:50:47 +0200 [voronwe.dk 24276][constructor] Class Initiated
Mon, 16 May 2005 17:50:47 +0200 [voronwe.dk 24276][GetDeviceCapabilitiesFromAgent] searching for MOT-V3/0E.40.3CR MIB/2.2.1 Profile/MIDP-2.0 Configuration/CLDC-1.0
Mon, 16 May 2005 17:50:47 +0200 [voronwe.dk 24276][_ReadFastAgentToId] Found MOT-V3/0E.40.3CR MIB/2.2.1 Profile/MIDP-2.0 Configuration/CLDC-1.0 with id=
Mon, 16 May 2005 17:50:47 +0200 [voronwe.dk 24276][GetDeviceCapabilitiesFromAgent] Device found in local cache, the id is 
Mon, 16 May 2005 17:50:47 +0200 [voronwe.dk 24276][_GetFullCapabilities] searching for 
Mon, 16 May 2005 17:50:47 +0200 [voronwe.dk 24276][_GetDeviceCapabilitiesFromId] reading id:
Mon, 16 May 2005 17:50:47 +0200 [voronwe.dk 24276][_GetDeviceCapabilitiesFromId] ERROR: the id  is not present in wurfl_agents
Mon, 16 May 2005 17:51:11 +0200 [voronwe.dk 24271][constructor] Class Initiated
Mon, 16 May 2005 17:51:11 +0200 [voronwe.dk 24271][GetDeviceCapabilitiesFromAgent] searching for MOT-V3/0E.40.3CR MIB/2.2.1 Profile/MIDP-2.0 Configuration/CLDC-1.0
Mon, 16 May 2005 17:51:11 +0200 [voronwe.dk 24271][_ReadFastAgentToId] Found MOT-V3/0E.40.3CR MIB/2.2.1 Profile/MIDP-2.0 Configuration/CLDC-1.0 with id=
Mon, 16 May 2005 17:51:11 +0200 [voronwe.dk 24271][GetDeviceCapabilitiesFromAgent] Device found in local cache, the id is 
Mon, 16 May 2005 17:51:11 +0200 [voronwe.dk 24271][_GetFullCapabilities] searching for 
Mon, 16 May 2005 17:51:11 +0200 [voronwe.dk 24271][_GetDeviceCapabilitiesFromId] reading id:
Mon, 16 May 2005 17:51:11 +0200 [voronwe.dk 24271][_GetDeviceCapabilitiesFromId] ERROR: the id  is not present in wurfl_agents 
And the file created by WURFL contains the following. :

Code: Select all

<?php 
$cached_agents = array (
  0 => 
  array (
    'user_agent' => 'MOT-c350',
    'is_wap' => true,
    'capabilities' => 
    array (
    ),
  ),
  1 => 
  array (
    'user_agent' => 'MOT-V3/0E.40.3CR MIB/2.2.1 Profile/MIDP-2.0 Configuration/CLDC-1.0',
    'is_wap' => true,
    'capabilities' => 
    array (
    ),
  ),
)?>


And as u can see i tryed to login 2 times and the ident of my phone is different both times, i get a page saying that it could not be loaded.
The Following is from my apache log. :

Code: Select all

[client 194.182.251.15] PHP Warning:  fputs(): supplied argument is not a valid stream resource in /home/httpd/subdomains/zoneminder/html/zm/wurfl_class.php on line 643
[client 194.182.251.15] PHP Warning:  fclose(): supplied argument is not a valid stream resource in /home/httpd/subdomains/zoneminder/html/zm/wurfl_class.php on line 644
[client 194.182.251.15] PHP Warning:  fopen(wurfl/wurfl.log): failed to open stream: Permission denied in /home/httpd/subdomains/zoneminder/html/zm/wurfl_class.php on line 642
[client 194.182.251.15] PHP Warning:  fputs(): supplied argument is not a valid stream resource in /home/httpd/subdomains/zoneminder/html/zm/wurfl_class.php on line 643
[client 194.182.251.15] PHP Warning:  fclose(): supplied argument is not a valid stream resource in /home/httpd/subdomains/zoneminder/html/zm/wurfl_class.php on line 644
[client 194.182.251.15] PHP Warning:  fopen(wurfl/wurfl.log): failed to open stream: Permission denied in /home/httpd/subdomains/zoneminder/html/zm/wurfl_class.php on line 642
[client 194.182.251.15] PHP Warning:  fputs(): supplied argument is not a valid stream resource in /home/httpd/subdomains/zoneminder/html/zm/wurfl_class.php on line 643
[client 194.182.251.15] PHP Warning:  fclose(): supplied argument is not a valid stream resource in /home/httpd/subdomains/zoneminder/html/zm/wurfl_class.php on line 644
[client 194.182.251.15] PHP Warning:  fopen(wurfl/wurfl.log): failed to open stream: Permission denied in /home/httpd/subdomains/zoneminder/html/zm/wurfl_class.php on line 642
[client 194.182.251.15] PHP Warning:  fputs(): supplied argument is not a valid stream resource in /home/httpd/subdomains/zoneminder/html/zm/wurfl_class.php on line 643
[client 194.182.251.15] PHP Warning:  fclose(): supplied argument is not a valid stream resource in /home/httpd/subdomains/zoneminder/html/zm/wurfl_class.php on line 644
[client 194.182.251.15] PHP Warning:  fopen(wurfl/wurfl.log): failed to open stream: Permission denied in /home/httpd/subdomains/zoneminder/html/zm/wurfl_class.php on line 642
[client 194.182.251.15] PHP Warning:  fputs(): supplied argument is not a valid stream resource in /home/httpd/subdomains/zoneminder/html/zm/wurfl_class.php on line 643
[client 194.182.251.15] PHP Warning:  fclose(): supplied argument is not a valid stream resource in /home/httpd/subdomains/zoneminder/html/zm/wurfl_class.php on line 644
[client 194.182.251.15] PHP Warning:  fopen(wurfl/wurfl.log): failed to open stream: Permission denied in /home/httpd/subdomains/zoneminder/html/zm/wurfl_class.php on line 642
[client 194.182.251.15] PHP Warning:  fputs(): supplied argument is not a valid stream resource in /home/httpd/subdomains/zoneminder/html/zm/wurfl_class.php on line 643
[client 194.182.251.15] PHP Warning:  fclose(): supplied argument is not a valid stream resource in /home/httpd/subdomains/zoneminder/html/zm/wurfl_class.php on line 644
[client 194.182.251.15] PHP Warning:  fopen(wurfl/wurfl.log): failed to open stream: Permission denied in /home/httpd/subdomains/zoneminder/html/zm/wurfl_class.php on line 642
[client 194.182.251.15] PHP Warning:  fputs(): supplied argument is not a valid stream resource in /home/httpd/subdomains/zoneminder/html/zm/wurfl_class.php on line 643
[client 194.182.251.15] PHP Warning:  fclose(): supplied argument is not a valid stream resource in /home/httpd/subdomains/zoneminder/html/zm/wurfl_class.php on line 644
[client 194.182.251.15] PHP Warning:  fopen(wurfl/wurfl.log): failed to open stream: Permission denied in /home/httpd/subdomains/zoneminder/html/zm/wurfl_class.php on line 642
[client 194.182.251.15] PHP Warning:  fputs(): supplied argument is not a valid stream resource in /home/httpd/subdomains/zoneminder/html/zm/wurfl_class.php on line 643
[client 194.182.251.15] PHP Warning:  fclose(): supplied argument is not a valid stream resource in /home/httpd/subdomains/zoneminder/html/zm/wurfl_class.php on line 644
[client 194.182.251.15] PHP Warning:  fopen(wurfl/wurfl.log): failed to open stream: Permission denied in /home/httpd/subdomains/zoneminder/html/zm/wurfl_class.php on line 642
[client 194.182.251.15] PHP Warning:  fputs(): supplied argument is not a valid stream resource in /home/httpd/subdomains/zoneminder/html/zm/wurfl_class.php on line 643
[client 194.182.251.15] PHP Warning:  fclose(): supplied argument is not a valid stream resource in /home/httpd/subdomains/zoneminder/html/zm/wurfl_class.php on line 644
[client 194.182.251.15] PHP Warning:  fopen(wurfl/wurfl.log): failed to open stream: Permission denied in /home/httpd/subdomains/zoneminder/html/zm/wurfl_class.php on line 642
[client 194.182.251.15] PHP Warning:  fputs(): supplied argument is not a valid stream resource in /home/httpd/subdomains/zoneminder/html/zm/wurfl_class.php on line 643
[client 194.182.251.15] PHP Warning:  fclose(): supplied argument is not a valid stream resource in /home/httpd/subdomains/zoneminder/html/zm/wurfl_class.php on line 644 
Best Regards
Tom Stage
User avatar
zoneminder
Site Admin
Posts: 5215
Joined: Wed Jul 09, 2003 2:07 pm
Location: Bristol, UK
Contact:

Post by zoneminder »

A couple of things to check

1) Does it work with any other phone?
2) Is your cache directory etc writeable? The invalid file handle errors look a bit suspicious
3) I have had the wurfl dump incomplete cache files when it runs out of memory. You could try increasing the available memory in php.ini, restarting apache and deleting your cache files to see if that makes any difference.

Phil
User avatar
voronwe
Posts: 193
Joined: Tue Jan 18, 2005 12:40 am
Location: Copenhagen Denmark

Post by voronwe »

Hi Phil

1) I dont have any other phone to test with, at the moment.
2) My cache directory have chmod 777 on it, so that sgould not be the problem.
3) I have tested the memory setting and no dice will test the delete cache thing right away.
Best Regards
Tom Stage
User avatar
voronwe
Posts: 193
Joined: Tue Jan 18, 2005 12:40 am
Location: Copenhagen Denmark

Post by voronwe »

Hi Phil

Did the remove cache test and still no dice.

This is not a big issue for me atm.
Best Regards
Tom Stage
User avatar
voronwe
Posts: 193
Joined: Tue Jan 18, 2005 12:40 am
Location: Copenhagen Denmark

Post by voronwe »

Hi All

Ok i finally solved this problem, and here comes the conclusion. :

WURFL php scripts downloaded and installed in the ZoneMinder root web dir.
WURFL xml file downloaded and installed inside a directory called wurfl in the ZM root web dir.
The wurfl_config.php file edited so that the data dir points to wurfl instead of data.
Inside the wurfl directory i created the multicache and multicache_tmp dir, so the structure now looks like this. :
[ZoneMinder Web Dir]/wurfl
[ZoneMinder Web Dir]/wurfl/multicache
[ZoneMinder Web Dir]/wurfl/multicache_tmp

I then did a : chmod 777 -R wurfl/
Then a : chown apache.apache -R wurfl/
Then a : chmod 644 wurfl/wurfl.xml

It turns out that i was missing the 2 multicache dir´s when they where added i could now log in to ZoneMinder.
Best Regards
Tom Stage
User avatar
zoneminder
Site Admin
Posts: 5215
Joined: Wed Jul 09, 2003 2:07 pm
Location: Bristol, UK
Contact:

Post by zoneminder »

Good. I'm glad you worked that out. I think you must have a newer version of WURFL than me as I don't remember any multicache directory when I installed it. I should try and do an update when I get time.

Phil
User avatar
voronwe
Posts: 193
Joined: Tue Jan 18, 2005 12:40 am
Location: Copenhagen Denmark

Post by voronwe »

:) Well the 1 i run atm is the latest from their website.
Best Regards
Tom Stage
Gool
Posts: 6
Joined: Sun Mar 26, 2006 7:16 am

RAZR V3 & ZM

Post by Gool »

Hi all, I can't get work my RAZR with wurfl package (RAZR send request in HTML format and other problems) but I found the simple way, just add this code (only shown in bold!) to zm.php (see below) and change MOT-V3/0E.40.9CR MIB/2.2.1 Profile/MIDP-2.0 Configuration/CLDC-1.0.5 string to Your phone useragent string.

if ( $_GET['format'] )
{
$format = $_GET['format'];
$cookies = true;
}
if ( $_GET['cookies'] )
{
$cookies = $_GET['cookies'];
}
if ( $_GET['devwidth'] )
{
$device['width'] = $_GET['devwidth'];
}
if ( $_GET['devheight'] )
{
$device['height'] = $_GET['devheight'];
}

$ddd=getenv('HTTP_USER_AGENT');
if ("$ddd" == "MOT-V3/0E.40.9CR MIB/2.2.1 Profile/MIDP-2.0 Configuration/CLDC-1.0.5" )
{
$format = xhtml;
$cookies = true;
$width = 176;
$height = 220;
}
linuxsense
Posts: 374
Joined: Wed Nov 07, 2007 1:59 am
Location: Huntington Beach, California
Contact:

Post by linuxsense »

I was having a hard time getting wurfl to work properly (still looking into the issue) but used the quick-n-dirty hack that Gool listed above to enable support for my Treo 650 for now. Works well. I connect to my LAN via PPTP and then I can access ZM in a tidy interface. You can access the normal interface via Blazer in a pinch but this is much more usable.

Here is what I used for the Treo 650:

Code: Select all

// Treo 650 hack
$ddd=getenv('HTTP_USER_AGENT');
if ("$ddd" == "Mozilla/4.0 (compatible; MSIE 6.0; Windows 98; PalmSource/hspr-H102; Blazer/4.3) 16;320x320" )
{
$format = xhtml;
$cookies = true;
$width = 320;
$height = 320;
}
// end Treo 650 hack
Just insert those lines starting at line 79 (at least for 1.22.3) in 'zm.php' and you can access via your Treo 650 without the hassle of wurfl.

Thanks for the info Gool.

edit: It turns out that my phone is simply not properly ID'ed by wurfl. Its a unlocked 650 with a very hacked ROM so that is not surprising. I dont have any other VPN capable phones so I cant test but it looks like wurfl is working, just not for my oddball phone.
Post Reply