Files
allwpilib/hal/include/HAL/Compressor.h

44 lines
2.0 KiB
C
Raw Normal View History

/*----------------------------------------------------------------------------*/
/* Copyright (c) FIRST 2016. All Rights Reserved. */
/* Open Source Software - may be modified and shared by FRC teams. The code */
/* must be accompanied by the FIRST BSD license file in the root directory of */
/* the project. */
/*----------------------------------------------------------------------------*/
2016-07-02 08:22:44 -07:00
#pragma once
#include <stdint.h>
2016-07-02 08:22:44 -07:00
#include "HAL/Handles.h"
extern "C" {
2016-07-02 08:22:44 -07:00
HalCompressorHandle initializeCompressor(uint8_t module, int32_t* status);
bool checkCompressorModule(uint8_t module);
2016-07-02 08:22:44 -07:00
bool getCompressor(HalCompressorHandle compressor_handle, int32_t* status);
2016-07-02 08:22:44 -07:00
void setClosedLoopControl(HalCompressorHandle compressor_handle, bool value,
int32_t* status);
bool getClosedLoopControl(HalCompressorHandle compressor_handle,
int32_t* status);
2016-07-02 08:22:44 -07:00
bool getPressureSwitch(HalCompressorHandle compressor_handle, int32_t* status);
float getCompressorCurrent(HalCompressorHandle compressor_handle,
int32_t* status);
2016-07-02 08:22:44 -07:00
bool getCompressorCurrentTooHighFault(HalCompressorHandle compressor_handle,
int32_t* status);
bool getCompressorCurrentTooHighStickyFault(
HalCompressorHandle compressor_handle, int32_t* status);
bool getCompressorShortedStickyFault(HalCompressorHandle compressor_handle,
int32_t* status);
bool getCompressorShortedFault(HalCompressorHandle compressor_handle,
int32_t* status);
bool getCompressorNotConnectedStickyFault(HalCompressorHandle compressor_handle,
int32_t* status);
bool getCompressorNotConnectedFault(HalCompressorHandle compressor_handle,
int32_t* status);
void clearAllPCMStickyFaults(HalCompressorHandle compressor_handle,
int32_t* status);
}