0.1.9 PinInGroup

This commit is contained in:
Rob Tillaart 2023-11-15 11:50:44 +01:00
parent 7fdd4fab98
commit d80140f4ec
6 changed files with 43 additions and 18 deletions

View File

@ -6,6 +6,10 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/)
and this project adheres to [Semantic Versioning](http://semver.org/).
## [0.1.9] - 2023-11-15
- update readme.md
## [0.1.8] - 2022-11-22
- add changelog.md
- add RP2040 in build
@ -14,8 +18,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
- update unit test
- add PININGROUP_ERROR_PIN
## [0.1.7] - 2022-08-04
## [0.1.7] - 2022-08-04
- fix getIdx() to fix build-CI.
## [0.1.6] - 2021-12-23
@ -23,7 +26,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
- update license
- minor edits.
## [0.1.5] - 2021-11-12
## [0.1.5] - 2021-11-12
- update build-CI
- update readme, badges
- rename variables for readability,
@ -43,7 +46,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
## [0.1.1] - 2020-05-19
- refactor
- add clear()
- add param for INPUT or INPUT_PULLUP
- add parameter for INPUT or INPUT_PULLUP
## [0.1.0] - 2017-08-20
- initial version (based upon pinGroup)

View File

@ -1,7 +1,7 @@
//
// FILE: PinInGroup.cpp
// AUTHOR: Rob Tillaart
// VERSION: 0.1.8
// VERSION: 0.1.9
// DATE: 2017-04-26
// PURPOSE: PinInGroup library for Arduino
// goal is to easily read a group of pins that logically

View File

@ -1,7 +1,7 @@
#pragma once
// FILE: PinInGroup.h
// AUTHOR: Rob dot Tillaart at gmail dot com
// VERSION: 0.1.8
// AUTHOR: Rob Tillaart
// VERSION: 0.1.9
// DATE: 2017-04-26
// PURPOSE: PinInGroup library for Arduino
//
@ -12,7 +12,7 @@
#include "Arduino.h"
#define PININGROUP_LIB_VERSION (F("0.1.8"))
#define PININGROUP_LIB_VERSION (F("0.1.9"))
// smaller MAXSIZE will reduce memory footprint with ditto bytes.

View File

@ -2,8 +2,11 @@
[![Arduino CI](https://github.com/RobTillaart/PinInGroup/workflows/Arduino%20CI/badge.svg)](https://github.com/marketplace/actions/arduino_ci)
[![Arduino-lint](https://github.com/RobTillaart/PinInGroup/actions/workflows/arduino-lint.yml/badge.svg)](https://github.com/RobTillaart/PinInGroup/actions/workflows/arduino-lint.yml)
[![JSON check](https://github.com/RobTillaart/PinInGroup/actions/workflows/jsoncheck.yml/badge.svg)](https://github.com/RobTillaart/PinInGroup/actions/workflows/jsoncheck.yml)
[![GitHub issues](https://img.shields.io/github/issues/RobTillaart/PinInGroup.svg)](https://github.com/RobTillaart/PinInGroup/issues)
[![License: MIT](https://img.shields.io/badge/license-MIT-green.svg)](https://github.com/RobTillaart/PinInGroup/blob/master/LICENSE)
[![GitHub release](https://img.shields.io/github/release/RobTillaart/PinInGroup.svg?maxAge=3600)](https://github.com/RobTillaart/PinInGroup/releases)
[![PlatformIO Registry](https://badges.registry.platformio.org/packages/robtillaart/library/PinInGroup.svg)](https://registry.platformio.org/libraries/robtillaart/PinInGroup)
# PinInGroup
@ -26,6 +29,11 @@ This allows you to check that state of e.g. a parallel bus has not changed durin
Default **PININGROUP_MAXSIZE** = 16.
#### Related
- https://github.com/RobTillaart/PinOutGroup
## Performance
The PinInGroup is not more efficient as reading the pins in a loop yourself.
@ -38,11 +46,15 @@ This is platform, group size and pin state dependent.
## Interface
```cpp
#include "PinInGroup.h"
```
### Constructor
- **PinInGroup()** Constructor.
### Administration
- **void clear()** sets the size to zero so one can repopulate.
@ -74,7 +86,7 @@ Returns 0 or 1 if OK and 0xFFFF when index >= size.
#### Error codes
PININGROUP_ERROR_PIN = 0xFF = 255.
PININGROUP_ERROR_PIN = 0xFF = 255.
## Operation
@ -86,20 +98,19 @@ See examples.
These ideas will be explored when time permits or needs arise.
#### must
#### Must
- improve documentation
- move code from .h to .cpp
#### should
#### Should
- add real live examples
- Allocate dynamic memory (0.2.0)
- fragmentation?
- would be memory efficient.
#### could
#### Could
- Optimize the low level reading e.g. reading registers only once.
- Hold register and bit info per pin.
@ -114,3 +125,14 @@ These ideas will be explored when time permits or needs arise.
- getIndex()
- getPin()
#### Wont
## Support
If you appreciate my libraries, you can support the development and maintenance.
Improve the quality of the libraries by providing issues and Pull Requests, or
donate through PayPal or GitHub sponsors.
Thank you,

View File

@ -15,9 +15,9 @@
"type": "git",
"url": "https://github.com/RobTillaart/PinInGroup.git"
},
"version": "0.1.8",
"version": "0.1.9",
"license": "MIT",
"frameworks": "arduino",
"frameworks": "*",
"platforms": "*",
"headers": "PinInGroup.h"
}

View File

@ -1,9 +1,9 @@
name=PinInGroup
version=0.1.8
version=0.1.9
author=Rob Tillaart <rob.tillaart@gmail.com>
maintainer=Rob Tillaart <rob.tillaart@gmail.com>
sentence=A class that groups input pins so they can be read in one logical step.
paragraph=
paragraph=
category=Communication
url=https://github.com/RobTillaart/PinInGroup
architectures=*