Skip to content

Commit 69ed900

Browse files
authored
Initial commit
0 parents  commit 69ed900

11 files changed

+325
-0
lines changed

.github/add_issue_to_project.yml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
# This action will add your issue to our Product Defect Project
2+
name: Add new issue to main project
3+
4+
on:
5+
issues:
6+
types:
7+
- opened
8+
9+
jobs:
10+
add-to-project:
11+
name: Add issue to project
12+
runs-on: ubuntu-latest
13+
steps:
14+
- uses: actions/add-to-project@main
15+
with:
16+
project-url: https://github.com/orgs/sparkfun/projects/19
17+
github-token: ${{ secrets.DEFECT_ADD_TO_PROJECT }}
18+

.github/cross-compilation.yml

Lines changed: 113 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,113 @@
1+
# Link to Introduction to Arduino Actions:
2+
# https://blog.arduino.cc/2021/04/09/test-your-arduino-projects-with-github-actions/
3+
name: Cross-compilation
4+
5+
on:
6+
- push
7+
#- pull_request
8+
9+
jobs:
10+
compile-sketch:
11+
runs-on: ubuntu-latest
12+
13+
strategy:
14+
fail-fast: false
15+
16+
matrix:
17+
board:
18+
# Uno
19+
# https://github.com/arduino/ArduinoCore-avr/blob/master/boards.txt
20+
- fqbn: arduino:avr:mega
21+
platforms: |
22+
- name: arduino:avr
23+
source-url: https://downloads.arduino.cc/packages/package_index.json
24+
25+
# ESP32
26+
# https://github.com/espressif/arduino-esp32/blob/master/boards.txt
27+
- fqbn: esp32:esp32:esp32
28+
platforms: |
29+
- name: esp32:esp32
30+
source-url: https://raw.githubusercontent.com/espressif/arduino-esp32/gh-pages/package_esp32_index.json
31+
32+
# ESP32-S2
33+
# https://github.com/espressif/arduino-esp32/blob/master/boards.txt
34+
- fqbn: esp32:esp32:esp32s2
35+
platforms: |
36+
- name: esp32:esp32
37+
source-url: https://raw.githubusercontent.com/espressif/arduino-esp32/gh-pages/package_esp32_index.json
38+
39+
# ESP32-C3
40+
# https://github.com/espressif/arduino-esp32/blob/master/boards.txt
41+
- fqbn: esp32:esp32:esp32c3
42+
platforms: |
43+
- name: esp32:esp32
44+
source-url: https://raw.githubusercontent.com/espressif/arduino-esp32/gh-pages/package_esp32_index.json
45+
46+
# Artemis / Apollo3
47+
# https://github.com/sparkfun/Arduino_Apollo3/blob/main/boards.txt
48+
- fqbn: SparkFun:apollo3:sfe_artemis_atp
49+
platforms: |
50+
- name: SparkFun:apollo3
51+
source-url: https://raw.githubusercontent.com/sparkfun/Arduino_Apollo3/master/package_sparkfun_apollo3_index.json
52+
53+
# ESP8266
54+
# https://github.com/esp8266/Arduino/blob/master/boards.txt
55+
- fqbn: esp8266:esp8266:thingdev
56+
platforms: |
57+
- name: esp8266:esp8266
58+
source-url: https://arduino.esp8266.com/stable/package_esp8266com_index.json
59+
60+
# SAMD21
61+
# https://github.com/arduino/ArduinoCore-samd/blob/master/boards.txt
62+
- fqbn: arduino:samd:mkr1000
63+
platforms: |
64+
- name: arduino:samd
65+
# source-url: https://downloads.arduino.cc/packages/package_index.json
66+
67+
# Nano BLE 33 / nRF52840
68+
# https://github.com/arduino/ArduinoCore-mbed/blob/master/boards.txt
69+
- fqbn: arduino:mbed:nano33ble
70+
platforms: |
71+
- name: arduino:mbed
72+
# source-url: https://downloads.arduino.cc/packages/package_index.json
73+
74+
# RP2040
75+
# https://github.com/arduino/ArduinoCore-mbed/blob/master/boards.txt
76+
- fqbn: rp2040:rp2040:sparkfun_promicrorp2040
77+
platforms: |
78+
- name: rp2040:rp2040
79+
source-url: https://github.com/earlephilhower/arduino-pico/releases/download/global/package_rp2040_index.json
80+
81+
# STM32
82+
# https://github.com/arduino/ArduinoCore-mbed/blob/master/boards.txt
83+
- fqbn: STMicroelectronics:stm32:GenF4
84+
platforms: |
85+
- name: STMicroelectronics:stm32
86+
source-url: https://github.com/stm32duino/BoardManagerFiles/raw/main/package_stmicroelectronics_index.json
87+
88+
steps:
89+
- name: Checkout
90+
uses: actions/checkout@v3
91+
92+
- name: Branch name
93+
run: echo running on branch ${GITHUB_REF##*/}
94+
95+
- name: Compile Sketch
96+
uses: arduino/compile-sketches@v1.1.0
97+
with:
98+
platforms: ${{ matrix.board.platforms }}
99+
fqbn: ${{ matrix.board.fqbn }}
100+
libraries: |
101+
- source-path: ./
102+
# Example of additional libraries needed
103+
#- name: Simple FOC
104+
sketch-paths: |
105+
- examples/example1_basic
106+
# TODO: Update the path to the sketch, file suffix not needed
107+
enable-warnings-report: true
108+
enable-deltas-report: true
109+
verbose: true
110+
111+
# outputs:
112+
# report-artifact-name: ${{ steps.report-artifact-name.outputs.report-artifact-name }}
113+

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
.vscode/
2+
.build/

LICENSE.md

Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
SparkFun License Information
2+
============================
3+
4+
SparkFun uses two different licenses for our files — one for hardware and one for code.
5+
6+
Hardware
7+
---------
8+
9+
**SparkFun hardware is released under [Creative Commons Share-alike 4.0 International](http://creativecommons.org/licenses/by-sa/4.0/).**
10+
11+
Note: This is a human-readable summary of (and not a substitute for) the [license](http://creativecommons.org/licenses/by-sa/4.0/legalcode).
12+
13+
You are free to:
14+
15+
Share — copy and redistribute the material in any medium or format
16+
Adapt — remix, transform, and build upon the material
17+
for any purpose, even commercially.
18+
The licensor cannot revoke these freedoms as long as you follow the license terms.
19+
Under the following terms:
20+
21+
Attribution — You must give appropriate credit, provide a link to the license, and indicate if changes were made. You may do so in any reasonable manner, but not in any way that suggests the licensor endorses you or your use.
22+
ShareAlike — If you remix, transform, or build upon the material, you must distribute your contributions under the same license as the original.
23+
No additional restrictions — You may not apply legal terms or technological measures that legally restrict others from doing anything the license permits.
24+
Notices:
25+
26+
You do not have to comply with the license for elements of the material in the public domain or where your use is permitted by an applicable exception or limitation.
27+
No warranties are given. The license may not give you all of the permissions necessary for your intended use. For example, other rights such as publicity, privacy, or moral rights may limit how you use the material.
28+
29+
30+
Code
31+
--------
32+
Library contains code from multiple sources, see top of each file for specific licensing information.
33+
34+
**SparkFun code, firmware, and software is released under the MIT License(http://opensource.org/licenses/MIT).**
35+
36+
The MIT License (MIT)
37+
38+
Copyright (c) 2020 SparkFun Electronics
39+
40+
Permission is hereby granted, free of charge, to any person obtaining a copy
41+
of this software and associated documentation files (the "Software"), to deal
42+
in the Software without restriction, including without limitation the rights
43+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
44+
copies of the Software, and to permit persons to whom the Software is
45+
furnished to do so, subject to the following conditions:
46+
47+
The above copyright notice and this permission notice shall be included in all
48+
copies or substantial portions of the Software.
49+
50+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
51+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
52+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
53+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
54+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
55+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
56+
SOFTWARE.
57+
58+
**Analog Devices, firmware and software is subject to software license agreement. See SLA pdf included with this repo.**
59+
License terms outlines in:
60+
2021-05-20-LWSCADIN1110 Click Thru SLA .pdf

README.md

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
# SparkFun_Template_Arduino_Library
2+
========================================
3+
4+
<table class="table table-hover table-striped table-bordered">
5+
<p> TODO: Add product photos and links </p>
6+
</table>
7+
8+
TODO: Add description of product and library
9+
10+
Repository Contents
11+
-------------------
12+
13+
* **/documents** - Data sheets, additional product information
14+
* **/examples** - Example code
15+
* **/src** - Source code
16+
17+
Documentation
18+
--------------
19+
* **[GitHub Repo](https://github.com/sparkfun/TODO)** - TODO: Update URL and description
20+
* **[Hookup Guide](http://docs.sparkfun.com/TODO/)** - TODO: Update URL and description
21+
22+
License Information
23+
-------------------
24+
25+
This product is _**open source**_!
26+
27+
Please review the LICENSE.md file for license information.
28+
29+
If you have any questions or concerns on licensing, please contact technical support on our [SparkFun forums](https://forum.sparkfun.com/viewforum.php?f=152).
30+
31+
Distributed as-is; no warranty is given.
32+
33+
- Your friends at SparkFun.
34+
35+
_<COLLABORATION CREDIT>_

documents/add_documents_here.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Add any relevant documents to this director (eg. datasheet), and delete this file.
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
// TODO: Add includes as needed
2+
#include "SparkFun_Template_Arduino_Library.h"
3+
4+
// TODO: Change Template
5+
TemplateClass myDevice;
6+
7+
void setup()
8+
{
9+
// Start serial
10+
Serial.begin(115200);
11+
Serial.println("Template Example 1 - Basic Uasge"); // TODO: Update
12+
13+
// TODO: Check return value of begin
14+
myDevice.begin();
15+
16+
// TODO: Add other setup code if needed. Most setup should be done in begin()
17+
}
18+
19+
void loop()
20+
{
21+
// TODO: Demonstrate minimal code needed for basic usage
22+
}

keywords.txt

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
#########################################################
2+
# Syntax Coloring Map for TODO: Add name #
3+
#########################################################
4+
# Class
5+
#########################################################
6+
7+
# TODO: Add this
8+
TemplateClass KEYWORD1
9+
10+
#########################################################
11+
# Methods and Functions
12+
#########################################################
13+
14+
# TODO: Add these
15+
begin KEYWORD2
16+
17+
#########################################################
18+
# Constants
19+
#########################################################
20+
21+
# TODO: Add these
22+
TEMPALTE_CONSTANT LITERAL1
23+
24+
#########################################################
25+
# Structs
26+
#########################################################
27+
28+
# TODO: Add these
29+
template_struct_t LITERAL3

library.properties

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
name=SparkFun Template Arduino Library
2+
version=1.0.0
3+
author=SparkFun Electronics <techsupport@sparkfun.com>
4+
maintainer=SparkFun Electronics <sparkfun.com>
5+
sentence=TODO: Add short description
6+
paragraph=TODO: Add long description
7+
category=TODO: Add category (Sensors, Display, Communication, etc.)
8+
url=TODO: Add URL
9+
architectures=TODO: Add architectures (*, esp32, teensy, stm32, megaavr, etc.)
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
#include "SparkFun_Template_Arduino_Library.h"
2+
3+
TemplateClass::TemplateClass()
4+
{
5+
// TODO: Initialize variables
6+
}
7+
8+
bool TemplateClass::begin()
9+
{
10+
// TODO: Check if device is connected
11+
12+
// TODO: Initialize hardware
13+
14+
// TODO: Return whether successful
15+
return false;
16+
}
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
#pragma once
2+
3+
// TODO: Add includes as needed (e.g. #include <Wire.h>, #include <SPI.h>)
4+
#include "Arduino.h"
5+
6+
// TODO: Add constants
7+
8+
// TODO: Implement class
9+
class TemplateClass
10+
{
11+
public:
12+
/// @brief TODO
13+
TemplateClass();
14+
15+
/// @brief TODO
16+
/// @return TODO
17+
bool begin();
18+
19+
// TODO: Add other methods as needed
20+
};

0 commit comments

Comments
 (0)