64
64
#define TEST_SCLK_PIN P10_12
65
65
#define TEST_CS_PIN P10_13
66
66
67
+ #elif defined(TARGET_FF_ARDUINO)
68
+ #define TEST_MOSI_PIN D11
69
+ #define TEST_MISO_PIN D12
70
+ #define TEST_SCLK_PIN D13
71
+ #define TEST_CS_PIN D10
72
+
73
+ #elif defined(TARGET_DISCO_F429ZI)
74
+ #define TEST_MOSI_PIN PC_12
75
+ #define TEST_MISO_PIN PC_11
76
+ #define TEST_SCLK_PIN PC_10
77
+ #define TEST_CS_PIN PA_15
78
+
67
79
#else
68
80
#error Target not supported
69
81
#endif
@@ -152,7 +164,7 @@ TEST(SPI_Master_Asynchronous, short_tx_0_rx)
152
164
{
153
165
int rc;
154
166
// Write a buffer of Short Transfer length.
155
- rc = obj->transfer ( tx_buf,SHORT_XFR,NULL ,0 , callback, - 1 );
167
+ rc = obj->transfer ( ( const uint8_t *) tx_buf, SHORT_XFR, ( uint8_t *) NULL , 0 , callback, 255 );
156
168
CHECK_EQUAL (0 , rc);
157
169
158
170
while (!complete);
@@ -171,7 +183,7 @@ TEST(SPI_Master_Asynchronous, short_tx_0_rx_nn)
171
183
{
172
184
int rc;
173
185
// Write a buffer of Short Transfer length.
174
- rc = obj->transfer ( tx_buf,SHORT_XFR,rx_buf,0 ,callback, -1 );
186
+ rc = obj->transfer ( ( const uint8_t *) tx_buf,SHORT_XFR,( uint8_t *) rx_buf, 0 ,callback, -1 );
175
187
CHECK_EQUAL (0 , rc);
176
188
177
189
while (!complete);
@@ -189,7 +201,7 @@ TEST(SPI_Master_Asynchronous, 0_tx_short_rx)
189
201
{
190
202
int rc;
191
203
// Read a buffer of Short Transfer length.
192
- rc = obj->transfer ( NULL ,0 ,rx_buf,SHORT_XFR,callback, -1 );
204
+ rc = obj->transfer ( ( const uint8_t *) NULL ,0 ,( uint8_t *) rx_buf,SHORT_XFR,callback, -1 );
193
205
CHECK_EQUAL (0 , rc);
194
206
195
207
while (!complete);
0 commit comments