GithubHelp home page GithubHelp logo

locam's People

Contributors

401unauthorized avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

locam's Issues

Add Snapshot, Streaming & Speaking Functionality

If anyone is interested in the following, please leave a comment or a reaction to this post.

Some functionality is missing from the current implementation:

stream(type, view)

  • Get the live stream of the camera
  • Display in a window or return the buffer

streamToFile(type, seconds)

  • Save the live stream of the camera to a file

streamToStream(type, format)

  • Restream the live stream of the camera in another format

vodStream(type, view)

  • Get the VOD recording stream of the camera
  • Display in a window or return the buffer

speak(type, audioStream)

  • Send an audio stream to the camera speaker

snapshotImage(type, link)

  • Get the latest thumbnail image from the camera

In order to provide more advanced integrations into other platforms such as @SmartThingsCommunity, @homebridge & @home-assistant, this functionality should become available.

It can be broken down into multiple milestones as follows:

  1. Snapshot Image (snapshotImage)
  2. Incoming Streams (stream, vodStream, streamToFile)
  3. Restream (streamToStream)
  4. Outgoing Streams (speak)

Getting Error Code -10007, Unauthorized Error

Loaded your code and then created the below test script. I validated the username and password by logging out and back into the Kasa App. I did not change any of the source modules. Node JS Version: 16.14.2.

TEST CODE:
const Camera = require('locam');
const c = new Camera({
auth: {
username: '[email protected]',
password: 'xxxxxxx'
},
camera: {
ip: '0.0.50.43',
port: 10443,
name: 'camera'
},
logging: true
});
// Get Night Vision Setting
c.send(c.Settings.nightVision('get')).then(d => {
console.log(d);
}).catch(err => {
console.error(error);
});

Results:
Configuration: {
ip: 'xxxxxxx',
port: 10443,
name: 'camera',
source: '8a2d067d-07fa-49b9-9289-d9f694f709b4',
token: 'yyyyyyyyyyyyy',
package: 'locam',
version: '1.0.3'
}
{
context: { source: { err_code: -10007, err_msg: 'Unauthorized Error' } },
'smartlife.cam.ipcamera.dayNight': { get_mode: { err_code: -10007, err_msg: 'Unauthorized Error' } }
}

LOCAM also supports KD110 DOORBELL

The basic code; especially the credentials/login work with the KD110 Doorbell. Of course, the PTZ commands do not work, but other commands do. Recommending updating readme to so indicate.

Dave

PS: Just tested KC115 again. Still can not get this to work with my HW Ver 2 KC115, I think the key is the Ver 2 HW.

Minimum Supported Node Version Incorrect

It was erroneously determined that this library is supported on v12 when it requires at least v14.

The short term solution will be to update the documentation and package.json to denote this.

The better long term solution would be to use a compiling tool like babel in order to allow backwards compatibility of this library with older versions of node.

Motion Detection Alert

There appears to not be a way go get a motion detection alert into the application. True?

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.