Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: mbed 4DGL-uLCD-SE mbed-rtos nRF24L01P
Diff: CircularBuf.h
- Revision:
- 47:ee38764a787d
- Parent:
- 46:62e45e6e4cdb
- Child:
- 48:26fd1492c5ab
--- a/CircularBuf.h Sun Apr 29 23:21:55 2018 +0000 +++ b/CircularBuf.h Mon Apr 30 00:15:19 2018 +0000 @@ -15,34 +15,35 @@ template <typename T> class CircularBuf { public: - // Argument: - // - /** - @param size Size of the buffer. - * Assigns a circular buffer of the fiven size. + /** + * Assigns a circular buffer of the given size. + * @param size Size of the buffer. */ CircularBuf(unsigned int size); ~CircularBuf(); /** - * Pushes data onto the buffer - * (Adds data to the buffer) - * Arguement:/n - * Data: The array of data to add to the buffer. - * data: The array of data to add - * size: The amount of data in the array - * Return: - * Amount of data actually written - * - * Example Code: - * - * int dataToAdd[2]; - * dataToAdd[0] = 15; - * dataToAdd[1] = 23; - * buffer.push(dataToAdd, 2); - * - * buffer now contains [15, 23] - * @param data The array of data to add to the buffer. - * @param size The size of the array "data" + * Pushes data onto the buffer. Returns the amount of data actually written. + * @param Data The array of data to add to the buffer + * @param size The amound of data in teh array. + */ + // (Adds data to the buffer) + // Argument:/n + // Data: The array of data to add to the buffer. + // data: The array of data to add + // size: The amount of data in the array + // Return: + // Amount of data actually written + // + // Example Code: + // + // int dataToAdd[2]; + // dataToAdd[0] = 15; + // dataToAdd[1] = 23; + // buffer.push(dataToAdd, 2); + // + // buffer now contains [15, 23] + // @param data The array of data to add to the buffer. + // @param size The size of the array "data" */ unsigned int push(T* data, unsigned int size);