kopiro / homebridge-tapo-camera

Homebridge plugin for TP-Link TAPO security cameras
ISC License
120 stars 10 forks source link

Homebridge on Synology DS 418 - Tapo Camera Error #70

Closed Abby74656 closed 1 year ago

Abby74656 commented 1 year ago

Hi, I have a problem. I have two cameras TP-Link Tapo C100, I was added to Homebridge, but in log is error, repeats itself. Is interesting, that I added this cameras to Apple Home Kit and they show real motion picture. Help me please, where is the problem? Thank you.

[1/25/2023, 11:46:27 PM] [TPLink] Try for 192.168.1.71 : 11/20 [1/25/2023, 11:46:27 PM] [TPLink] Error sending command: deviceInfo AxiosError: connect ECONNREFUSED 192.168.1.71:80 at Function.AxiosError.from (/volume1/homebridge/node_modules/homebridge-tp-link-tapo/node_modules/axios/lib/core/AxiosError.js:89:14) at RedirectableRequest.handleRequestError (/volume1/homebridge/node_modules/homebridge-tp-link-tapo/node_modules/axios/lib/adapters/http.js:533:25) at RedirectableRequest.emit (node:events:527:28) at ClientRequest.eventHandlers. (/volume1/homebridge/node_modules/homebridge-tp-link-tapo/node_modules/follow-redirects/index.js:14:24) at ClientRequest.emit (node:events:527:28) at Socket.socketErrorListener (node:_http_client:454:9) at Socket.emit (node:events:527:28) at emitErrorNT (node:internal/streams/destroy:157:8) at emitErrorCloseNT (node:internal/streams/destroy:122:3) at processTicksAndRejections (node:internal/process/task_queues:83:21) { port: 80, address: '192.168.1.71', syscall: 'connect', code: 'ECONNREFUSED', errno: -111, config: { transitional: { silentJSONParsing: true, forcedJSONParsing: true, clarifyTimeoutError: false }, adapter: [ 'xhr', 'http' ], transformRequest: [ [Function: transformRequest] ], transformResponse: [ [Function: transformResponse] ], timeout: 0, xsrfCookieName: 'XSRF-TOKEN', xsrfHeaderName: 'X-XSRF-TOKEN', maxContentLength: -1, maxBodyLength: -1, env: { FormData: [Function], Blob: null }, validateStatus: [Function: validateStatus], headers: AxiosHeaders { Accept: 'application/json, text/plain, /', 'Content-Type': 'application/json', 'User-Agent': 'axios/1.2.2', 'Content-Length': '352', 'Accept-Encoding': 'gzip, compress, deflate, br' }, method: 'post', url: 'http://192.168.1.71/app', data: '{"method":"handshake","params":{"key":"-----BEGIN PUBLIC KEY-----\nMIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDeJlvciz1+n+pJaBi5ZAp6/nRg\njBucGVMuVZjBurL55SAw9iYsWFxl0wwqwjk6zOvQTKe+3nZd4Mqe2bz2BLdJrPE4\nsf9SSOjQbHb7qhe35zMIqL7jZYAai5SVPDLVf7GjEOGYPeu1WAl4vIRY7PGg7wWf\nfQIGXPgKgH6920Pd9QIDAQAB\n-----END PUBLIC KEY-----\n"},"requestTimeMils":1674686787757}' }, request: <ref *1> Writable { _writableState: WritableState { objectMode: false, highWaterMark: 16384, finalCalled: false, needDrain: false, ending: false, ended: false, finished: false, destroyed: false, decodeStrings: true, defaultEncoding: 'utf8', length: 0, writing: false, corked: 0, sync: true, bufferProcessing: false, onwrite: [Function: bound onwrite], writecb: null, writelen: 0, afterWriteTickInfo: null, buffered: [], bufferedIndex: 0, allBuffers: true, allNoop: true, pendingcb: 0, constructed: true, prefinished: false, errorEmitted: false, emitClose: true, autoDestroy: true, errored: null, closed: false, closeEmitted: false,

},
_events: [Object: null prototype] {
  response: [Function: handleResponse],
  error: [Function: handleRequestError],
  socket: [Function: handleRequestSocket]
},
_eventsCount: 3,
_maxListeners: undefined,
_options: {
  maxRedirects: 21,
  maxBodyLength: Infinity,
  protocol: 'http:',
  path: '/app',
  method: 'POST',
  headers: [Object: null prototype],
  agents: [Object],
  auth: undefined,
  beforeRedirect: [Function: dispatchBeforeRedirect],
  beforeRedirects: [Object],
  hostname: '192.168.1.71',
  port: '',
  agent: undefined,
  nativeProtocols: [Object],
  pathname: '/app'
},
_ended: false,
_ending: true,
_redirectCount: 0,
_redirects: [],
_requestBodyLength: 352,
_requestBodyBuffers: [ [Object] ],
_onNativeResponse: [Function (anonymous)],
_currentRequest: ClientRequest {
  _events: [Object: null prototype],
  _eventsCount: 7,
  _maxListeners: undefined,
  outputData: [],
  outputSize: 0,
  writable: true,
  destroyed: false,
  _last: true,
  chunkedEncoding: false,
  shouldKeepAlive: false,
  maxRequestsOnConnectionReached: false,
  _defaultKeepAlive: true,
  useChunkedEncodingByDefault: true,
  sendDate: false,
  _removedConnection: false,
  _removedContLen: false,
  _removedTE: false,
  _contentLength: null,
  _hasBody: true,
  _trailer: '',
  finished: false,
  _headerSent: true,
  _closed: false,
  socket: [Socket],
  _header: 'POST /app HTTP/1.1\r\n' +
    'Accept: application/json, text/plain, */*\r\n' +
    'Content-Type: application/json\r\n' +
    'User-Agent: axios/1.2.2\r\n' +
    'Content-Length: 352\r\n' +
    'Accept-Encoding: gzip, compress, deflate, br\r\n' +
    'Host: 192.168.1.71\r\n' +
    'Connection: close\r\n' +
    '\r\n',
  _keepAliveTimeout: 0,
  _onPendingData: [Function: nop],
  agent: [Agent],
  socketPath: undefined,
  method: 'POST',
  maxHeaderSize: undefined,
  insecureHTTPParser: undefined,
  path: '/app',
  _ended: false,
  res: null,
  aborted: false,
  timeoutCb: null,
  upgradeOrConnect: false,
  parser: null,
  maxHeadersCount: null,
  reusedSocket: false,
  host: '192.168.1.71',
  protocol: 'http:',
  _redirectable: [Circular *1],
  [Symbol(kCapture)]: false,
  [Symbol(kNeedDrain)]: false,
  [Symbol(corked)]: 0,
  [Symbol(kOutHeaders)]: [Object: null prototype]
},
_currentUrl: 'http://192.168.1.71/app',
[Symbol(kCapture)]: false

}, cause: Error: connect ECONNREFUSED 192.168.1.71:80 at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1187:16) { errno: -111, code: 'ECONNREFUSED', syscall: 'connect', address: '192.168.1.71', port: 80 } } [1/25/2023, 11:46:27 PM] [TPLink] Failed to get info about: 192.168.1.71 | The first argument must be of type string or an instance of Buffer, ArrayBuffer, or Array or an Array-like Object. Received undefined

kopiro commented 1 year ago

Something is wrong with your configuration or credentials passed to Homebridge; please check them again.