Skip to content

Commit 22acc79

Browse files
committed
fpga_ci_test_shield-uart: Disable test cases not supported on NRF52840_DK target
According to the documentation, `NRF52840_DK` does not support odd parity and 2 stop bits. Skip these test case using #if !defined(TARGET_NRF52840) directive. This is temporary solution. In the future we shell consider adding `uart_get_capabilities()` function. -
1 parent 6a9b4bb commit 22acc79

File tree

1 file changed

+7
-0
lines changed
  • TESTS/mbed_hal_fpga_ci_test_shield/uart

1 file changed

+7
-0
lines changed

TESTS/mbed_hal_fpga_ci_test_shield/uart/main.cpp

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -338,7 +338,9 @@ Case cases[] = {
338338
Case("38400, 8N1, FC off", one_peripheral<UARTNoFCPort, DefaultFormFactor, fpga_uart_test_common_no_fc<38400, 8, ParityNone, 1, false> >),
339339
Case("115200, 8N1, FC off", one_peripheral<UARTNoFCPort, DefaultFormFactor, fpga_uart_test_common_no_fc<115200, 8, ParityNone, 1, false> >),
340340
// stop bits
341+
#if !defined(TARGET_NRF52840)
341342
Case("9600, 8N2, FC off", one_peripheral<UARTNoFCPort, DefaultFormFactor, fpga_uart_test_common_no_fc<9600, 8, ParityNone, 2, false> >),
343+
#endif
342344

343345
#if DEVICE_SERIAL_FC
344346
// Every set of pins from every peripheral.
@@ -355,11 +357,16 @@ Case cases[] = {
355357
Case("115200, 8N1, FC on", one_peripheral<UARTPort, DefaultFormFactor, fpga_uart_test_common<115200, 8, ParityNone, 1, false> >),
356358
// data bits: not tested (some platforms support 8 bits only)
357359
// parity
360+
#if !defined(TARGET_NRF52840)
358361
Case("9600, 8O1, FC on", one_peripheral<UARTPort, DefaultFormFactor, fpga_uart_test_common<9600, 8, ParityOdd, 1, false> >),
362+
#endif
359363
Case("9600, 8E1, FC on", one_peripheral<UARTPort, DefaultFormFactor, fpga_uart_test_common<9600, 8, ParityEven, 1, false> >),
360364
// stop bits
365+
#if !defined(TARGET_NRF52840)
361366
Case("9600, 8N2, FC on", one_peripheral<UARTPort, DefaultFormFactor, fpga_uart_test_common<9600, 8, ParityNone, 2, false> >),
362367
#endif
368+
#endif
369+
363370
};
364371

365372
utest::v1::status_t greentea_test_setup(const size_t number_of_cases)

0 commit comments

Comments
 (0)