-
Notifications
You must be signed in to change notification settings - Fork 0
/
total_control.h
31 lines (22 loc) · 897 Bytes
/
total_control.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
#ifndef TYPEDEF_BYTE
#define TYPEDEF_BYTE
typedef unsigned char byte;
#endif
// Initialize Total Control Lighting.
void tcl_init();
// Adjust the SPI clock frequency.
void tcl_set_clock_delay(byte delay_length);
// Start a new pixel sequence.
void tcl_reset();
// Send a single pixel in a sequence.
void tcl_put_pixel(byte red, byte green, byte blue);
// Send an entire sequence of n pixels, given n*3 bytes of colour data.
void tcl_put_pixels(byte* pixels, int n);
// Send multiple pixels in parallel, one pixel to each strand.
void tcl_put_pixel_multi(byte** pixel_ptrs, int num_strands);
// Send multiple sequences of pixels in parallel to multiple strands.
void tcl_put_pixels_multi(byte** pixel_ptrs, int num_strands, int num_pixels);
// Read a button (b = 1, 2, 3, or 4).
byte tcl_read_button(byte b);
// Adjust the SPI clock frequency.
void tcl_set_clock_delay(byte delay_length);