2012-12-14 21:55:38 -04:00
|
|
|
|
|
|
|
#include "SPIDriver.h"
|
|
|
|
|
|
|
|
using namespace Empty;
|
|
|
|
|
2012-12-17 15:07:26 -04:00
|
|
|
EmptySPIDeviceDriver::EmptySPIDeviceDriver()
|
|
|
|
{}
|
|
|
|
|
|
|
|
void EmptySPIDeviceDriver::init()
|
|
|
|
{}
|
|
|
|
|
|
|
|
AP_HAL::Semaphore* EmptySPIDeviceDriver::get_semaphore()
|
|
|
|
{
|
|
|
|
return &_semaphore;
|
|
|
|
}
|
|
|
|
|
2012-12-17 21:12:15 -04:00
|
|
|
void EmptySPIDeviceDriver::transaction(const uint8_t *tx, uint8_t *rx, uint16_t len)
|
|
|
|
{}
|
|
|
|
|
|
|
|
|
2012-12-17 15:07:26 -04:00
|
|
|
void EmptySPIDeviceDriver::cs_assert()
|
|
|
|
{}
|
|
|
|
|
|
|
|
void EmptySPIDeviceDriver::cs_release()
|
|
|
|
{}
|
|
|
|
|
|
|
|
uint8_t EmptySPIDeviceDriver::transfer (uint8_t data)
|
|
|
|
{
|
|
|
|
return 0;
|
|
|
|
}
|
|
|
|
|
2013-01-12 07:13:23 -04:00
|
|
|
void EmptySPIDeviceDriver::transfer (const uint8_t *data, uint16_t len)
|
|
|
|
{
|
|
|
|
}
|
|
|
|
|
2012-12-17 15:07:26 -04:00
|
|
|
EmptySPIDeviceManager::EmptySPIDeviceManager()
|
|
|
|
{}
|
|
|
|
|
|
|
|
void EmptySPIDeviceManager::init(void *)
|
|
|
|
{}
|
|
|
|
|
2012-12-14 21:55:38 -04:00
|
|
|
AP_HAL::SPIDeviceDriver* EmptySPIDeviceManager::device(enum AP_HAL::SPIDevice)
|
2012-12-17 15:07:26 -04:00
|
|
|
{
|
|
|
|
return &_device;
|
|
|
|
}
|
2012-12-14 21:55:38 -04:00
|
|
|
|