Skip to content
This repository was archived by the owner on Mar 25, 2021. It is now read-only.

Commit 36689f3

Browse files
author
James Foster
authored
Add Devices directory with stub of LiquidCrystal_TC (#6)
Add LiquidCrystal_TC stub class and devices directory.
1 parent 40740bb commit 36689f3

File tree

9 files changed

+53
-16
lines changed

9 files changed

+53
-16
lines changed

.arduino-ci.yml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,15 +8,18 @@ platforms:
88
features:
99
defines:
1010
- __AVR_ATmega2560__
11-
# added this line
1211
- ARDUINO_CI
1312
warnings:
1413
flags:
1514

1615
unittest:
1716
platforms:
1817
- mega2560
19-
18+
libraries:
19+
- "LiquidCrystal"
20+
2021
compile:
2122
platforms:
2223
- mega2560
24+
libraries:
25+
- "LiquidCrystal"

.github/workflows/Arduino-CI.yaml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,11 @@ jobs:
2020
- run: |
2121
bundle install
2222
23+
# Installing libraries needed for this project
24+
- name: Install libraries
25+
run: |
26+
./scripts/install_libraries.sh
27+
2328
# Finally, run the tests
2429
- run: |
25-
bundle exec arduino_ci_remote.rb --skip-compilation
30+
bundle exec arduino_ci_remote.rb

Gemfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
source 'https://rubygems.org'
2-
gem 'arduino_ci'
2+
gem 'arduino_ci', git: 'https://github.com/ianfixes/arduino_ci.git', branch: '2020-10-16_suggestions'

examples/Blink/Blink.ino

Lines changed: 0 additions & 10 deletions
This file was deleted.
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
2+
#include "TankControllerLib.h"
3+
TankControllerLib *tank = TankControllerLib::instance();
4+
5+
void setup() {
6+
tank->setup();
7+
}
8+
void loop() {
9+
tank->loop();
10+
}

library.properties

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,6 @@ author=James Foster <[email protected]>
44
maintainer=James Foster <[email protected]>
55
sentence=Software for the Arduino that controls pH and temperature in the Ocean Acidification project.
66
paragraph=
7-
category=Device Congtrol
7+
category=Device Control
88
url=https://github.com/Open-Acidification/TankControllerLib
9-
architectures=*
9+
architectures=avr

scripts/install_libraries.sh

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
#!/bin/bash
2+
3+
# set up directories
4+
bundle exec ensure_arduino_installation.rb
5+
6+
# get custom version of LiquidCrystal
7+
git clone https://github.com/Arduino-CI/LiquidCrystal.git
8+
mv LiquidCrystal $(bundle exec arduino_library_location.rb)
9+

src/Devices/LiquidCrystal_TC.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
#include "LiquidCrystal_TC.h"

src/Devices/LiquidCrystal_TC.h

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
#include <Arduino.h>
2+
#ifdef ARDUINO_CI
3+
#include <LiquidCrystal_CI.h>
4+
#else
5+
#include <LiquidCrystal.h>
6+
#endif
7+
8+
class LiquidCrystal_TC {
9+
private:
10+
const int RS = 24, EN = 22, D4 = 26, D5 = 28, D6 = 30, D7 = 32;
11+
LiquidCrystal* pLCD; // (RS, EN, D4, D5, D6, D7);
12+
13+
public:
14+
LiquidCrystal_TC();
15+
~LiquidCrystal_TC();
16+
void clear();
17+
void setCursor();
18+
void print();
19+
};

0 commit comments

Comments
 (0)