mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2026-01-15 22:31:32 +01:00
merged to developer
This commit is contained in:
@@ -8,16 +8,14 @@
|
||||
#ifndef ERROR_DEFS_H_
|
||||
#define ERROR_DEFS_H_
|
||||
|
||||
#include "ansi.h"
|
||||
#include "sls_detector_defs.h"
|
||||
|
||||
#include <stdio.h>
|
||||
#include <string>
|
||||
#include <cstring>
|
||||
using namespace std;
|
||||
|
||||
|
||||
#include "sls_detector_defs.h"
|
||||
#include <cstring>
|
||||
#include <iostream>
|
||||
|
||||
using namespace std;
|
||||
|
||||
/** Error flags */
|
||||
/*Assumption: Only upto 63 detectors */
|
||||
@@ -26,52 +24,57 @@ using namespace std;
|
||||
#define MULTI_DETECTORS_NOT_ADDED 0x8000000000000000ULL
|
||||
|
||||
|
||||
#define CANNOT_CONNECT_TO_DETECTOR 0x8000000000000000ULL
|
||||
#define CANNOT_CONNECT_TO_RECEIVER 0x4000000000000000ULL
|
||||
#define COULDNOT_SET_CONTROL_PORT 0x2000000000000000ULL
|
||||
#define COULDNOT_SET_STOP_PORT 0x1000000000000000ULL
|
||||
#define COULDNOT_SET_DATA_PORT 0x0800000000000000ULL
|
||||
#define FILE_PATH_DOES_NOT_EXIST 0x0400000000000000ULL
|
||||
#define COULDNOT_CREATE_UDP_SOCKET 0x0200000000000000ULL
|
||||
#define COULDNOT_CREATE_FILE 0x0100000000000000ULL
|
||||
#define COULDNOT_ENABLE_COMPRESSION 0x0080000000000000ULL
|
||||
#define RECEIVER_DET_HOSTNAME_NOT_SET 0x0040000000000000ULL
|
||||
#define RECEIVER_DET_HOSTTYPE_NOT_SET 0x0020000000000000ULL
|
||||
#define DETECTOR_TEN_GIGA 0x0010000000000000ULL
|
||||
#define DETECTOR_ACTIVATE 0x0008000000000000ULL
|
||||
#define CANNOT_CONNECT_TO_DETECTOR 0x4000000000000000ULL
|
||||
#define CANNOT_CONNECT_TO_RECEIVER 0x2000000000000000ULL
|
||||
#define COULDNOT_SET_CONTROL_PORT 0x1000000000000000ULL
|
||||
#define COULDNOT_SET_STOP_PORT 0x0800000000000000ULL
|
||||
#define COULDNOT_SET_DATA_PORT 0x0400000000000000ULL
|
||||
#define FILE_PATH_DOES_NOT_EXIST 0x0200000000000000ULL
|
||||
#define COULDNOT_CREATE_UDP_SOCKET 0x0100000000000000ULL
|
||||
#define COULDNOT_CREATE_FILE 0x0080000000000000ULL
|
||||
#define COULDNOT_ENABLE_COMPRESSION 0x0040000000000000ULL
|
||||
#define RECEIVER_DET_HOSTNAME_NOT_SET 0x0020000000000000ULL
|
||||
#define RECEIVER_DET_HOSTTYPE_NOT_SET 0x0010000000000000ULL
|
||||
#define DETECTOR_TEN_GIGA 0x0008000000000000ULL
|
||||
#define DETECTOR_ACTIVATE 0x0004000000000000ULL
|
||||
#define COULD_NOT_CONFIGURE_MAC 0x0002000000000000ULL
|
||||
#define COULDNOT_START_RECEIVER 0x0001000000000000ULL // default error like starting threads
|
||||
#define COULDNOT_STOP_RECEIVER 0x0000800000000000ULL
|
||||
|
||||
// 0xFFFFFFFF00000000ULL
|
||||
|
||||
#define COULD_NOT_CONFIGURE_MAC 0x0000000000000001ULL
|
||||
#define COULDNOT_SET_NETWORK_PARAMETER 0x0000000000000002ULL
|
||||
#define COULDNOT_SET_ROI 0x0000000000000004ULL
|
||||
#define RECEIVER_READ_FREQUENCY 0x0000000000000008ULL
|
||||
#define SETTINGS_NOT_SET 0x0000000000000010ULL
|
||||
#define SETTINGS_FILE_NOT_OPEN 0x0000000000000020ULL
|
||||
#define COULDNOT_START_RECEIVER 0x0000000000000040ULL // default error like starting threads
|
||||
#define COULDNOT_STOP_RECEIVER 0x0000000000000080ULL
|
||||
#define DETECTOR_TIMER_VALUE_NOT_SET 0x0000000000000100ULL
|
||||
#define RECEIVER_ACQ_PERIOD_NOT_SET 0x0000000000000200ULL
|
||||
#define RECEIVER_FRAME_NUM_NOT_SET 0x0000000000000400ULL
|
||||
#define RECEIVER_DYNAMIC_RANGE 0x0000000000000800ULL
|
||||
#define RECEIVER_TEN_GIGA 0x0000000000001000ULL
|
||||
#define ALLTIMBITS_NOT_SET 0x0000000000002000ULL
|
||||
#define COULD_NOT_SET_SPEED_PARAMETERS 0x0000000000004000ULL
|
||||
#define COULD_NOT_SET_READOUT_FLAGS 0x0000000000008000ULL
|
||||
#define COULD_NOT_SET_FIFO_DEPTH 0x0000000000010000ULL
|
||||
#define COULD_NOT_SET_COUNTER_BIT 0x0000000000020000ULL
|
||||
#define COULD_NOT_PULSE_PIXEL 0x0000000000040000ULL
|
||||
#define COULD_NOT_PULSE_PIXEL_NMOVE 0x0000000000080000ULL
|
||||
#define COULD_NOT_PULSE_CHIP 0x0000000000100000ULL
|
||||
#define COULD_NOT_SET_RATE_CORRECTION 0x0000000000200000ULL
|
||||
#define DETECTOR_NETWORK_PARAMETER 0x0000000000400000ULL
|
||||
#define RATE_CORRECTION_NOT_32or16BIT 0x0000000000800000ULL
|
||||
#define RATE_CORRECTION_NO_TAU_PROVIDED 0x0000000001000000ULL
|
||||
#define PROGRAMMING_ERROR 0x0000000002000000ULL
|
||||
#define RECEIVER_ACTIVATE 0x0000000004000000ULL
|
||||
#define DATA_STREAMING 0x0000000008000000ULL
|
||||
#define RESET_ERROR 0x0000000010000000ULL
|
||||
#define POWER_CHIP 0x0000000020000000ULL
|
||||
|
||||
#define COULDNOT_SET_NETWORK_PARAMETER 0x0000000000000001ULL
|
||||
#define COULDNOT_SET_ROI 0x0000000000000002ULL
|
||||
#define RECEIVER_READ_FREQUENCY 0x0000000000000004ULL
|
||||
#define SETTINGS_NOT_SET 0x0000000000000008ULL
|
||||
#define SETTINGS_FILE_NOT_OPEN 0x0000000000000010ULL
|
||||
#define DETECTOR_TIMER_VALUE_NOT_SET 0x0000000000000020ULL
|
||||
#define RECEIVER_ACQ_PERIOD_NOT_SET 0x0000000000000040ULL
|
||||
#define RECEIVER_FRAME_NUM_NOT_SET 0x0000000000000080ULL
|
||||
#define RECEIVER_DYNAMIC_RANGE 0x0000000000000100ULL
|
||||
#define RECEIVER_TEN_GIGA 0x0000000000000200ULL
|
||||
#define ALLTIMBITS_NOT_SET 0x0000000000000400ULL
|
||||
#define COULD_NOT_SET_SPEED_PARAMETERS 0x0000000000000800ULL
|
||||
#define COULD_NOT_SET_READOUT_FLAGS 0x0000000000001000ULL
|
||||
#define COULD_NOT_SET_FIFO_DEPTH 0x0000000000002000ULL
|
||||
#define COULD_NOT_SET_COUNTER_BIT 0x0000000000004000ULL
|
||||
#define COULD_NOT_PULSE_PIXEL 0x0000000000008000ULL
|
||||
#define COULD_NOT_PULSE_PIXEL_NMOVE 0x0000000000010000ULL
|
||||
#define COULD_NOT_PULSE_CHIP 0x0000000000020000ULL
|
||||
#define COULD_NOT_SET_RATE_CORRECTION 0x0000000000040000ULL
|
||||
#define DETECTOR_NETWORK_PARAMETER 0x0000000000080000ULL
|
||||
#define RATE_CORRECTION_NOT_32or16BIT 0x0000000000100000ULL
|
||||
#define RATE_CORRECTION_NO_TAU_PROVIDED 0x0000000000200000ULL
|
||||
#define PROGRAMMING_ERROR 0x0000000000400000ULL
|
||||
#define RECEIVER_ACTIVATE 0x0000000000800000ULL
|
||||
#define DATA_STREAMING 0x0000000001000000ULL
|
||||
#define RESET_ERROR 0x0000000002000000ULL
|
||||
#define POWER_CHIP 0x0000000004000000ULL
|
||||
#define RECEIVER_READ_TIMER 0x0000000008000000ULL
|
||||
#define RECEIVER_ACQ_TIME_NOT_SET 0x0000000010000000ULL
|
||||
#define RECEIVER_FLIPPED_DATA_NOT_SET 0x0000000020000000ULL
|
||||
|
||||
// 0x00000000FFFFFFFFULL
|
||||
/** @short class returning all error messages for error mask */
|
||||
class errorDefs {
|
||||
@@ -225,6 +228,12 @@ public:
|
||||
if(slsErrorMask&POWER_CHIP)
|
||||
retval.append("Could not power on/off/get the chip\n");
|
||||
|
||||
if(slsErrorMask&RECEIVER_READ_TIMER)
|
||||
retval.append("Could not set receiver read timer\n");
|
||||
|
||||
if(slsErrorMask&RECEIVER_FLIPPED_DATA_NOT_SET)
|
||||
retval.append("Could not set receiver flipped data/bottom\n");
|
||||
|
||||
//------------------------------------------------------ length of message
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user