We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 678f3f9 commit 4213c61Copy full SHA for 4213c61
targets/TARGET_NORDIC/TARGET_NRF5/spi_api.c
@@ -254,6 +254,11 @@ void spi_init(spi_t *obj,
254
PinName mosi, PinName miso, PinName sclk, PinName ssel)
255
{
256
int i;
257
+
258
+ // This block is only a workaround that allows to create SPI object several
259
+ // times, what would be otherwise impossible in the current implementation
260
+ // of mbed driver that does not call spi_free() from SPI destructor.
261
+ // Once this mbed's imperfection is corrected, this block should be removed.
262
for (i = 0; i < SPI_COUNT; ++i) {
263
spi_info_t *p_spi_info = &m_spi_info[i];
264
if (p_spi_info->initialized &&
0 commit comments