Skip to content

Commit 2876ff7

Browse files
authored
update GitHub actions (#19)
- update GitHub actions - update examples - minor edits
1 parent 2d07251 commit 2876ff7

File tree

15 files changed

+86
-63
lines changed

15 files changed

+86
-63
lines changed

.github/workflows/arduino-lint.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ jobs:
66
runs-on: ubuntu-latest
77
timeout-minutes: 5
88
steps:
9-
- uses: actions/checkout@v4
10-
- uses: arduino/arduino-lint-action@v1
9+
- uses: actions/checkout@v5
10+
- uses: arduino/arduino-lint-action@v2
1111
with:
1212
library-manager: update
1313
compliance: strict

.github/workflows/arduino_test_runner.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ jobs:
88
timeout-minutes: 20
99

1010
steps:
11-
- uses: actions/checkout@v4
11+
- uses: actions/checkout@v5
1212
- uses: ruby/setup-ruby@v1
1313
with:
1414
ruby-version: 2.6

.github/workflows/jsoncheck.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,15 @@ on:
55
paths:
66
- '**.json'
77
pull_request:
8+
paths:
9+
- '**.json'
810

911
jobs:
1012
test:
1113
runs-on: ubuntu-latest
1214
timeout-minutes: 5
1315
steps:
14-
- uses: actions/checkout@v4
16+
- uses: actions/checkout@v5
1517
- name: json-syntax-check
1618
uses: limitusus/json-syntax-check@v2
1719
with:

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,11 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/)
66
and this project adheres to [Semantic Versioning](http://semver.org/).
77

88

9+
## [0.4.1] - 2025-10-12
10+
- update GitHub actions
11+
- update examples
12+
- minor edits
13+
914
## [0.4.0] - 2024-09-10
1015
- fix #17, loop unroll option, improving performance, kudos to nt314p
1116
- added flag to select LOOP UNROLL (is optional as it gives larger code size)

FastShiftIn.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
//
22
// FILE: FastShiftIn.cpp
33
// AUTHOR: Rob Tillaart
4-
// VERSION: 0.4.0
4+
// VERSION: 0.4.1
55
// PURPOSE: Fast ShiftIn for 74HC165 register, AVR optimized
66
// DATE: 2013-09-29
77
// URL: https://github.com/RobTillaart/FastShiftIn

FastShiftIn.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
//
33
// FILE: FastShiftIn.h
44
// AUTHOR: Rob Tillaart
5-
// VERSION: 0.4.0
5+
// VERSION: 0.4.1
66
// PURPOSE: Fast ShiftIn for 74HC165 register, AVR optimized
77
// DATE: 2013-09-29
88
// URL: https://github.com/RobTillaart/FastShiftIn
@@ -11,7 +11,7 @@
1111
#include "Arduino.h"
1212

1313

14-
#define FASTSHIFTIN_LIB_VERSION (F("0.4.0"))
14+
#define FASTSHIFTIN_LIB_VERSION (F("0.4.1"))
1515

1616
// uncomment next line to get SPEED OPTIMIZED CODE
1717
// #define FASTSHIFTIN_AVR_LOOP_UNROLLED 1

LICENSE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
MIT License
22

3-
Copyright (c) 2013-2024 Rob Tillaart
3+
Copyright (c) 2013-2025 Rob Tillaart
44

55
Permission is hereby granted, free of charge, to any person obtaining a copy
66
of this software and associated documentation files (the "Software"), to deal

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -163,6 +163,7 @@ pull up resistors, especially if wires are exceeding 10 cm (4").
163163
- performance ESP32
164164
- example schema
165165
- add invert flag?
166+
- value = value ^ 0xFF;
166167
- would it be interesting to make a fastShiftIn16() etc?
167168
- squeeze performance but more maintenance.?
168169

examples/fastShiftIn/fastShiftIn.ino

Lines changed: 12 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -15,13 +15,16 @@ volatile int x = 0;
1515
void setup()
1616
{
1717
Serial.begin(115200);
18-
Serial.println(__FILE__);
18+
Serial.println();
19+
Serial.println(__FILE__);
20+
Serial.println("FASTSHIFTIN_LIB_VERSION: ");
1921
Serial.println(FASTSHIFTIN_LIB_VERSION);
22+
Serial.println();
2023

2124
digitalWrite(12, HIGH);
22-
Serial.println("\n 8 bits HIGH\n");
25+
Serial.println("\n 8 bits HIGH\n");
2326

24-
Serial.println("\nPerformance - time in us");
27+
Serial.println("\nPerformance - time in us");
2528
uint32_t start = micros();
2629
for (int i = 0; i < 1000; i++)
2730
{
@@ -39,9 +42,9 @@ void setup()
3942
}
4043
uint32_t duration2 = micros() - start;
4144
Serial.print("FastShiftIn2: ");
42-
Serial.println(duration2 * 0.001);
45+
Serial.println(duration2 * 0.001f);
4346
Serial.print(" Delta: ");
44-
Serial.println((duration2 - duration1)* 0.001);
47+
Serial.println((duration2 - duration1)* 0.001f);
4548
Serial.println();
4649

4750

@@ -52,7 +55,7 @@ void setup()
5255
}
5356
duration1 = micros() - start;
5457
Serial.print("Standard shiftIn1: ");
55-
Serial.println(duration1* 0.001);
58+
Serial.println(duration1* 0.001f);
5659

5760
start = micros();
5861
for (int i = 0; i < 1000; i++)
@@ -62,9 +65,9 @@ void setup()
6265
}
6366
duration2 = micros() - start;
6467
Serial.print("Standard shiftIn2: ");
65-
Serial.println(duration2 * 0.001);
68+
Serial.println(duration2 * 0.001f);
6669
Serial.print(" Delta: ");
67-
Serial.println((duration2 - duration1) * 0.001);
70+
Serial.println((duration2 - duration1) * 0.001f);
6871
Serial.println();
6972

7073
Serial.println("done...");
@@ -76,5 +79,5 @@ void loop()
7679
}
7780

7881

79-
// -- END OF FILE --
82+
// -- END OF FILE --
8083

examples/fastShiftIn_readLSBFIRST/fastShiftIn_readLSBFIRST.ino

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,11 @@ volatile int x = 0;
1515
void setup()
1616
{
1717
Serial.begin(115200);
18+
Serial.println();
1819
Serial.println(__FILE__);
20+
Serial.println("FASTSHIFTIN_LIB_VERSION: ");
1921
Serial.println(FASTSHIFTIN_LIB_VERSION);
22+
Serial.println();
2023

2124
digitalWrite(12, HIGH);
2225
Serial.println("\n 8 bits HIGH - readLSBFIRST\n");
@@ -29,7 +32,7 @@ void setup()
2932
}
3033
uint32_t duration1 = micros() - start;
3134
Serial.print("FastShiftIn1: ");
32-
Serial.println(duration1 * 0.001);
35+
Serial.println(duration1 * 0.001f);
3336

3437
start = micros();
3538
for (int i = 0; i < 1000; i++)
@@ -39,9 +42,9 @@ void setup()
3942
}
4043
uint32_t duration2 = micros() - start;
4144
Serial.print("FastShiftIn2: ");
42-
Serial.println(duration2 * 0.001);
45+
Serial.println(duration2 * 0.001f);
4346
Serial.print(" Delta: ");
44-
Serial.println((duration2 - duration1) * 0.001);
47+
Serial.println((duration2 - duration1) * 0.001f);
4548
Serial.println();
4649

4750

@@ -52,7 +55,7 @@ void setup()
5255
}
5356
duration1 = micros() - start;
5457
Serial.print("Standard shiftIn1: ");
55-
Serial.println(duration1 * 0.001);
58+
Serial.println(duration1 * 0.001f);
5659

5760
start = micros();
5861
for (int i = 0; i < 1000; i++)
@@ -62,9 +65,9 @@ void setup()
6265
}
6366
duration2 = micros() - start;
6467
Serial.print("Standard shiftIn2: ");
65-
Serial.println(duration2 * 0.001);
68+
Serial.println(duration2 * 0.001f);
6669
Serial.print(" Delta: ");
67-
Serial.println((duration2 - duration1) * 0.001);
70+
Serial.println((duration2 - duration1) * 0.001f);
6871
Serial.println();
6972

7073
Serial.println("done...");
@@ -76,4 +79,4 @@ void loop()
7679
}
7780

7881

79-
// -- END OF FILE --
82+
// -- END OF FILE --

0 commit comments

Comments
 (0)