semf
stm32f4i2cslave.h
Go to the documentation of this file.
1
10#ifndef SEMF_HARDWAREABSTRACTION_STM32F4_STM32F4I2CSLAVE_H_
11#define SEMF_HARDWAREABSTRACTION_STM32F4_STM32F4I2CSLAVE_H_
12
14
15#if defined(STM32F4) && defined(HAL_I2C_MODULE_ENABLED)
16namespace semf
17{
21class Stm32F4I2cSlave : public Stm32I2cSlave
22{
23public:
27 enum class ErrorCode : uint8_t
28 {
29 SetFrequencyHardware_FrequencyNotSupported = 0
30 };
40 void clearBusyFlagErratum(GPIO_TypeDef* sclPort, uint16_t sclPin,
41 GPIO_TypeDef* sdaPort, uint16_t sdaPin, uint8_t alternate);
42
43protected:
48 void setFrequencyHardware(uint32_t hz) override;
49
50private:
52 static constexpr Error::ClassID kSemfClassId = Error::ClassID::Stm32F4I2cSlave;
53};
54} // namespace semf
55#endif
56#endif // SEMF_HARDWAREABSTRACTION_STM32F4_STM32F4I2CSLAVE_H_
ClassID
Semf class IDs.
Definition: error.h:28
Stm32I2cSlave(I2C_HandleTypeDef &hwHandle)
Constructor.