# Boron Cloud Compile fails, local succeeds

**URL:** <https://community.particle.io/t/boron-cloud-compile-fails-local-succeeds/67025>\
**Category:** Developer Tools\
**Created:** [June 16, 2024, 12:05am UTC](https://community.particle.io/t/boron-cloud-compile-fails-local-succeeds/67025 "2024-06-16T00:05:34Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![colemanjj](https://sea2.discourse-cdn.com/flex026/user_avatar/community.particle.io/colemanjj/32/23436_2.png) [@colemanjj](https://community.particle.io/u/colemanjj)\
**Post date:** [June 16, 2024, 12:05am UTC](https://community.particle.io/t/boron-cloud-compile-fails-local-succeeds/67025/1 "2024-06-16T00:05:34Z")

</div>

Boron program compiles locally and runs fine and very similar program for Electron compiles both locally and in cloud. But when I try to compile the Boron program in the cloud I get errors that start with:

```auto
In file included from lib/SparkIntervalTimer/src/SparkIntervalTimer.cpp:24:
lib/SparkIntervalTimer/src/SparkIntervalTimer.h:37:4: error: #error " ***PARTICLE device not supported by this library. PLATFORM should be Core or Photon***"
   37 | #error " ***PARTICLE device not supported by this library. PLATFORM should be Core or Photon***"
      | ^ ~~~~
lib/SparkIntervalTimer/src/SparkIntervalTimer.cpp:110:4: error: #error " ***PARTICLE device not supported by this library. PLATFORM should be Core or Photon***"
  110 | #error " ***PARTICLE device not supported by this library. PLATFORM should be Core or Photon***"
      | ^ ~~~~

```

Trying to compile Boron device with target Platform Boron and deviceOS@5.5.0  
Using Particle Workbench in Visual Studio Code.  
I haven't modified lib files locally or anything like that.  
I did a particle Clean Application (local) with no effect.  
Hints on where to look for a solution much appreciated.  
john

---

<div class="post-metadata">

**Author:** ![ScruffR](https://sea2.discourse-cdn.com/flex026/user_avatar/community.particle.io/scruffr/32/6952_2.png) [@ScruffR](https://community.particle.io/u/ScruffR)\
**Post date:** [June 16, 2024, 6:19am UTC](https://community.particle.io/t/boron-cloud-compile-fails-local-succeeds/67025/2 "2024-06-16T06:19:21Z")

</div>

It shouldn't compile locally either since SparkIntervalTimer is really not supported due to HW limitations.

---

<div class="post-metadata">

**Author:** ![colemanjj](https://sea2.discourse-cdn.com/flex026/user_avatar/community.particle.io/colemanjj/32/23436_2.png) [@colemanjj](https://community.particle.io/u/colemanjj)\
**Post date:** [June 16, 2024, 12:40pm UTC](https://community.particle.io/t/boron-cloud-compile-fails-local-succeeds/67025/3 "2024-06-16T12:40:43Z")

</div>

What is SparkIntervalTimer used for? I don't call it, at least not directly.

---

<div class="post-metadata">

**Author:** ![ScruffR](https://sea2.discourse-cdn.com/flex026/user_avatar/community.particle.io/scruffr/32/6952_2.png) [@ScruffR](https://community.particle.io/u/ScruffR)\
**Post date:** [June 16, 2024, 12:48pm UTC](https://community.particle.io/t/boron-cloud-compile-fails-local-succeeds/67025/4 "2024-06-16T12:48:28Z")

</div>

It's a library that allows to generate precise, relatively high frequency interrupts by facilitating the hardware timers of the STM32 chips used on Gen1 and 2 of Particle devices.

Some other libraries (e.g. RGBMatrixPanel, ParticleSoftSerial, ...) use it to control their time critical tasks.

So chances are that some of the libraries your project employs use SparkIntervalTimer internally.

---

<div class="post-metadata">

**Author:** ![colemanjj](https://sea2.discourse-cdn.com/flex026/user_avatar/community.particle.io/colemanjj/32/23436_2.png) [@colemanjj](https://community.particle.io/u/colemanjj)\
**Post date:** [June 16, 2024, 1:33pm UTC](https://community.particle.io/t/boron-cloud-compile-fails-local-succeeds/67025/5 "2024-06-16T13:33:35Z")

</div>

Thanks for the info. I don't pretend to understand the cloud compile very well but this would seem to suggest that my local libraries are compatible with Boron (i.e. do not call SparkIntervalTimer) but that the cloud based libraries are not compatible with Boron. Does that make sense?  
I'm using local libraries:  
#include \<Ubidots.h\> //Ubidots 3.2.3 [verified] 247781 Ubidots library for Particle devices  
#include \<CE\_BME280.h\> //CE\_BME280 1.0.1 18445 Control Everything BME280 Library  
I could switch the local libraries I'm using, at least the BME one, but since it's a cloud compile problem would that help?

---

<div class="post-metadata">

**Author:** ![ScruffR](https://sea2.discourse-cdn.com/flex026/user_avatar/community.particle.io/scruffr/32/6952_2.png) [@ScruffR](https://community.particle.io/u/ScruffR)\
**Post date:** [June 16, 2024, 2:21pm UTC](https://community.particle.io/t/boron-cloud-compile-fails-local-succeeds/67025/6 "2024-06-16T14:21:17Z")

</div>

Have you tried to run a search for `SparkIntervalTimer` in your project folder?  
You may still have a copy of this library (or any library using it) in there that may result in this error, even when they are not used.

The compiler cannot know whether any module it finds in the project will be needed or not. Hence all present modules will be compiled just in case - if they are not, the linker will just not link them in.

For cloud compile you may also need to consider the dependencies stated in the `project.properties` and `library.properties` files.

For more targeted advice we'd need to know more about your project structure.  
e.g. posting a directory tree showing all folders and files of that particular project.

---

<div class="post-metadata">

**Author:** ![colemanjj](https://sea2.discourse-cdn.com/flex026/user_avatar/community.particle.io/colemanjj/32/23436_2.png) [@colemanjj](https://community.particle.io/u/colemanjj)\
**Post date:** [June 16, 2024, 4:08pm UTC](https://community.particle.io/t/boron-cloud-compile-fails-local-succeeds/67025/7 "2024-06-16T16:08:06Z")

</div>

Yes! I had an unused library listed in the project.properties file. When I did particle find library for that library. It returned: "ParticleSoftSerial 0.0.15 92478 Basic SoftSerial implementation (requires SparkIntervalTimer library to work)". Once I removed ParticleSoftSerial from the project.properties file the program successfully cloud compiled. Thanks a ton.  
Two followup questions:

1. How do I keep the dependencies listed in project.properties file consistent with the libraries I have locally installed and #include in my program. I often see libraries that are either in my project and not listed in the project.properties file, or the other way around.
2. How do I remove a local library so that it doesn't clutter up my project? There is "Particle install library" but no "Particle remove library". Can I just delete the library from the project directory and from the project.properties file? or is there a better way.  
john

---

<div class="post-metadata">

**Author:** ![ScruffR](https://sea2.discourse-cdn.com/flex026/user_avatar/community.particle.io/scruffr/32/6952_2.png) [@ScruffR](https://community.particle.io/u/ScruffR)\
**Post date:** [June 16, 2024, 6:05pm UTC](https://community.particle.io/t/boron-cloud-compile-fails-local-succeeds/67025/8 "2024-06-16T18:05:17Z")

</div>

`Particle install library` will download the sources _and_ add dependencies.  
If there is now dependencies entry in `project.properties` but the sources are installed in the `lib` folder then these sources will be uploaded to the build farm for remote building.

When you want to tweak a library to suite your particular needs, you need to disable the dependencies entry (e.g. by adding a leading `#` symbol as first letter in that line) so that the cloud compile doesn't use the stock sources but use your local copy instead.

To remove a library it's OK to just delete the respective subdirectory and the dependencies entry from `project.properties`.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex026/uploads/particle/original/3X/3/2/3291e3c9351789fe8620ae5bcec8d3fec67ff221.png) [@system](https://community.particle.io/u/system)\
**Post date:** [July 17, 2024, 4:05am UTC](https://community.particle.io/t/boron-cloud-compile-fails-local-succeeds/67025/9 "2024-07-17T04:05:32Z")

</div>

Closed on July 17, 2024, 4:05am UTC

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
