mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-19 00:41:43 +00:00
[hal, cscore, ntcore] Use WPI common handle type base
This commit is contained in:
@@ -5,6 +5,8 @@
|
||||
#ifndef CSCORE_HANDLE_H_
|
||||
#define CSCORE_HANDLE_H_
|
||||
|
||||
#include <wpi/Synchronization.h>
|
||||
|
||||
#include "cscore_c.h"
|
||||
|
||||
namespace cs {
|
||||
@@ -18,7 +20,7 @@ class Handle {
|
||||
public:
|
||||
enum Type {
|
||||
kUndefined = 0,
|
||||
kProperty = 0x40,
|
||||
kProperty = wpi::kHandleTypeCSBase,
|
||||
kSource,
|
||||
kSink,
|
||||
kListener,
|
||||
|
||||
@@ -6,6 +6,8 @@
|
||||
|
||||
#include <stdint.h>
|
||||
|
||||
#include <wpi/Synchronization.h>
|
||||
|
||||
#include "hal/Types.h"
|
||||
|
||||
/* General Handle Data Layout
|
||||
@@ -43,7 +45,7 @@ constexpr int16_t InvalidHandleIndex = -1;
|
||||
*/
|
||||
enum class HAL_HandleEnum {
|
||||
Undefined = 0,
|
||||
DIO = 1,
|
||||
DIO = wpi::kHandleTypeHALBase,
|
||||
Port = 2,
|
||||
Notifier = 3,
|
||||
Interrupt = 4,
|
||||
|
||||
@@ -5,6 +5,8 @@
|
||||
#ifndef NTCORE_HANDLE_H_
|
||||
#define NTCORE_HANDLE_H_
|
||||
|
||||
#include <wpi/Synchronization.h>
|
||||
|
||||
#include "ntcore_c.h"
|
||||
|
||||
namespace nt {
|
||||
@@ -17,7 +19,7 @@ namespace nt {
|
||||
class Handle {
|
||||
public:
|
||||
enum Type {
|
||||
kConnectionListener = 1,
|
||||
kConnectionListener = wpi::kHandleTypeNTBase,
|
||||
kConnectionListenerPoller,
|
||||
kEntry,
|
||||
kEntryListener,
|
||||
|
||||
Reference in New Issue
Block a user