picolibrary

MCP3008 Facilities

Microchip MCP3008 facilities are defined in the include/picolibrary/microchip/mcp3008.h/source/picolibrary/microchip/mcp3008.cc header/source file pair.

Table of Contents

  1. Input Identification
  2. Driver
  3. Blocking, Single Sample ADC

Input Identification

The ::picolibrary::Microchip::MCP3008::Input enum class is used to identify Microchip MCP3008 inputs.

A std::ostream insertion operator is defined for ::picolibrary::Microchip::MCP3008::Input if the PICOLIBRARY_ENABLE_AUTOMATED_TESTING project configuration option is ON. The insertion operator is defined in the include/picolibrary/testing/automated/microchip/mcp3008.h/source/picolibrary/testing/automated/microchip/mcp3008.cc header/source file pair.

Driver

The ::picolibrary::Microchip::MCP3008::Driver Microchip MCP3008 driver template class is used to interact with a Microchip MCP3008.

::picolibrary::Microchip::MCP3008::Driver automated tests are defined in the test/automated/picolibrary/microchip/mcp3008/driver/main.cc source file.

The ::picolibrary::Testing::Automated::Microchip::MCP3008::Mock_Driver mock Microchip MCP3008 driver class is available if the PICOLIBRARY_ENABLE_AUTOMATED_TESTING project configuration option is ON. The mock is defined in the include/picolibrary/testing/automated/microchip/mcp3008.h/source/picolibrary/testing/automated/microchip/mcp3008.cc header/source file pair.

Blocking, Single Sample ADC

The ::picolibrary::Microchip::MCP3008::Blocking_Single_Sample_Converter template class implements a blocking, single sample ADC interface for interacting with a Microchip MCP3008 input. See the ::picolibrary::ADC::Blocking_Single_Sample_Converter_Concept documentation for more information. ::picolibrary::Microchip::MCP3008::Blocking_Single_Sample_Converter automated tests are defined in the test/automated/picolibrary/microchip/mcp3008/blocking_single_sample_converter/main.cc source file.

The ::picolibrary::Testing::Interactive::Microchip::MCP3008::sample() interactive test helper is available if the PICOLIBRARY_ENABLE_INTERACTIVE_TESTING project configuration option is ON. The interactive test helper is defined in the include/picolibrary/testing/interactive/microchip/mcp3008.h/source/picolibrary/testing/interactive/microchip/mcp3008.cc header/source file pair.