Toolchain Flashing Incorrectly

Hello,

I am trying to use libraries that are not already incorporated into the Particle IDE, I am forced to use tool chain gcc-arm local build. I tested out the tool chain using my desired code and it does compile, but it does not run as expected.

The problem:
When I just try to flash a simple Hello World, putting the system on manual mode, the Electron still attempts to connect to the cloud (flashes green) leading me to believe that it is not being flashed the correct code. Can anyone advise me if I am doing something wrong when doing the local build? Or why my electron is still trying to connect to the cloud even though it has been put on manual mode?

This is the exact Hello World that I ran:

#include "Application.h"

SYSTEM_MODE(MANUAL);

void setup(){
    Serial.begin(9600);
    
}

void loop(){
    Serial.println("Hello World!");
    delay(5000);
}

This is exactly how I went about compiling my code:
I have followed all the steps listed in the Particle Docs (running a mac, if that helps) on how to download and use it.
I created a new folder called Hello in /firmware/user/applications and put the code above in a file called application.cpp in this folder.
As described in the http://particle-firmware.readthedocs.io/en/develop/build/, I changed to the main directory and ran make APP=Hello. It appears to compile successfully and I run “particle flash --serial Hello.bin” from the /build/target/main/platform-0-lto/ directory

Nothing is printed out to the screen after running particle serial monitor and the electron flashes green indicating it is trying to connect to the cloud even though I specifically put the system in manual mode.

If you have any advice or can walk me through how you have successfully used the tool chain and flashed the code to your device, your help is much appreciated.

In case it matters, the firmware on the electron is 0.4.8 (from “particle identify”).

Thank you,
Nicole

Actually no, you can use CLI or Particle Dev to use libraries not provided by the Particle libs repository

And

This suggest you have not set the Electron as your target platform (platform 0 is Spark Core).
If you don’t just say, you have done as advised but actually post the build command, we may be able to point you at the exact mistake in that command.
You may think you’ve done as advised and we would imply you’ve done as we understand what needs to be done, but that does not necessarily match up :wink:

If you use particle flash --usb Hello.bin instead, you’ll get a more elaborate error message which would probably have told you about the platform mismatch.

Could you tell me more about the CLI or Particle Dev?

Have you tried using po-util? It’s a tool I made to facilitate local building on macOS and Linux.

You can install po-util using Homebrew.

$ brew tap nrobinson2000/po
$ brew install po
$ po install

CLI: https://www.particle.io/products/development-tools/particle-command-line-interface
Dev: https://www.particle.io/products/development-tools/particle-desktop-ide

There are also guides in the docs
https://docs.particle.io/reference/cli/
https://docs.particle.io/guide/tools-and-features/dev/#getting-started

After this you may ask any further questions not answered by these resources :wink: