#ifndef __UDSSERVERCALLBACKS_GM_H
#define __UDSSERVERCALLBACKS_GM_H

/* ------------------------------ Includes --------------------------------- */
#include "Global.h"
#include "Iso15765_3_CFG.h"

/* --------------------------- Type Definitions ---------------------------- */

/* ------------------------------- Defines --------------------------------- */
#define START_DOWNLOAD_VALUE (0xABC1)	/* Memory value to indicate to the bootloader that a reprogramming session is requested */

/************************* DATA IDENTIFIERS ***********************************/

/*** SUPPORTED DATA IDENTIFIERS FOR READDATABYID AND WRITEDATABYID SERVICES ***/
#define DID_DIO_HALL_SENSOR_VALUES				((uint16)0xB000)
#define DID_DIO_ST								((uint16)0xB001)
#define DID_DIO_HOLD							((uint16)0xB002)
#define DID_DIO_SNS_ENA							((uint16)0xB003)
#define DID_DIO_HALL_ENA_1						((uint16)0xB004)
#define DID_DIO_HALL_SNS_2						((uint16)0xB005)
#define DID_DIO_STR_RLY_CTRL					((uint16)0xB006)
#define DID_DIO_REV_LMP_CTRL					((uint16)0xB007)
#define DID_DIO_RESET_TO_SUPERVISOR				((uint16)0xB008)
#define DID_ADC_IGN_SNS							((uint16)0xB100)
#define DID_ADC_BAT_12V_SNS						((uint16)0xB101)
#define DID_ADC_PWR_OR_SNS						((uint16)0xB102)
#define DID_ADC_2V5REFA							((uint16)0xB103)
#define DID_ADC_VCC_B_SNS						((uint16)0xB104)
#define DID_ADC_VCC_C_SNS						((uint16)0xB105)
#define DID_ADC_VCC_HALL_A_SNS					((uint16)0xB106)
#define DID_ADC_VCC_HALL_B_SNS					((uint16)0xB107)
#define DID_ADC_HW_VERSION						((uint16)0xB108)
#define DID_ADC_REV_LMP_SNS						((uint16)0xB109)
#define DID_ADC_STR_RLY_SNS						((uint16)0xB110)
#define DID_COLUMN_SHIFTER_DETECTION			((uint16)0xB020)


/* Routine Control */
#define DID_Periodic_ID							((uint16)0xF005)/* Same than NEVs */
#define DID_UDS_Resp_ID							((uint16)0xF006)/* Same than NEVs */
#define DID_UDS_Req_ID							((uint16)0xF007)/* Same than NEVs */

/* IO Control */
#define DID_HS_Control							((uint16)0xF100)
#define DID_SR_Control							((uint16)0xF101)
#define DID_RLR_Control							((uint16)0xF102)

/* Logistic data */
#define DID_FICOSA_HW_ID						((UI_16)0xF192)
#define DID_FICOSA_SW_ID						((UI_16)0xF194)

#define DID_PP_DIO_HALL_SENSOR_VALUES			((uint16)0xFD00)
#define DID_PP_DIO_ST							((uint16)0xFD01)
#define DID_PP_DIO_HOLD							((uint16)0xFD02)
#define DID_PP_DIO_SNS_ENA						((uint16)0xFD03)
#define DID_PP_DIO_HALL_ENA_1					((uint16)0xFD04)
#define DID_PP_DIO_HALL_SNS_2					((uint16)0xFD05)
#define DID_PP_DIO_STR_RLY_CTRL					((uint16)0xFD06)
#define DID_PP_DIO_REV_LMP_CTRL					((uint16)0xFD07)
#define DID_PP_DIO_RESET_TO_SUPERVISOR			((uint16)0xFD08)
#define DID_PP_ADC_IGN_SNS						((uint16)0xFD20)
#define DID_PP_ADC_BAT_12V_SNS					((uint16)0xFD21)
#define DID_PP_ADC_PWR_OR_SNS					((uint16)0xFD22)
#define DID_PP_ADC_2V5REFA						((uint16)0xFD23)
#define DID_PP_ADC_VCC_B_SNS					((uint16)0xFD24)
#define DID_PP_ADC_VCC_C_SNS					((uint16)0xFD25)
#define DID_PP_ADC_VCC_HALL_A_SNS				((uint16)0xFD26)
#define DID_PP_ADC_VCC_HALL_B_SNS				((uint16)0xFD27)
#define DID_PP_ADC_HW_VERSION					((uint16)0xFD28)
#define DID_PP_ADC_REV_LMP_SNS					((uint16)0xFD29)
#define DID_PP_ADC_STR_RLY_SNS					((uint16)0xFD30)
#define DID_PP_PRODUCTION_DATA					((uint16)0xFE00)
#define DID_PP_UDS_SESSION_CHECK				((uint16)0xFE01)
#define DID_PP_START_UP_HS_CHECK				((uint16)0xFE02)
/* Logistic data */
#define DID_PP_FICOSA_HW_ID						((UI_16)0xFE92)
#define DID_PP_FICOSA_SW_ID						((UI_16)0xFE94)

/* Definitions needed for the Read/WriteMemoryByAddress UDS services */
#define FIXED_ADDR_LEN 		((UI_8)4)
#define MAX_ADDR_SIZE 		((UI_8)4)
#define MAX_SIZE_LEN 		((UI_8)0xFF)
#define DIAG_TX_RX_BUF_LEN 	((UI_8)0xFF)
#define MAX_DATA_SIZE 		((UI_8)4)
#endif
