#include "drv/drv.h"
#include "sys/ti_drv_fray.h"
#include "binary.h"
-#include "hal/hal.h"
+#include "drv/digital_io.h"
/**
* The structure maps a RX/TX buffer to a slot in the communication cycle.
/** Array of responses for each fray driver */
static uint32_t fray_spi_resp[FRAY_NUM_PORTS];
/** Array of port names to be easily accessible by indexing */
-static const char *fray_port_names[FRAY_NUM_PORTS] = { PORT_NAME_FRAY1, PORT_NAME_FRAY2 };
+static const char *fray_port_names[FRAY_NUM_PORTS] = { DIO_PORT_NAME_FRAY1, DIO_PORT_NAME_FRAY2 };
/** Array of integers, where FlexRay cluster and node configuration
* parameters are stored to be accessible by indexes defined in Fr_GeneralTypes.h.
*/
int Fr_spi_transfer(uint8_t port)
{
uint32_t commands[2];
- port_desc_t *desc;
+ dio_port_desc_t *desc;
if (port > FRAY_NUM_PORTS) return -1;
- desc = hal_port_get_dsc(fray_port_names[port], -1);
+ desc = dio_port_get_dsc(fray_port_names[port], -1);
fray_spi_cmd_sh = fray_spi_cmd;
commands[0] = (fray_spi_cmd_sh & 0xFF00) >> 8;
commands[1] = (fray_spi_cmd_sh & 0xFF);