I seem to be having trouble with the particle-cli again.
I’ve had head banging sessions in the past but for the last year or so its been fine. I have it installed on my windows 7 laptop, and after my last problems I discovered that I had multiple over installations which appead to be the casse of my problems. So I uninstalled it both using the installer and the command line prompt. Installed it via the windows installer and everything seem stable.
Then a few weeks ago, I was using the command line to set up a core, which it had been succesfull at doing when I was prompted that a new version of the cli was available and to update it with npm -g particle-cli upgrade, for something very similar, OK I thought and gave it a go. Which was a mistake becasue then, when ever I ran it it would complain that it needed node 4.4. So I upgraded node to 8 (something) and then the CLI just started messing me around all over again. So I uninstalled the CLI, with the installer, only to find particle still present on the command line, did a command line uninstall and once I thought I had rid of it, reinstalled it with the installer. Everything seemed to go fine, I could run particle without a prompt to undate.
But now I am trying to set up a 1st gen core.
I can use particle setup, to set up the wifi, and strangely it is not asking for the security type, just the SSID and password. It can been seen on the console devices screen going on and offline. its breathing blue, it reacts to the rainbow command. I can not flash to it.
I have tried using particle doctor, but it fails after updating cc3000 firmware, applying update, then doctor didn’t complete sucesfully. this.promptDfd is not a function.
my current particle version is 1.28.2 and Node version 8,10.0
Despite the instructions to the contrary, you should never update the Windows Particle CLI installed with the Particle CLI installer using npm install -g particle-cli (or npm update). The Windows CLI will update itself when needed now.
To get out of this, uninstall the manual install again:
! A newer version (1.28.2) of particle-cli is available.
! Upgrade now by running: npm install -g particle-cli
1.27.0
C:\Users\Cyber>particle setup
So clearly I'm not going to update my desktop, unitl I can figure out why my laptop got all hissy-fitty with trying to upgrade the cli. All I did was run the suggested command line npm install -g particle-cli, and then it got nasty about the node version I was using, demanding node 4.4. after finally upgrading node to version 8 it started going wrong, forcing me in to uninstalling the cli both via the program manager, and becasue it was still there, the command line uninstall.
Thinking I was all clear I reinstalled via the program manager and now its really not playing ball. When I do get the core online via the laptop, it keeps goiong on and offline every 20 second or so.
As I have managed to get it working using an older install of my desktop surely it must be something in the laptop installation. And clearly casued by something uninstalling both the command line way and the program manager way failed to resolve.
Still scratching my head but I'll try again tomorrow at work.
Hi, Hopefully someone will pick up on this old thread, but I've just had some time to return to the problem.
OK, my main problem started when I got a message on my cli advising me to update it with using the :- npm install -g particle-cli command.
Well like a good chap I did and it turns out I was wrong and should have used 'particle update-cli'
Will I have tried it, and I get a report back that there is nothing to update. But I am still having problems when I run the particle doctor command is get:-
Flash success!
Applying update...
Wait until the device stops blinking magenta and starts blinking yellow
The Doctor didn't complete sucesfully. this.promptDfd is not a function
Please visit our community forums for help with this error:
And my device is stuck flashing yellowy/green,
I'm able to recover my device using particle doctor on an other machine so I'm not tearing my hair out but I would like to get my laptop working again.
Basically its a win 7 machine. I have tried uninstalling it and reinstalling it using the windows installer.
Using
npm ls
Shows there is no other npm packages installed
I get
C:\Users\Liam>particle --version
1.29.0
And attempts to repair the install using
C:\Users\Liam>particle update-cli
Updating CLI... no plugins to update.
So I am at a loss now. I thought I have learnt uninstalling and reinstalling particle CLI to a tee now, but its got me beat.
Any idea what is causing the
this.promptDfd is not a function
So I can try and find a solution? Any help appreciated.
I think you’re still picking up the wrong CLI install. Do a file search for particle. The correct installation location after using the Particle CLI installer is of the form:
C:\Users\username\AppData\Local\particle
If you’re finding one in a node directory, then the wrong one is being used.
I think I am going to have to uninstall the CLI yet again and uninstall node as well. Any thing else anyone can suggest I should do my best to uninstall as well?
OK I’ve tried, and tried, and tried again to fix a problem with a fault that occured with the CLI after following the instrustions when prompted by the CLI to upgrade to a newer version.
Apparently I was not supposed to use ‘npm install -g particle-cli’ but I did, becasue thats what the prompt TOLD me to do.
Anyway, I have tried uninstalling the CLI, both manually and using the installer I have also removed node js. To the best of my knowlage I have removed both node and the particle cli, and any referance I can find to them and reinstalled using the windows installer. I now have Version 1.29.0
However I still keep getting the SAME error when running the particle doctor, after Updateing the CC3000 firmware, continue when the device blinks yellow, Flash success, Applying the update, wait until device stops blinking magenta, and starts blinking Yellow. The doctor didn’t complete sucesfully. this.promptDfd is not a function.
and at that point the routine stops and drops back to the command line.
So the only thing I can think of for now is to force my laptop back to the state it was in before which means version 1.27.0. But everytime I run the installer it keeps trying to install the latest version which is the only varible I can not control.
Is there still a means of installing version 1.27.0?
If the CLI is working except for the device doctor, another question to ask would be for what reason do you need to use the device doctor? It’s just a front-end in front of other CLI commands, so if you have a specific problem you need to solve - like bad keys - I can just give you the command to fix that instead.
It is possible to roll back the Particle CLI version, however this will have the side effect of rolling back the version of system firmware installed by particle update, so this isn’t usually a good solution.
As far as I can tell, most of the rest of the CLI functions are working. I’ve specifically tried List, Help and Monitor.
As far as I know I don’t have a problem with my keys. I can get the device working again by simply running particle doctor on my desk top PC which is running CLI 1.27.0. The problem is with the laptop, which is handy to have working as I am often setting up cores and photons at work, the London Hackspace, home or my mothers. All have different wi-fi routers and such like so if I have a problem with particle setup not working, a particle doctor gets it going again and away I go.
If you get fast blinking cyan followed by one or more red or orange blinks and you can never get to breathing cyan, you may have a keys problem. However, in this case you probably don’t.
You should just be able to restore default user firmware:
In DFU mode (blinking yellow):
particle flash --usb tinker
Then reconfigure Wi-Fi in blinking dark blue (listening mode):
particle serial wifi
instead of using particle setup and you should be able to get online.
I want to reuse my Core and having the same problem that Liam, just did the flash tinker and with the wifi, it stays at flashing green.
I try first in a mac OS, and now in a PC (win10) and it is exactly the same
I want to reuse my Core and having the same problem that Liam, just did the flash tinker and with the wifi, it stays at flashing green.
To fix that on a Spark Core only (not a Photon, P1, Electron, etc.):
Put the Core in DFU mode by holding down both the RST and MODE buttons, releasing RST and continuing to hold down MODE until it blinks yellow and issue the commands below, in order.
After completing some of the steps the color may change to something else; if so note what color/pattern it is, then use the button combination to get back to blinking yellow. The core should be blinking yellow before each of the commands listed below is entered.
Then put the Core in listening mode (blinking blue) if not already in that state by pressing and releasing RST. Then holding down MODE until it blinks dark blue. Then issue the command:
particle serial wifi
The normal sequence is white, blinking green, blinking cyan (light blue), fast blinking cyan, and finally breathing cyan. If you don't get all the way to breathing cyan, copy and paste the full output from all the commands and submit them as a support ticket.
@peekay123 when I did run particle update-cli it told me to run npm, hence the laughter . It looks like my windows install is up-to-date it just doesn't seem to know it.
@rocksetta, I wonder if you have left-overs from an older npm install on your system. When I run particle update-cli is does the update or indicates that there no no packages to update.