WPILibC++  2020.3.2
AddressableLED.h
1 /*----------------------------------------------------------------------------*/
2 /* Copyright (c) 2019 FIRST. All Rights Reserved. */
3 /* Open Source Software - may be modified and shared by FRC teams. The code */
4 /* must be accompanied by the FIRST BSD license file in the root directory of */
5 /* the project. */
6 /*----------------------------------------------------------------------------*/
7 
8 #pragma once
9 
10 #include <stdint.h>
11 
12 #include "hal/AddressableLEDTypes.h"
13 #include "hal/Types.h"
14 
21 #ifdef __cplusplus
22 extern "C" {
23 #endif
24 
25 HAL_AddressableLEDHandle HAL_InitializeAddressableLED(
26  HAL_DigitalHandle outputPort, int32_t* status);
27 
28 void HAL_FreeAddressableLED(HAL_AddressableLEDHandle handle);
29 
30 void HAL_SetAddressableLEDOutputPort(HAL_AddressableLEDHandle handle,
31  HAL_DigitalHandle outputPort,
32  int32_t* status);
33 
34 void HAL_SetAddressableLEDLength(HAL_AddressableLEDHandle handle,
35  int32_t length, int32_t* status);
36 
37 void HAL_WriteAddressableLEDData(HAL_AddressableLEDHandle handle,
38  const struct HAL_AddressableLEDData* data,
39  int32_t length, int32_t* status);
40 
41 void HAL_SetAddressableLEDBitTiming(HAL_AddressableLEDHandle handle,
42  int32_t lowTime0NanoSeconds,
43  int32_t highTime0NanoSeconds,
44  int32_t lowTime1NanoSeconds,
45  int32_t highTime1NanoSeconds,
46  int32_t* status);
47 
48 void HAL_SetAddressableLEDSyncTime(HAL_AddressableLEDHandle handle,
49  int32_t syncTimeMicroSeconds,
50  int32_t* status);
51 
52 void HAL_StartAddressableLEDOutput(HAL_AddressableLEDHandle handle,
53  int32_t* status);
54 
55 void HAL_StopAddressableLEDOutput(HAL_AddressableLEDHandle handle,
56  int32_t* status);
57 
58 #ifdef __cplusplus
59 } // extern "C"
60 #endif
61 
HAL_AddressableLEDData
Definition: AddressableLEDTypes.h:14