Skip to content

Fresh install not working, #29

@Sanman96

Description

@Sanman96

I am using Ubuntu 14.04 LTS (fresh install)
I installed pip and then used pip to install onvif as stated on the homepage.
I downloaded the wsdl file and xsd file straight form ONVIF.
When I launch python I typed

from onvif import ONVIFCamera

then

mycam = ONVIFCamera('IP_ADDR', 8088, 'admin', 'test', '')

i get

Traceback (most recent call last):
File "", line 1, in
File "/usr/local/lib/python2.7/dist-packages/onvif/client.py", line 227, in init
self.update_xaddrs()
File "/usr/local/lib/python2.7/dist-packages/onvif/client.py", line 237, in update_xaddrs
services = self.devicemgmt.GetServices({'IncludeCapability': False})
File "/usr/local/lib/python2.7/dist-packages/onvif/client.py", line 187, in getattr
return self.service_wrapper(getattr(self.ws_client.service, name))
File "/usr/local/lib/python2.7/dist-packages/suds/client.py", line 296, in getattr
port = self.__find(0)
File "/usr/local/lib/python2.7/dist-packages/suds/client.py", line 331, in __find
raise Exception, 'No services defined'
Exception: No services defined

I have the files where it is looking for them (/etc/onvif/wsdl/devicemgmt.wsdl and /ver10/schema/onvif.xsd)

If I use the interactive cli with

onvif-cli devicemgmt GetHostname --user 'admin' --password 'test' --host 'IPADDR' --port 8088

i get

Traceback (most recent call last):
File "/usr/local/bin/onvif-cli", line 9, in
load_entry_point('onvif==0.1.3', 'console_scripts', 'onvif-cli')()
File "/usr/local/lib/python2.7/dist-packages/onvif/cli.py", line 160, in main
cli.setup(args)
File "/usr/local/lib/python2.7/dist-packages/onvif/cli.py", line 39, in setup
args.wsdl, encrypt=args.encrypt)
File "/usr/local/lib/python2.7/dist-packages/onvif/client.py", line 227, in init
self.update_xaddrs()
File "/usr/local/lib/python2.7/dist-packages/onvif/client.py", line 237, in update_xaddrs
services = self.devicemgmt.GetServices({'IncludeCapability': False})
File "/usr/local/lib/python2.7/dist-packages/onvif/client.py", line 187, in getattr
return self.service_wrapper(getattr(self.ws_client.service, name))
File "/usr/local/lib/python2.7/dist-packages/suds/client.py", line 296, in getattr
port = self.__find(0)
File "/usr/local/lib/python2.7/dist-packages/suds/client.py", line 331, in __find
raise Exception, 'No services defined'
Exception: No services defined

Even though there are plenty of services declared in the onvif wsdl, why isn't the program recognizing it? I am new to onvif and trying to learn it as fast as possible and I thought this library would be the perfect start.

If it is any help I am trying to interface to a group of AVIGILON 2.0MP Day/Night 20x HD PTZ Dome Cameras.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions