Debugging Particle on Windows (HELP)!

It looks like it’s working. If you type c then return, it should resume executing.

This might be a very noob question but its not really like debugging in vs. How do i make this work in netbeans or eclipse. I have toolchain setup and i have been using mostly netbeans to locally develop the firmware. Can it be setup so that i can pause, run code and put breakpoints and then view what values the breakpoints have like when debugging other c++ programs?

That’s why I said you should wait for a week or two until the tutorial is ready! It will only be a matter of days now, maybe by the end of this week or the beginning of next week.


I understand !! I will wait. Thank you for helping me out.

Any updates on this??

The document was done last week; it’s currently in review. Should be published this week.


looking forward to it!!

Any updates on when this document will be released?

I don’t know, but for now I put up the draft version of it:

1 Like


Great work on the debugging instructions. I somehow get a USB device disconnected error though. I can still continue debugging but cannot call functions using the console. I am using the particle debugger connected to 2 USB cables.And how do I get code assistance to work. Netbeans just searches the build directory to make this work.

Thanks! It doesn’t surprise me that the USB would be detected as having been disconnected if you’re stopped in the debugger for any length of time. I’m not even sure if it’s possible to work around that, but I put it on my list to investigate. I plan on adding the ability to have the rest of code assistance working at some point in time. You need to tell Eclipse where the system firmware is; that gets you almost all of the way there, but I’m having trouble getting getting Code Analyzer to recognize that it’s supposed to be in C++11 mode so it has trouble dealing with things like uint16_t.

I will include the firmware path and then try instructions mentioned here

Will let you know how it went.

A question though if it says USB disconnected how does it pass a particle function to the mcu as you’ve mentioned in your instructions.

I have been playing around with the command line debugger on a 68hc12 so have a more basic understanding of how gdb works.

Update(For making code assistance work):-

  1. In project settings/Paths and symbols/Source Location/
    Press Link Folder and link to the folder that holds the firmware

  2. In project settings/Preprocessor Include Paths,Macros etc/
    Click on CDT GCC Built in Compiler Settings Cross ARM
    replace ${COMMAND} with arm-none-eabi-gcc

Code analysis now works without any errors on stdint.h

Thank you again @rickkas7 for the awesome tutorial.

How do i make the makefile include subfolders in the same directory when building. Currently it only looks in the root of the APPDIR?

That’s odd. I use that setup to build projects with libraries in subdirectories all the time and it works for me. Can you include the Make output?

No it works fine. I had my include path wrong. Actually i am trying to have make look one level below so i can keep the libraries i am using in their own folders. How can i build using APPDIR and add other directories to look for files to compile?

I don’t know if there’s a way you can pass options to the Makefile to do that. However the make process does follow symbolic links (ln -s), so at least on Mac and Linux you can link both directories and individual files under APPDIR and they will be built. I use that technique frequently with libraries shared between projects.

I am using Cygwin to build. I will try using symbolic links with Cygwin paths and see if it works. So if I have a folder A that contains my .h and .cpp and I want to include files from folder A in folder B which is at the same level and contains my main and the makefile what would the APPDIR variable look like

ln -s path/to/B path/to/A rest of the path?


Run mklink /D {taget} {source}