Skip to content

How do I run this code? #74

@maurus56

Description

@maurus56

sorry about the stupid question but i tried with the "dualshock-controller" in the terminal thinking it was a standalone and also with "node dualshock-controller" and got this

maurolanzas-MBP:~ maurolanza$ node dualshock-controller
module.js:557
    throw err;
    ^

Error: Cannot find module '/Users/maurolanza/dualshock-controller'
    at Function.Module._resolveFilename (module.js:555:15)
    at Function.Module._load (module.js:482:25)
    at Function.Module.runMain (module.js:701:10)
    at startup (bootstrap_node.js:193:16)
    at bootstrap_node.js:617:3

and during instalation:

maurolanzas-MBP:~ maurolanza$ npm install dualshock-controller

> node-hid@0.5.7 install /Users/maurolanza/node_modules/node-hid
> prebuild-install || node-gyp rebuild

prebuild-install info begin Prebuild-install version 2.5.0
prebuild-install info looking for local prebuild @ prebuilds/node-hid-v0.5.7-node-v59-darwin-x64.tar.gz
prebuild-install info looking for cached prebuild @ /Users/maurolanza/.npm/_prebuilds/https-github.com-node-hid-node-hid-releases-download-v0.5.7-node-hid-v0.5.7-node-v59-darwin-x64.tar.gz
prebuild-install http request GET https://github.com/node-hid/node-hid/releases/download/v0.5.7/node-hid-v0.5.7-node-v59-darwin-x64.tar.gz
prebuild-install http 404 https://github.com/node-hid/node-hid/releases/download/v0.5.7/node-hid-v0.5.7-node-v59-darwin-x64.tar.gz
prebuild-install WARN install No prebuilt binaries found (target=9.4.0 runtime=node arch=x64 platform=darwin)
xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command line tools instance

xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command line tools instance

  CC(target) Release/obj.target/hidapi/hidapi/mac/hid.o
../hidapi/mac/hid.c:252:20: warning: comparison of integers of different signs: 'CFIndex' (aka 'long') and 'size_t' (aka 'unsigned long')
      [-Wsign-compare]
                if (chars_copied == len)
                    ~~~~~~~~~~~~ ^  ~~~
1 warning generated.
  LIBTOOL-STATIC Release/hidapi.a
  CXX(target) Release/obj.target/HID/src/HID.o
../src/HID.cc:207:45: warning: 'NewInstance' is deprecated [-Wdeprecated-declarations]
    Local<Object> buf = nodeBufConstructor->NewInstance(1, nodeBufferArgs);
                                            ^
/Users/maurolanza/.node-gyp/9.4.0/include/node/v8.h:3843:3: note: 'NewInstance' has been explicitly marked deprecated here
  V8_DEPRECATED("Use maybe version",
  ^
/Users/maurolanza/.node-gyp/9.4.0/include/node/v8config.h:321:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated))
                            ^
1 warning generated.
  SOLINK_MODULE(target) Release/HID.node
npm WARN saveError ENOENT: no such file or directory, open '/Users/maurolanza/package.json'
npm notice created a lockfile as package-lock.json. You should commit this file.
npm WARN enoent ENOENT: no such file or directory, open '/Users/maurolanza/package.json'
npm WARN maurolanza No description
npm WARN maurolanza No repository field.
npm WARN maurolanza No README data
npm WARN maurolanza No license field.

+ dualshock-controller@1.1.1
added 56 packages in 84.514s

Is there any problem with that?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions