Fixed comments
git-svn-id: https://svn.vbchaos.nl/svn/hsb/trunk@409 05563f52-14a8-4384-a975-3d1654cca0fa
This commit is contained in:
@@ -99,6 +99,38 @@ struct DisplayDevice
|
||||
// Function declarations
|
||||
// -----------------------------------------------------------------------------
|
||||
|
||||
|
||||
/** ----------------------------------------------------------------------------
|
||||
* DisplayDevice_construct
|
||||
* Constructor for a new Display Device
|
||||
* If a specific function is not implemented at the display device it is valid
|
||||
* to use NULL pointer instead
|
||||
*
|
||||
* @param self The device instance
|
||||
* @param parameters Parameters for the display device
|
||||
* @param reset Pointer to DISPLAY RESET function
|
||||
* @param setState Pointer to DISPLAY SETSTATE function
|
||||
* @param backspace Pointer to DISPLAY BACKSPACE function
|
||||
* @param setCursorToPosition Pointer to DISPLAY SETCURSORTO POSITION
|
||||
* function
|
||||
* @param writeCharacter Pointer to DISPLAY WRITECHARACTER function
|
||||
* this function writes on single character
|
||||
* @param write Pointer to DIAPLAY WRITE function
|
||||
* @param clear Pointer to DISPLAY CLEARALL function
|
||||
* @param clearLine Pointer to DISPLAY CLEARLINE function
|
||||
* @param setBrightness Pointer to DISPLAY SETBRIGHTNESS function
|
||||
* @param setContrast Pointer to DISPLAY SETCONTRAST function
|
||||
* @param invert Pointer to DISPLAY INVERT function
|
||||
* @param setBlinkingCursor Pointer to DISPLAY SETBLINKINGCURSOR
|
||||
* function
|
||||
*
|
||||
*
|
||||
* @return ErrorStatus SUCCESS if constructor was successful
|
||||
* ERROR otherwise
|
||||
*
|
||||
* @todo
|
||||
* -----------------------------------------------------------------------------
|
||||
*/
|
||||
extern ErrorStatus DisplayDevice_construct (struct DisplayDevice* self, struct DisplayDeviceParameters* parameters,
|
||||
DisplayResetFunction reset,
|
||||
DisplaySetStateFunction setState,
|
||||
@@ -113,17 +145,237 @@ extern ErrorStatus DisplayDevice_construct (struct DisplayDevice* self, struct D
|
||||
DisplayInvertFunction invert,
|
||||
DisplaySetBlinkingCursor setBlinkingCursor);
|
||||
|
||||
|
||||
/** ----------------------------------------------------------------------------
|
||||
* DisplayDevice_destruct
|
||||
* Destructor for Display Device
|
||||
*
|
||||
* @param self The device instance to destruct
|
||||
*
|
||||
* @return void
|
||||
*
|
||||
* @todo
|
||||
* -----------------------------------------------------------------------------
|
||||
*/
|
||||
extern void DisplayDevice_destruct (struct DisplayDevice* self);
|
||||
|
||||
|
||||
/** ----------------------------------------------------------------------------
|
||||
* DisplayDevice_reset
|
||||
* RESET the complete display device
|
||||
*
|
||||
* @param self The device instance
|
||||
*
|
||||
* @return ErrorStatus SUCCESS if function was successful
|
||||
* ERROR otherwise
|
||||
*
|
||||
* @todo
|
||||
* -----------------------------------------------------------------------------
|
||||
*/
|
||||
extern ErrorStatus DisplayDevice_reset(const struct DisplayDevice* self);
|
||||
|
||||
|
||||
/** ----------------------------------------------------------------------------
|
||||
* DisplayDevice_setState
|
||||
* Sets the display to new state
|
||||
*
|
||||
*
|
||||
* @param self The device instance
|
||||
* @param state Can be either ON or OFF
|
||||
*
|
||||
* @return ErrorStatus SUCCESS if function was successful
|
||||
* ERROR otherwise
|
||||
*
|
||||
* @todo
|
||||
* -----------------------------------------------------------------------------
|
||||
*/
|
||||
extern ErrorStatus DisplayDevice_setState(const struct DisplayDevice* self, DisplayDevice_functionalState state);
|
||||
|
||||
|
||||
/** ----------------------------------------------------------------------------
|
||||
* DisplayDevice_backspace
|
||||
* Display backspace function. Set cursor one position back and delete character
|
||||
*
|
||||
*
|
||||
* @param self The device instance
|
||||
*
|
||||
* @return ErrorStatus SUCCESS if function was successful
|
||||
* ERROR otherwise
|
||||
*
|
||||
* @todo
|
||||
* -----------------------------------------------------------------------------
|
||||
*/
|
||||
extern ErrorStatus DisplayDevice_backspace(const struct DisplayDevice* self);
|
||||
|
||||
|
||||
/** ----------------------------------------------------------------------------
|
||||
* DisplayDevice_setCursorToPosition
|
||||
* Sets the cursor to the position given in arguments row/column
|
||||
* DisplayDevice function in behind verifies the position
|
||||
*
|
||||
*
|
||||
* @param self The device instance
|
||||
* @param row Row to use (starts with 1, not 0)
|
||||
* @param column Column to use (Starts with 1, not 0)
|
||||
*
|
||||
* @return ErrorStatus SUCCESS if function was successful
|
||||
* ERROR otherwise
|
||||
* Especially when position was not valid
|
||||
*
|
||||
* @todo
|
||||
* -----------------------------------------------------------------------------
|
||||
*/
|
||||
extern ErrorStatus DisplayDevice_setCursorToPosition(const struct DisplayDevice* self, unsigned int row, unsigned int column);
|
||||
|
||||
|
||||
/** ----------------------------------------------------------------------------
|
||||
* DisplayDevice_writeCharacter
|
||||
* Write a single character given in argument buffer to position given in
|
||||
* arguments row/column
|
||||
*
|
||||
*
|
||||
* @param self The device instance
|
||||
* @param buffer Pointer to the character to write
|
||||
* @param row Row to use (starts with 1, not 0)
|
||||
* @param column Column to use (Starts with 1, not 0)
|
||||
*
|
||||
* @return ErrorStatus SUCCESS if function was successful
|
||||
* ERROR otherwise
|
||||
* Especially when position was not valid
|
||||
*
|
||||
* @todo
|
||||
* -----------------------------------------------------------------------------
|
||||
*/
|
||||
extern ErrorStatus DisplayDevice_writeCharacter(const struct DisplayDevice* self, const char* buffer, unsigned int row, unsigned int column);
|
||||
|
||||
|
||||
/** ----------------------------------------------------------------------------
|
||||
* DisplayDevice_write
|
||||
*
|
||||
*
|
||||
* @param self The device instance
|
||||
* @param buffer Pointer to the string to write
|
||||
* @param length The length (number in characters) of the
|
||||
* message to write
|
||||
* @param row Row to use (starts with 1, not 0)
|
||||
* @param column Column to use (Starts with 1, not 0)
|
||||
*
|
||||
* @return ErrorStatus SUCCESS if function was successful
|
||||
* ERROR otherwise
|
||||
* Especially when position or string length
|
||||
* are not valid
|
||||
*
|
||||
* @todo
|
||||
* -----------------------------------------------------------------------------
|
||||
*/
|
||||
extern ErrorStatus DisplayDevice_write(const struct DisplayDevice* self, const char* buffer, unsigned int length, unsigned int row, unsigned int column);
|
||||
|
||||
|
||||
/** ----------------------------------------------------------------------------
|
||||
* DisplayDevice_clear
|
||||
* Function to clear the complete display
|
||||
*
|
||||
*
|
||||
* @param self The device instance
|
||||
*
|
||||
* @return ErrorStatus SUCCESS if function was successful
|
||||
* ERROR otherwise
|
||||
*
|
||||
* @todo
|
||||
* -----------------------------------------------------------------------------
|
||||
*/
|
||||
extern ErrorStatus DisplayDevice_clear(const struct DisplayDevice* self);
|
||||
|
||||
|
||||
/** ----------------------------------------------------------------------------
|
||||
* DisplayDevice_clearLine
|
||||
* Function to clear the line given in argument row
|
||||
*
|
||||
*
|
||||
* @param self The device instance
|
||||
* @param row Row to use (starts with 1, not 0)
|
||||
*
|
||||
* @return ErrorStatus SUCCESS if function was successful
|
||||
* ERROR otherwise
|
||||
* Especially when position was not valid
|
||||
*
|
||||
* @todo
|
||||
* -----------------------------------------------------------------------------
|
||||
*/
|
||||
extern ErrorStatus DisplayDevice_clearLine(const struct DisplayDevice* self, unsigned int row);
|
||||
|
||||
|
||||
/** ----------------------------------------------------------------------------
|
||||
* DisplayDevice_setBrightness
|
||||
* Sets the display brightness
|
||||
* Must be a value between the min and max brightness given in the display device
|
||||
* parameters in the constructor
|
||||
*
|
||||
*
|
||||
* @param self The device instance
|
||||
* @param brightness The brightness value
|
||||
*
|
||||
* @return ErrorStatus SUCCESS if function was successful
|
||||
* ERROR otherwise
|
||||
* Especially when brightness value is
|
||||
* outside boundaries
|
||||
*
|
||||
* @todo
|
||||
* -----------------------------------------------------------------------------
|
||||
*/
|
||||
extern ErrorStatus DisplayDevice_setBrightness(const struct DisplayDevice* self, unsigned int brightness);
|
||||
|
||||
|
||||
/** ----------------------------------------------------------------------------
|
||||
* DisplayDevice_setContrast
|
||||
* Sets the display contrast
|
||||
* Must be a value between the min and max contrast given in the display device
|
||||
* parameters in the constructor
|
||||
*
|
||||
* @param self The device instance
|
||||
* @param contrast The contrast value
|
||||
*
|
||||
* @return ErrorStatus SUCCESS if function was successful
|
||||
* ERROR otherwise
|
||||
* Especially when contrast value is
|
||||
* outside boundaries
|
||||
*
|
||||
* @todo
|
||||
* -----------------------------------------------------------------------------
|
||||
*/
|
||||
extern ErrorStatus DisplayDevice_setContrast(const struct DisplayDevice* self, unsigned int contrast);
|
||||
|
||||
|
||||
/** ----------------------------------------------------------------------------
|
||||
* DisplayDevice_invert
|
||||
* Function to invert the display representation
|
||||
*
|
||||
*
|
||||
* @param self The device instance
|
||||
*
|
||||
* @return ErrorStatus SUCCESS if function was successful
|
||||
* ERROR otherwise
|
||||
*
|
||||
* @todo
|
||||
* -----------------------------------------------------------------------------
|
||||
*/
|
||||
extern ErrorStatus DisplayDevice_invert(const struct DisplayDevice* self);
|
||||
|
||||
|
||||
/** ----------------------------------------------------------------------------
|
||||
* DisplayDevice_setBlinkingCursorState
|
||||
* Sets the state for a blinking cursor
|
||||
*
|
||||
*
|
||||
* @param self The device instance
|
||||
* @param state Can either be ON or OFF
|
||||
*
|
||||
* @return ErrorStatus SUCCESS if function was successful
|
||||
* ERROR otherwise
|
||||
*
|
||||
* @todo
|
||||
* -----------------------------------------------------------------------------
|
||||
*/
|
||||
extern ErrorStatus DisplayDevice_setBlinkingCursorState(const struct DisplayDevice* self, DisplayDevice_functionalState state);
|
||||
|
||||
#endif /* INC_DISPLAYDEVICE_H_ */
|
||||
|
||||
Reference in New Issue
Block a user