1
Discussion - Software / Re: Using a MPSSE interface for SPI and I2C, proper setup and reset
« on: March 25, 2019, 12:17:21 PM »
I2C_OpenChannel() returns FT_DEVICE_NOT_OPENED (FT_STATUS==3), and a handle==0, when called after SPI channel deinit. Then all calls to I2C_DeviceRead, I2C_DeviceWrite, FT_WriteGPIO return FT_INVALID_HANDLE. I2C_GetNumChannels() returns the same number (2) as when all is working, so the MPSSE channel is seemingly properly deinitialised.
SPI MPSSE does initialise and deinitialise on the same channel B even when I2C stops initialising.
Note I did not use SPI_CloseChannel(), rather only Cleanup_libMPSSE(), because only in this way does my 1.SPI init, 2.SPI work, 3.SPI deinit sequence work more than once. But I did use I2C_CloseChannel() because for I2C not using it impeded functionality (did not work).
SPI MPSSE does initialise and deinitialise on the same channel B even when I2C stops initialising.
Note I did not use SPI_CloseChannel(), rather only Cleanup_libMPSSE(), because only in this way does my 1.SPI init, 2.SPI work, 3.SPI deinit sequence work more than once. But I did use I2C_CloseChannel() because for I2C not using it impeded functionality (did not work).