prevent multiple initialization memory allocation and inform user if allocation was fail

This commit is contained in:
Zaltora 2018-03-27 10:56:46 +02:00
parent a89417e26e
commit 6dde352842
2 changed files with 20 additions and 6 deletions

View file

@ -53,7 +53,7 @@ typedef enum {
*
* @param pixels_number Number of pixels in the strip.
*/
void ws2812_i2s_init(uint32_t pixels_number, pixeltype_t type);
int ws2812_i2s_init(uint32_t pixels_number, pixeltype_t type);
/**
* Update ws2812 pixels.