Giter Site home page Giter Site logo

sparkfun / sparkfun_toolkit Goto Github PK

View Code? Open in Web Editor NEW
2.0 8.0 0.0 1.82 MB

Toolkit of common functionality for use within SparkFun Libraries

Home Page: https://docs.sparkfun.com/SparkFun_Toolkit/

License: MIT License

C 9.49% C++ 90.51%
arduino-library embedded sparkfun-tutorial

sparkfun_toolkit's Introduction

SparkFun Toolkit Arduino Library

Toolkit Tests Builds GitHub issues GitHub release (with filter) GitHub (Pre-)Release Date Documentation Build

The SparkFun Toolkit provides a common set of core functionality for use across the SparkFun Arduino Driver library. Instead of each device driver library implementing it's own communication layers, error types and design, the SparkFun Toolkit library is used.

Motivation

Often, the same core functionality is implemented with a majority of our Arduino libraries, each implementation providing the same functionality, but implemented differently. The result is solutions that have different quirks, and impossible to maintain/support effectively. The SparkFun Toolkit solves this issue.

The SparkFun Toolkit provides a single implementation of common functionality used in the software developed for SparkFun boards. Initially targeted at the Arduino development environment, the SparkFun Toolkit delivers the following benefits:

  • Use a well-tested and validated implementation
  • Reduce development effort
  • Implement functionality following a common structure
  • Set the foundation for future enhancements - as the capabilities of the toolkit grow, these features become available with little to any implementation effort.

Documentation

The SparkFun Toolkit Development documentation is available here

Installation and Use

To use the SparkFun Toolkit directly, or in library development kit is installable via the Arduino Library Manager - search for SparkFun ToolKit within the Arduino Library Manager to install.

However, for solutions that use the SparkFun Toolkit, it is installed automatically during the Arduino library installation process, by marking the Toolkit as a dependency when publishing your library.

To mark the SparkFun Toolkit as a dependency, add the following line to the library.properties file for your library.

depends=SparkFun Toolkit

Examples

The following Arduino Libraries are making use of the SparkFun Toolkit:

sparkfun_toolkit's People

Contributors

gigapod avatar sfe-brudnerd avatar madisonc-sparkfun avatar edspark avatar sfe-sparkfro avatar bboyho avatar paulzc avatar

Stargazers

LawlessCarrot avatar  avatar

Watchers

Nathan Seidle avatar James Cloos avatar John Trepke avatar  avatar  avatar Bryan Hoff avatar  avatar  avatar

sparkfun_toolkit's Issues

Document the "Platform Neutral" approach to developing libraries using the toolkit.

Document and create examples (or point to existing libraries) that outline the design pattern the Toolkit library is intended for.

This overview document includes:

  • Creating a C++ core for a library, that uses the Toolkit
  • How the core is leveraged to implement an Arduino solution
  • Examples of using this core library approach across different platforms, or bus types.

Description: Create a library of common entitles/functionality for use across other SparkFun Libraries/Applications

Description

Design, develop and implement a foundational software library that implements support for common, embedded functionality. This library is intended to be a core foundational block for SparkFun software implementations, enabling the use of a single, well tested solution across all products. Today, for common capabilities, each new library implements its own version of the functionality – a option that is error prone and difficult to maintain. With a “toolkit” library, only one, well tested and validated implementation is used across all our solutions. Additionally, updates to the toolkit library are rapidly integrated into existing solution updates.

The key premise that makes this toolkit library possible, is the library dependency functionally supported by the development environments the library is used within. For example, when building a new SparkFun Arduino Library, the new library can mark the SparkFun Toolkit library as a dependency.

While the initial focus of this library is communication bus architectures, the capabilities of this library will expand over time to deliver a wide variety of capabilities.

Initial Focus - Communication Bus Functionality

The library is designed to deliver a common communication bus interface, that is shared across the various bus types supported. This common interface enables the implementation of capabilities, with little need to understand the underlying details of the bus architecture, or even which type of bus is being used.

This implementation should support the following communication bus types:

  • I2C
  • SPI
  • UART/Serial

While the setup of each bus is different (initialization and definition), the data communication interface is the same, enabling common functionality use across different bus architectures

Use Scenarios

The general use case/scenario for the communication bus implementation of the Foundation library is:

  • An Arduino Library developer includes the SparkFun Foundation library.
  • The SparkFun Foundation library is marked as dependency, ensuring Arduino will install it automatically.
  • The core functionality of the new library uses the common communication interface provided. Read and write operations are performed using methods on this common interface.
  • The design of the library decouples the use of the bus implementation, from the creation of the bus specific object. This enables rapid creation of bus type specific solutions that all use the same core functionality.

Target Personas/Users

  • Arduino library developers
  • Internal SparkFun developers/employees

Key Functionality

  • Presents communication bus interfaces using a single, common interface.
  • C++ Implementation, with platform specific components (i.e. Arduino) provided, but part of the core architecture
  • Initial platform is Arduino.

Design Considerations

  • The foundation library functionality isolated using a C++ namespace.
  • Focus on Arduino initially.
  • Once a core implementation is available, test across a variety of existing SparkFun libraries to validate the implementation.
    • Once launched and available to the Arduino environment, these test libraries shall be updated to use the Foundation library.

Note that the implementation should follow the pattern delivered as part of these libraries:

Documentation

Delivered using GitHub Pages, the documentation should include:

  • Design overview and diagrams
  • Use examples.
  • API Documentation

Product Launch

Once launched and in use internally, the launch shall be marked via a SparkFun blog post. The intent is for internal use, but there's nothing to prevent external use of this library

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.