42 TEST_ASSERT_EQUAL(HIGH, digitalRead(LED_BUILTIN));
52 TEST_ASSERT_EQUAL(LOW, digitalRead(LED_BUILTIN));
60 digitalWrite(LED_BUILTIN, HIGH);
64 TEST_ASSERT_EQUAL(LOW, digitalRead(LED_BUILTIN));
68 TEST_ASSERT_EQUAL(HIGH, digitalRead(LED_BUILTIN));
78 TEST_ASSERT_EQUAL(HIGH, digitalRead(LED_BUILTIN));
81 TEST_ASSERT_EQUAL(LOW, digitalRead(LED_BUILTIN));
89 const uint16_t pinsToSet{ 0b11111111111100 };
94 for (uint8_t pin = 2; pin < 14; ++pin)
96 TEST_ASSERT_EQUAL(HIGH, digitalRead(pin));
105 const uint16_t pinsToSet{ 0b11111111111100 };
110 for (uint8_t pin = 2; pin < 14; ++pin)
112 TEST_ASSERT_EQUAL(LOW, digitalRead(pin));
123 for (uint8_t pin = 2; pin < 14; ++pin)
125 pinMode(pin, OUTPUT);
void test_togglePin(void)
void test_setPinsON(void)
void test_setPinsOFF(void)
void test_setPinState(void)
void test_setPinOFF(void)
Some utility functions for pins manipulation.
void setPinsOFF(uint16_t pins)
Set the Pins state to OFF.
constexpr void setPinState(const uint8_t pin, const bool bState)
Set the Pin state for the specified pin.
constexpr void togglePin(uint8_t pin)
Toggle the specified pin.
constexpr void setPinON(uint8_t pin)
Set the Pin state to ON for the specified pin.
constexpr void setPinOFF(uint8_t pin)
Set the Pin state to OFF for the specified pin.
void setPinsON(uint16_t pins)
Set the Pins state to ON.