Mod edit (@harrisonhjones): Solution: “I install dfu-util via homebrew and then ran particle update… now it is breathing cyan. Thank you!”
I flashed the following code to the electron via product console.
PRODUCT_ID(hidden_from_forum);
PRODUCT_VERSION(hidden_from_forum);
int led = D6; // LED is connected to D0
int pushButton = D5; // Push button is connected to D2
// This routine runs only once upon reset
void setup()
{
pinMode(led, OUTPUT); // Initialize D0 pin as output
pinMode(pushButton, INPUT_PULLUP);
// Initialize D2 pin as input with an internal pull-up resistor
}
// This routine loops forever
void loop()
{
int pushButtonState;
pushButtonState = digitalRead(pushButton);
if(pushButtonState == LOW){ //If we push down on the push button
digitalWrite(led, HIGH); // Turn ON the LED
Particle.publish("mumson", PRIVATE);
// Add a delay to prevent getting tons of emails from IFTTT
delay(5000);
}
else
{
digitalWrite(led, LOW); // Turn OFF the LED
}
}
Since I don’t have a device paired to my dev account, I had to compile an .ino file through the particle cli.
I created an empty .ino file with the code, then did particle electron compile
This succeeded in being uploaded to the cloud and was flashed to the device in the product. But now the electron is blinking red… I don’t know how to fix this… nothing is working. The device cannot go into safe mode, either.