Giter Site home page Giter Site logo

onvif-rs's Introduction

ONVIF-rs

ONVIF-rs is a Rust client library implementation of the ONVIF specification.

Features

  • all ONVIF types are generated from official schema
  • all ONVIF operations are generated from official schema
  • operations are async (currently only tokio runtime is supported)
  • device discovery on the local network using WS-discovery which is mandatory for all ONVIF devices
  • authentication using WS-Security UsernameToken which is mandatory for all ONVIF devices
  • zero unsafe

Usage

Cargo.toml:

[dependencies]
onvif = { git = "https://github.com/lumeohq/onvif-rs" }

Troubleshooting

If you have an issue with OpenSSL build under Ubuntu, perform the following actions:

sudo apt install openssl1.0 libssl1.0.0 libssl1.0-dev
cargo clean
export OPENSSL_LIB_DIR=/usr/lib/x86_64-linux-gnu
export OPENSSL_INCLUDE_DIR=/usr/include/openssl
cargo build

Examples

To discover devices on the local network:

cargo run --example discovery

To inspect and control a camera:

cargo run --example camera -- help

cargo run --example camera -- get-system-date-and-time \
    --uri=http://192.168.0.2:8000

cargo run --example camera -- set-hostname \
    --uri=http://192.168.0.2:8000 --username=admin --password=qwerty cam2

cargo run --example camera -- get-stream-uris --uri=http://192.168.0.2:8000

Dependencies

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.

License

MIT

onvif-rs's People

Contributors

caspermeijn avatar dave-andersen avatar dmitrysamoylov avatar jplatte avatar leonidkrutovsky avatar patrickelectric avatar scottlamb avatar sovictor avatar victor-soloviev avatar wiseman avatar zeenix avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.