GY-63_MS5611/libraries/DEVFULL
2024-04-13 10:35:57 +02:00
..
.github bulk update GitHub actions 2024-04-13 10:35:57 +02:00
examples 0.1.2 DEVFULL 2022-10-31 19:44:49 +01:00
test 0.1.1 DEVFULL 2022-07-02 12:50:15 +02:00
.arduino-ci.yml 0.1.2 DEVFULL 2022-10-31 19:44:49 +01:00
CHANGELOG.md 0.1.3 DEVFULL 2023-10-24 15:28:25 +02:00
DEVFULL.h 0.1.3 DEVFULL 2023-10-24 15:28:25 +02:00
keywords.txt 0.1.0 DEVFULL 2022-03-11 10:15:31 +01:00
library.json 0.1.3 DEVFULL 2023-10-24 15:28:25 +02:00
library.properties 0.1.3 DEVFULL 2023-10-24 15:28:25 +02:00
LICENSE bulk update GitHub actions 2024-04-13 10:35:57 +02:00
README.md 0.1.3 DEVFULL 2023-10-24 15:28:25 +02:00

Arduino CI Arduino-lint JSON check GitHub issues

License: MIT GitHub release PlatformIO Registry

DEVFULL

Arduino library for a /dev/full stream.

Description

The experimental library implements a stream class that mimics the /dev/full device of a Linux system. You can write nothing to it as it is always full. Every read data will return the value zero, just like /dev/zero.

Calls to print() and println() will be split up in multiple calls to write(). This causes a return value of n x -28 ==> mostly a number in the 65xxx range

See - https://en.wikipedia.org/wiki//dev/full

Interface

#include "DEVFULL.h"
  • DEVFULL() constructor, sets the timeout to zero.
  • int available() always return INT_MAX = platform dependant.
  • int peek() always returns 0.
  • int read() always returns 0.
  • void flush() does nothing but keeps some compilers happy.
  • size_t write(const uint8_t data) always returns -28 (ENOSPC).
  • size_t write(const uint8_t *buffer, size_t size) implements print interface. Always returns -28 (ENOSPC).

Error code

value name description
-28 ENOSPC No space available for writing onto the "storage device".

Operation

Use with care.

See examples.

Future

Must

  • improve documentation

Should

  • improve code
  • test different platforms.

Could

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,