Particle Dev v0.0.25 released

@suda, I am on OS X 10.10.4 and indeed the Particle Dev auto updated. I was seeing my Photons when plugged into the USB port on the serial monitor in Particle Dev. Now that serial port is missing and I can no longer monitor the Photon’s serial port. I see choices under serial in Dev of a printer that is not connected, a bluetooth.modem, a bluetooth.incoming.port, and my iPhone.wire. Additionally, using the CLI after logging into particle and giving the particle serial list command it returns “no devices available via serial.” So it would appear that this autoupdate broke the ability to monitor the serial line on USB connected Photons. Any suggests are welcome as I was depending on this for monitoring my apps in development and now I am stuck. I really don’t like auto updates on most software. Is their a way to fix this or revert so I can use the usb serial functionality again?

Update: now even Arduino development environment can no longer see USB connected Uno boards. The update seems to have hosed the usb driver.

2nd Update: So going into Arduino local dev I am able to re-establish a USB connection to my Arduino boards-but switching back to the updated Particle Dev environment shows no USB connections to connected Photons. How to get this USB connection back???

Particle Dev doesn’t do anything with the device driver so this shouldn’t happen. Can you see Arduino board in Dev’s serial monitor? Could you also post a screenshot of serial monitor with opened port dropdown?

Images below. Using .24 I was able to connect to Photon via usb, after update I can no longer do so. Images as requested below. Any suggestion on what I can do to get a usb serial working with Photons again? Is there some setup or configuration I can perform? Thanks.

Image below with Arduino connected via USB:

and now when I plugin a Photon I get this:

Ok so I did switch USB cables to the Photon and it established a usb connection to Particle Dev. The other cable is going in the trash! Problem Solved!

1 Like

Are you sure? I run Ubuntu 14.04 and when I tried to install the spark-dev package, I get an error. I didn’t bother trying the other two packages.

1 Like

Ok, I installed Ubuntu 14.04 and there are in fact some issues. After installing spark-dev package go to terminal and type:

$ cd ~/.atom/packages/spark-dev
$ npm install nopt
$ rm -rf node_modules/serialport
$ export ATOM_NODE_VERSION=0.22.3
$ apm install .
$ apm install tool-bar
$ apm rebuild-module-cache

Go to Atom, hit Cmd+Shift+P, type cache and select Incompatible Packages: Reload Atom And Recheck Packages. You should see Particle menu now :slight_smile:

1 Like

Thanks, this worked for me on Linux Mint 17.2.

1 Like

I think this should be in the Particle documentation somewhere, until a native Linux version of Particle Dev is released. From my knowledge, there are a lot of Linux users at a setback because they don’t have Particle Dev, and they would greatly appreciate this information.

You’re right. As this is an experimental way to run it I added it to the readme.

1 Like

The installation of the spark-dev package fails with this output:

> runas@2.0.0 install /tmp/apm-install-dir-115720-6900-znw1p6/node_modules/spark-dev/node_modules/pathwatcher/node_modules/runas
> node-gyp rebuild

make: Entering directory `/tmp/apm-install-dir-115720-6900-znw1p6/node_modules/spark-dev/node_modules/pathwatcher/node_modules/runas/build'
CXX(target) Release/obj.target/runas/src/main.o

make: Leaving directory `/tmp/apm-install-dir-115720-6900-znw1p6/node_modules/spark-dev/node_modules/pathwatcher/node_modules/runas/build'

> serialport@1.6.3 install /tmp/apm-install-dir-115720-6900-znw1p6/node_modules/spark-dev/node_modules/serialport
> node-pre-gyp install --fallback-to-build --runtime=atom-shell

make: Entering directory `/tmp/apm-install-dir-115720-6900-znw1p6/node_modules/spark-dev/node_modules/serialport/build'
  CXX(target) Release/obj.target/serialport/src/serialport.o
make: Leaving directory `/tmp/apm-install-dir-115720-6900-znw1p6/node_modules/spark-dev/node_modules/serialport/build'
Failed to execute 'node-gyp rebuild --name=serialport --configuration=Release --module_name=serialport --version=1.6.3 --major=1 --minor=6 --patch=3 --runtime=atom-shell --node_abi=atom-shell-v0.22.0 --target=0.22.0 --platform=linux --target_platform=linux --arch=x64 --target_arch=x64 --module_main=./serialport --host=https://node-serialport.s3.amazonaws.com/ --module_path=/tmp/apm-install-dir-115720-6900-znw1p6/node_modules/spark-dev/node_modules/serialport/build/serialport/v1.6.3/Release/atom-shell-v0.22.0-linux-x64 --module=/tmp/apm-install-dir-115720-6900-znw1p6/node_modules/spark-dev/node_modules/serialport/build/serialport/v1.6.3/Release/atom-shell-v0.22.0-linux-x64/serialport.node --remote_path=./serialport/v1.6.3/Release/ --package_name=atom-shell-v0.22.0-linux-x64.tar.gz --staged_tarball=build/stage/serialport/v1.6.3/Release/atom-shell-v0.22.0-linux-x64.tar.gz --hosted_path=https://node-serialport.s3.amazonaws.com/serialport/v1.6.3/Release/ --hosted_tarball=https://node-serialport.s3.amazonaws.com/serialport/v1.6.3/Release/atom-shell-v0.22.0-linux-x64.tar.gz' (1)

make: g++: Command not found
make: *** [Release/obj.target/runas/src/main.o] Error 127
gyp ERR! build error 
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/usr/share/atom/resources/app/apm/node_modules/npm/node_modules/node-gyp/lib/build.js:267:23)
gyp ERR! stack     at ChildProcess.emit (events.js:98:17)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (child_process.js:820:12)
gyp ERR! System Linux 3.16.0-46-generic
gyp ERR! command "node" "/usr/share/atom/resources/app/apm/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /tmp/apm-install-dir-115720-6900-znw1p6/node_modules/spark-dev/node_modules/pathwatcher/node_modules/runas
gyp ERR! node -v v0.10.35
gyp ERR! node-gyp -v v1.0.2
gyp ERR! not ok 
make: g++: Command not found
make: *** [Release/obj.target/serialport/src/serialport.o] Error 127
gyp ERR! build error 
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/usr/share/atom/resources/app/apm/node_modules/npm/node_modules/node-gyp/lib/build.js:267:23)
gyp ERR! stack     at ChildProcess.emit (events.js:98:17)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (child_process.js:820:12)
gyp ERR! System Linux 3.16.0-46-generic
gyp ERR! command "node" "/usr/share/atom/resources/app/apm/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild" "--name=serialport" "--configuration=Release" "--module_name=serialport" "--version=1.6.3" "--major=1" "--minor=6" "--patch=3" "--runtime=atom-shell" "--node_abi=atom-shell-v0.22.0" "--target=0.22.0" "--platform=linux" "--target_platform=linux" "--arch=x64" "--target_arch=x64" "--module_main=./serialport" "--host=https://node-serialport.s3.amazonaws.com/" "--module_path=/tmp/apm-install-dir-115720-6900-znw1p6/node_modules/spark-dev/node_modules/serialport/build/serialport/v1.6.3/Release/atom-shell-v0.22.0-linux-x64" "--module=/tmp/apm-install-dir-115720-6900-znw1p6/node_modules/spark-dev/node_modules/serialport/build/serialport/v1.6.3/Release/atom-shell-v0.22.0-linux-x64/serialport.node" "--remote_path=./serialport/v1.6.3/Release/" "--package_name=atom-shell-v0.22.0-linux-x64.tar.gz" "--staged_tarball=build/stage/serialport/v1.6.3/Release/atom-shell-v0.22.0-linux-x64.tar.gz" "--hosted_path=https://node-serialport.s3.amazonaws.com/serialport/v1.6.3/Release/" "--hosted_tarball=https://node-serialport.s3.amazonaws.com/serialport/v1.6.3/Release/atom-shell-v0.22.0-linux-x64.tar.gz"
gyp ERR! cwd /tmp/apm-install-dir-115720-6900-znw1p6/node_modules/spark-dev/node_modules/serialport
gyp ERR! node -v v0.10.35
gyp ERR! node-gyp -v v1.0.2
gyp ERR! not ok 
node-pre-gyp ERR! build error 
node-pre-gyp ERR! stack Error: Failed to execute 'node-gyp rebuild --name=serialport --configuration=Release --module_name=serialport --version=1.6.3 --major=1 --minor=6 --patch=3 --runtime=atom-shell --node_abi=atom-shell-v0.22.0 --target=0.22.0 --platform=linux --target_platform=linux --arch=x64 --target_arch=x64 --module_main=./serialport --host=https://node-serialport.s3.amazonaws.com/ --module_path=/tmp/apm-install-dir-115720-6900-znw1p6/node_modules/spark-dev/node_modules/serialport/build/serialport/v1.6.3/Release/atom-shell-v0.22.0-linux-x64 --module=/tmp/apm-install-dir-115720-6900-znw1p6/node_modules/spark-dev/node_modules/serialport/build/serialport/v1.6.3/Release/atom-shell-v0.22.0-linux-x64/serialport.node --remote_path=./serialport/v1.6.3/Release/ --package_name=atom-shell-v0.22.0-linux-x64.tar.gz --staged_tarball=build/stage/serialport/v1.6.3/Release/atom-shell-v0.22.0-linux-x64.tar.gz --hosted_path=https://node-serialport.s3.amazonaws.com/serialport/v1.6.3/Release/ --hosted_tarball=https://node-serialport.s3.amazonaws.com/serialport/v1.6.3/Release/atom-shell-v0.22.0-linux-x64.tar.gz' (1)
node-pre-gyp ERR! stack     at ChildProcess.<anonymous> (/tmp/apm-install-dir-115720-6900-znw1p6/node_modules/spark-dev/node_modules/serialport/node_modules/node-pre-gyp/lib/util/compile.js:76:29)
node-pre-gyp ERR! stack     at ChildProcess.emit (events.js:98:17)
node-pre-gyp ERR! stack     at maybeClose (child_process.js:766:16)
node-pre-gyp ERR! stack     at Process.ChildProcess._handle.onexit (child_process.js:833:5)
node-pre-gyp ERR! System Linux 3.16.0-46-generic
node-pre-gyp ERR! command "node" "/tmp/apm-install-dir-115720-6900-znw1p6/node_modules/spark-dev/node_modules/serialport/node_modules/.bin/node-pre-gyp" "install" "--fallback-to-build" "--runtime=atom-shell"
node-pre-gyp ERR! cwd /tmp/apm-install-dir-115720-6900-znw1p6/node_modules/spark-dev/node_modules/serialport
node-pre-gyp ERR! node -v v0.10.35
node-pre-gyp ERR! node-pre-gyp -v v0.5.26
node-pre-gyp ERR! not ok 
npm ERR! Linux 3.16.0-46-generic
npm ERR! argv "/usr/share/atom/resources/app/apm/bin/node" "/usr/share/atom/resources/app/apm/node_modules/npm/bin/npm-cli.js" "--globalconfig" "/home/meisteg/.atom/.apm/.apmrc" "--userconfig" "/home/meisteg/.atom/.apmrc" "install" "/tmp/d-115720-6900-j8tmbq/package.tgz" "--target=0.22.0" "--arch=x64"
npm ERR! node v0.10.35
npm ERR! npm  v2.5.1
npm ERR! code ELIFECYCLE

npm ERR! runas@2.0.0 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the runas@2.0.0 install script 'node-gyp rebuild'.
npm ERR! This is most likely a problem with the runas package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     node-gyp rebuild
npm ERR! You can get their info via:
npm ERR!     npm owner ls runas
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR!     /tmp/apm-install-dir-115720-6900-znw1p6/npm-debug.log

It looks like you may not have C++ compiler installed. Try:

Ubuntu / Debian

$ sudo apt-get install build-essential

Fedora / CentOS / RHEL

$ sudo dnf --assumeyes install make gcc gcc-c++ glibc-devel

Arch

$ sudo pacman -S --needed gconf base-devel

openSUSE

$ sudo zypper install make gcc gcc-c++ glibc-devel

Thanks @suda! After installing build-essential, I’m up and running now. This is fantastic!

Perhaps this is worth mentioning in the README as well?

2 Likes

Just installed spark-dev module on Atom, got the following in the Incompatible Package window:

Error message: Cannot find module ‘/Users/leo3/.atom/packages/spark-dev/node_modules/serialport/build/serialport/v1.6.3/Release/atom-shell-v0.22.3-darwin-x64/serialport.node’

Particle menu is blank (I’m guess because Spark Dev 0.0.25 stops loading upon error).

OS: Mac OSX 10.10.5
Hardware: Mac Pro (Mid 2012)
Atom: 1.0.7

Reported as issue on github/spark/spark-dev. Happy to provide more info if needed. Any advice would be appreciated! Cheers,

L3

FWIW, after installing spark-dev, there is a folder that is close to the missing path listed above, the only difference being that v0.22.3 is installed as v0.22.0.

I tried changing the name of that directory, but I got a new error saying incompatible file. Will keep digging on this. I must be missing something obvious (to others, at least ;-).

Cheers,
L3

Yeah it’s a bug in apm. Following steps 4 and 5 from Linux installation should help.

Awesome. Did 4 & 5 and it worked like a champ. Appreciate the help, and the great work! I love spark (ahem) particle-dev. Cheers, L3

1 Like

Heads up: update to Atom 1.6.0 might be problematic! (at least in Ubuntu 14.04)

In Ubuntu 14.04, I had Atom 1.3.2 and I was able to happily build and flash my photons.
Upgraded to Atom 1.6 and flashing failed every time. However flashing of the same firmware worked fine from https://build.particle.io/build

Removed Atom 1.6.0 and downgraded to Atom 1.3.2 and I’m happily flashing my photons again.

@suda A BIG THANK YOU for allowing me to work local in Ubuntu!!!

On a side note, I never used Atom.io before but since I started using it I like it more and more.

1 Like

Yeah it’s possible modules used for serial port need to be rebuild after upgrade. It should be possible from Incompatible Packages view.

yup, I did rebuild the incompatible packages in 1.6.0 but still no luck so I downgraded to 1.3.2.

thanks!
Gustavo.