So I installed the Particle Dev environment, but am unable to compile the blink LED tutorial. When I select Compile In Cloud, it errors out saying all the I/O variables (D0, D7, HIGH, LOW, OUTPUT) are undefined. What header files are these defined in?
So I found a Blink example on Spark Funâs website which would compile. Iâm not entirely sure what these .ino files are. Is there a decent set of documentation, as https://docs.particle.io/guide/tools-and-features/dev/ is lacking, the link which supposedly describes the difference between ino and c/cpp files links to the Online Store & Shipping Questions article (WTF?).
Wow this IDE is finicky. So I tried modifying SFâs Blink by adding my own .c and .h files. When compiling the IDE says there were no errors, but the bottom of the screen says âbuild didnât produce binary Error: Command faiâŚâ And of course the local compilation button does nothing when pressed.
One thing, have you got the most recent CLI (npm update -g particle-cli).
The old version did only like .CPP files and not .C - you can also try to rename your file to .CPP.
I also try to avoid any file paths containing blanks, since some command line tools tend to not wrap the paths in double quotes breaking the path up into multiple parameters.
The old version did only like .CPP files and not .C - you can also try to rename your file to .CPP.
Well this fixed it, thanks a lot! What a broken tool chain. I did install the particle-cli a couple minutes before I had made that post, so I can only assume it was the latest.
Hi , I am facing the same problem. I have updated the cli and tried to compile an empty project, but could not.have a look please, and see what else should i try.
This screenshot does not look like CLI it rather looks like Particle Dev
If you post a screenshot, could you provide one of the complete application window?
And maybe try selecting a device before you build, so that the IDE knows the target system.
The directory was D:\Example-PhotonDesktopIDE\TryChaChaPoly.ino and it had other .cpp and .h filea as well.
I tried with another example, in which,the directory is D:\Example-PhotonDesktopIDE\RegisteredCloudFunction\Example.ino
and it is the only file in the directoryâŚbut the issue persistsâŚ
The screenshot you provided shows the cyan âdirtyâ spot to the right of the file tap, so there are changes that havenât been saved (commited), but Particle Dev only builds what was saved.
I also see two open .INO tabs, in this case itâs not clear to Dev which one you want to build. Dev does not care what tab youâve got open when you start build, since Dev is merely an Editor and not really an IDE. Building is rather triggered like an external command.
For above reason - it might be couterintuitive thoâ - itâs recommended to open the project folder rather than only a file from the folder, since the external command is aimed to build a complete folder content and not seperate files.