Skip to content

Commit

Permalink
fix comment headers/weirdness
Browse files Browse the repository at this point in the history
  • Loading branch information
gigapod committed Apr 29, 2024
1 parent 34a82e2 commit 9d9ddaf
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 28 deletions.
34 changes: 17 additions & 17 deletions src/sfeTkArdI2C.h
Original file line number Diff line number Diff line change
Expand Up @@ -40,13 +40,13 @@ over Inter-Integrated Circuit (I2C) in Arduino
class sfeTkArdI2C : public sfeTkII2C
{
public:
/**--------------------------------------------------------------------------
/**
@brief Constructor
*/
sfeTkArdI2C(void) : _i2cPort(nullptr), _bufferChunkSize{kDefaultBufferChunk}
{
}
/**--------------------------------------------------------------------------
/**
@brief Constructor
@param addr The address of the device
Expand Down Expand Up @@ -74,20 +74,20 @@ class sfeTkArdI2C : public sfeTkII2C
return *this;
}

/**--------------------------------------------------------------------------
/**
@brief Method sets up the required I2C settings.
@note This function provides a default I2C Port.
@retval kSTkErrOk on successful execution.
*/
sfeTkError_t init();

/**--------------------------------------------------------------------------
/**
@brief - address version of the init method
*/
sfeTkError_t init(uint8_t addr);

/**--------------------------------------------------------------------------
/**
@brief Method sets up the required I2C settings.
@param wirePort Port for I2C communication.
Expand All @@ -97,15 +97,15 @@ class sfeTkArdI2C : public sfeTkII2C
*/
sfeTkError_t init(TwoWire &wirePort, uint8_t addr, bool bInit = false);

/**--------------------------------------------------------------------------
/**
@brief A simple ping of the device at the given address.
@note sfeTkIBus interface method
@retval kSTkErrOk on success,
*/
sfeTkError_t ping();

/**--------------------------------------------------------------------------
/**
@brief Write a single byte to the device
@note sfeTkIBus interface method
Expand All @@ -115,7 +115,7 @@ class sfeTkArdI2C : public sfeTkII2C
*/
sfeTkError_t writeByte(uint8_t data);

/**--------------------------------------------------------------------------
/**
@brief Write a single byte to the given register
@note sfeTkIBus interface method
Expand All @@ -126,7 +126,7 @@ class sfeTkArdI2C : public sfeTkII2C
*/
sfeTkError_t writeRegisterByte(uint8_t devReg, uint8_t data);

/**--------------------------------------------------------------------------
/**
@brief Write a single word to the given register
@note sfeTkIBus interface method
Expand All @@ -137,7 +137,7 @@ class sfeTkArdI2C : public sfeTkII2C
*/
sfeTkError_t writeRegisterWord(uint8_t devReg, uint16_t data);

/**--------------------------------------------------------------------------
/**
@brief Writes a number of bytes starting at the given register's address.
@note sfeTkIBus interface method
Expand All @@ -150,7 +150,7 @@ class sfeTkArdI2C : public sfeTkII2C
*/
sfeTkError_t writeRegisterRegion(uint8_t devReg, const uint8_t *data, size_t length);

/**--------------------------------------------------------------------------
/**
@brief Writes a number of bytes starting at the given register's 16-bit address.
@param devAddr The device's 16-bit address/pin
Expand All @@ -162,7 +162,7 @@ class sfeTkArdI2C : public sfeTkII2C
*/
sfeTkError_t writeRegister16Region(uint16_t devReg, const uint8_t *data, size_t length);

/**--------------------------------------------------------------------------
/**
@brief Reads a byte of data from the given register.
@note sfeTkIBus interface method
Expand All @@ -174,7 +174,7 @@ class sfeTkArdI2C : public sfeTkII2C
*/
sfeTkError_t readRegisterByte(uint8_t devReg, uint8_t &data);

/**--------------------------------------------------------------------------
/**
@brief Reads a word of data from the given register.
@note sfeTkIBus interface method
Expand All @@ -186,7 +186,7 @@ class sfeTkArdI2C : public sfeTkII2C
*/
sfeTkError_t readRegisterWord(uint8_t devReg, uint16_t &data);

/**--------------------------------------------------------------------------
/**
@brief Reads a block of data from the given register.
@note sfeTkIBus interface method
Expand All @@ -202,7 +202,7 @@ class sfeTkArdI2C : public sfeTkII2C
*/
sfeTkError_t readRegisterRegion(uint8_t devReg, uint8_t *data, size_t numBytes, size_t &readBytes);

/**--------------------------------------------------------------------------
/**
@brief Reads a block of data from the given 16-bit register address.
@param reg The device's 16 bit register's address.
Expand All @@ -216,7 +216,7 @@ class sfeTkArdI2C : public sfeTkII2C
sfeTkError_t readRegister16Region(uint16_t reg, uint8_t *data, size_t numBytes, size_t &readBytes);

// Buffer size chunk getter/setter
/**--------------------------------------------------------------------------
/**
@brief set the buffer chunk size
@note default size is 32
Expand All @@ -230,7 +230,7 @@ class sfeTkArdI2C : public sfeTkII2C
_bufferChunkSize = theChunk;
}

/**--------------------------------------------------------------------------
/**
@brief set the buffer chunk size
@retval The current chunk size
Expand Down
22 changes: 11 additions & 11 deletions src/sfeTkArdSPI.h
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ class sfeTkArdSPI : public sfeTkISPI
return *this;
}

/**--------------------------------------------------------------------------
/**
@brief Method sets up the required SPI settings.
@note This function provides a default SPI Port.
Expand All @@ -86,7 +86,7 @@ class sfeTkArdSPI : public sfeTkISPI

sfeTkError_t init(uint8_t csPin, bool bInit = false);

/**--------------------------------------------------------------------------
/**
@brief Method sets up the required SPI settings.
@param spiPort Port for SPI communication.
Expand All @@ -97,7 +97,7 @@ class sfeTkArdSPI : public sfeTkISPI
*/
sfeTkError_t init(SPIClass &spiPort, SPISettings &busSPISettings, uint8_t csPin, bool bInit = false);

/**--------------------------------------------------------------------------
/**
@brief Write a single byte to the device
@param data Data to write.
Expand All @@ -106,7 +106,7 @@ class sfeTkArdSPI : public sfeTkISPI
*/
sfeTkError_t writeByte(uint8_t data);

/**--------------------------------------------------------------------------
/**
@brief Write a single byte to the given register
@param devReg The device's register's address.
Expand All @@ -116,7 +116,7 @@ class sfeTkArdSPI : public sfeTkISPI
*/
sfeTkError_t writeRegisterByte(uint8_t devReg, uint8_t data);

/**--------------------------------------------------------------------------
/**
@brief Write a single word to the given register
@param devReg The device's register's address.
Expand All @@ -126,7 +126,7 @@ class sfeTkArdSPI : public sfeTkISPI
*/
sfeTkError_t writeRegisterWord(uint8_t devReg, uint16_t data);

/**--------------------------------------------------------------------------
/**
@brief Writes a number of bytes starting at the given register's address.
@note This method is virtual to allow it to be overridden to support a device that requires a unique impl
Expand All @@ -137,7 +137,7 @@ class sfeTkArdSPI : public sfeTkISPI
*/
sfeTkError_t writeRegisterRegion(uint8_t devReg, const uint8_t *data, size_t length);

/**--------------------------------------------------------------------------
/**
@brief Writes a number of bytes starting at the given register's address.
@note This method is virtual to allow it to be overridden to support a device that requires a unique impl
Expand All @@ -148,7 +148,7 @@ class sfeTkArdSPI : public sfeTkISPI
*/
sfeTkError_t writeRegister16Region(uint16_t devReg, const uint8_t *data, size_t length);

/**--------------------------------------------------------------------------
/**
@brief Read a single byte from the given register
@param devReg The device's register's address.
Expand All @@ -158,7 +158,7 @@ class sfeTkArdSPI : public sfeTkISPI
*/
sfeTkError_t readRegisterByte(uint8_t devReg, uint8_t &data);

/**--------------------------------------------------------------------------
/**
@brief read a single word to the given register
@param devReg The device's register's address.
Expand All @@ -168,7 +168,7 @@ class sfeTkArdSPI : public sfeTkISPI
*/
sfeTkError_t readRegisterWord(uint8_t devReg, uint16_t &data);

/**--------------------------------------------------------------------------
/**
@brief Reads a block of data from the given register.
@note This method is virtual to allow it to be overridden to support a device that requires a unique impl
Expand All @@ -181,7 +181,7 @@ class sfeTkArdSPI : public sfeTkISPI
*/
virtual sfeTkError_t readRegisterRegion(uint8_t reg, uint8_t *data, size_t numBytes, size_t &readBytes);

/**--------------------------------------------------------------------------
/**
@brief Reads a block of data from the given register.
@note This method is virtual to allow it to be overridden to support a device that requires a unique impl
Expand Down

0 comments on commit 9d9ddaf

Please sign in to comment.