mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-07-03 03:01:44 +00:00
Implements Better Error Messages from the HAL (#172)
* Makes the HAL provide a better error message for certain things. * Makes Java error messages better * Updates C++ errors. * Moves handles header folder to HAL directory
This commit is contained in:
committed by
Peter Johnson
parent
05c00430b3
commit
d2aa168f66
@@ -25,8 +25,8 @@
|
||||
#include "HAL/Errors.h"
|
||||
#include "HAL/cpp/priority_condition_variable.h"
|
||||
#include "HAL/cpp/priority_mutex.h"
|
||||
#include "HAL/handles/HandlesInternal.h"
|
||||
#include "ctre/ctre.h"
|
||||
#include "handles/HandlesInternal.h"
|
||||
#include "visa/visa.h"
|
||||
|
||||
static tGlobal* global = nullptr;
|
||||
@@ -113,6 +113,10 @@ const char* HAL_GetErrorMessage(int32_t code) {
|
||||
return NO_AVAILABLE_RESOURCES_MESSAGE;
|
||||
case RESOURCE_IS_ALLOCATED:
|
||||
return RESOURCE_IS_ALLOCATED_MESSAGE;
|
||||
case RESOURCE_OUT_OF_RANGE:
|
||||
return RESOURCE_OUT_OF_RANGE_MESSAGE;
|
||||
case HAL_INVALID_ACCUMULATOR_CHANNEL:
|
||||
return HAL_INVALID_ACCUMULATOR_CHANNEL_MESSAGE;
|
||||
case HAL_HANDLE_ERROR:
|
||||
return HAL_HANDLE_ERROR_MESSAGE;
|
||||
case NULL_PARAMETER:
|
||||
|
||||
Reference in New Issue
Block a user