diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/portable/st/stm32_fsdev/dcd_stm32_fsdev.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/portable/st/stm32_fsdev/dcd_stm32_fsdev.c b/src/portable/st/stm32_fsdev/dcd_stm32_fsdev.c index 2411c1c37..8f809b6a7 100644 --- a/src/portable/st/stm32_fsdev/dcd_stm32_fsdev.c +++ b/src/portable/st/stm32_fsdev/dcd_stm32_fsdev.c @@ -125,14 +125,18 @@ * Checks, structs, defines, function definitions, etc. */ -#if (MAX_EP_COUNT > 8) +#if ((MAX_EP_COUNT) > 8) # error Only 8 endpoints supported on the hardware #endif -#if ((DCD_STM32_BTABLE_BASE + DCD_STM32_BTABLE_LENGTH)>PMA_LENGTH) +#if (((DCD_STM32_BTABLE_BASE) + (DCD_STM32_BTABLE_LENGTH))>(PMA_LENGTH)) # error BTABLE does not fit in PMA RAM #endif +#if (((DCD_STM32_BTABLE_BASE) % 8) != 0) +// per STM32F3 reference manual +#error BTABLE must be aligned to 8 bytes +#endif // Max size of a USB FS packet is 64... #define MAX_PACKET_SIZE 64 |
