Skip to content

Add conditional compilation flags to reduce compiled binary size. #111

Closed
@SFE-Brudnerd

Description

@SFE-Brudnerd

Problem Statement

Currently, this framework is all or nothing, which can bloat the binary. While this is acceptable for the datalogger product it's currently used in, it makes it difficult to utilize this in future products that may not want to use all the sensors, only some of them.

Proposed Solution

Using some sort of conditional compilation. 2 ideas come to mind to me.

  1. #ifdef guarding inside the device libraries with a configuration file in your application including the appropriate devices. This could take the form of #ifdef (FLX_DEV_ALL || FLX_DEV_ABC123) so there's still an include all option.
  2. Using CMake. I'm not sure how this would work in the context of arduino applications, but arduino cores use it. Would require further thought.

Metadata

Metadata

Assignees

Labels

enhancementNew feature or requesthelp wantedExtra attention is needed

Type

No type

Projects

Status

Done

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions