// PWM is available for HBR control.
#include "drv/drv.h"
#include <os/semphr.h>
-#include "drv/spi.h"
+#include "drv/spi_tms570.h"
#include "drv/gio_tab.h"
//Flag variable if pwm was initialized and is ready to start.
// SPI message format definition for watchdog reset command
spi_msg_t hbr_spi_wdg = {
.flags = 0,
- .addr = 0,
+ .dev = SPIDEV_L99H01,
.rq_len = 2,
.tx_buf = (uint8_t *)&hbr_spi_wdg_tx_shd,
.rx_buf = (uint8_t *)&hbr_spi_wdg_rx_shd,
*/
void drv_hbr_wdg_task(void *p)
{
- spi_drv_t *ifc;
-
- ifc = spi_find_drv(NULL, 4);
-
- if (ifc == NULL) {
- wdg_start = FALSE;
- vTaskDelete(NULL);
- }
-
portTickType xLastWakeTime;
xLastWakeTime = xTaskGetTickCount();
wdg_start = FALSE;
}
else
- spi_msg_rq_ins(ifc, &hbr_spi_wdg);
+ spi_msg_rq_ins(&hbr_spi_wdg);
xSemaphoreGive(wdg_sync);
}
}