I know there are similar posts but not like this.
I have 5 Photons and have always managed setup with the iPhone app. But I downloaded a newer version & there was no obvious click to even get to setup (listed my Photon, though). So after teeth gnashing I moved to USB setup. Of course, I had to download particle app. Text copy from Terminal below represents my Nth try (for large N):
$ particle setup (Photon blinking blue)
_ __ _ _ _
| '_ \ __ _ _ __| |_(_) ___| | ___
| |_) |/ _` | '__| __| |/ __| |/ _ \
| __/| (_| | | | |_| | (__| | __/
|_| \__,_|_| \__|_|\___|_|\___|
https://particle.io
> Setup is easy! Let's get started...
> It appears as though you are already logged in as ***
? Would you like to log in with a different account? No
! PROTIP: Hold the MODE/SETUP button on your device until it blinks blue!
! PROTIP: Please make sure you are connected to the internet.
> I have detected a Photon connected via USB.
? Would you like to continue with this one? Yes
! The Photon supports secure Wi-Fi setup. We'll try that first.
! PROTIP: Wireless setup of Photons works like a wizard!
! PROTIP: We will automagically change the Wi-Fi network to which your computer is connected.
! PROTIP: You will lose your connection to the internet periodically.
? Found "Photon-***". Would you like to perform setup on this one now? Yes
! PROTIP: You will need to know the password for your Wi-Fi network (if any) to proceed.
! PROTIP: You can press ctrl + C to quit setup at any time.
! You are still connected to your Photon's Wi-Fi network. Please reconnect to a Wi-Fi network with internet access.
? Have you reconnected to the internet? Yes
> Obtained magical secure claim code.
> Hey! We successfully connected to Photon-***
> Now to configure our precious Photon-***
! PROTIP: If you want to skip scanning, or your network is configured as a
! PROTIP: non-broadcast network, please enter manual mode to proceed...
? Would you like to manually enter your Wi-Fi network configuration? No
â–„ Asking the Photon to scan for nearby Wi-Fi networks...events.js:161
throw er; // Unhandled 'error' event
^
Error: connect ECONNREFUSED 192.168.0.1:****
at Object.exports._errnoException (util.js:1023:11)
at exports._exceptionWithHostPort (util.js:1046:20)
at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1090:14)
=============
So this ends with an error message & dumps me back in the Shell. But perversely, my Photon went to breathing cyan. Why?