STMicroelectronics / STM32CubeF3

STM32Cube MCU Full Package for the STM32F3 series - (HAL + LL Drivers, CMSIS Core, CMSIS Device, MW libraries plus a set of Projects running on all boards provided by ST (Nucleo, Evaluation and Discovery Kits))
Other
141 stars 54 forks source link

Missing (PCD_HandleTypeDef *) casts cause build errors in C++ compilers when USB is used #10

Closed pawelszramowski closed 2 years ago

pawelszramowski commented 4 years ago

Since void* is not implicitly convertible to other pointers, missing (PCD_HandleTypeDef *) casts cause build errors in C++ compiler (I used IAR EW for Arm 8.50.1) when USB is used. This affects the following files:

CCASTM commented 3 years ago

Ali, I have discovered this Issues, quite old ! Can you check in a first step with Aymen if this problem has already been taken into account ? Regards Christophe

ALABSTM commented 3 years ago

Hi @pawelszramowski,

Thank you for your report. May I know the MCU target you are using? This way, the issue will be transferred to the appropriate repository and deeper analyzed.

With regards,

pawelszramowski commented 3 years ago

@ALABSTM, this is not related to a particular microcontroller. As I wrote, it affects files %ProgramFiles%\STMicroelectronics\STM32Cube\STM32CubeMX\db\templates\usbdconf*_c.ftl and %UserProfile%\STM32Cube\Repository\STM32Cube_FW_F3_V1.11.0\Middlewares\ST\STM32_USB_Device_Library\Class\CDC\Src\usbd_cdc.c thus project for any MCU generated using these files will be affected too.

ALABSTM commented 3 years ago

Hi @pawelszramowski,

Thank you for the precision. Indeed, the issue might impact more than one firmware in particular. I asked my question simply because with the way-of-work we defined, such issues are handled at STM32Cube.. repository-level, not at this one's.

Once the issue confirmed and logged into our internal database, we will surely spread the fix to any other firmware impacted. I noticed you have mentioned the STM32Cube_FW_F3_V1.11.0. I will then transfer this issue to the STM32CubeF3 repository.

Thank you for your comprehension and thank you again for having reported the point.

With regards,

ALABSTM commented 3 years ago

Hi @pawelszramowski,

The issue you reported has been reproduced using the C++ compiler of EWARM v8.32.4 (an even older version than the one you are using). Your report will be forwarded to our development teams. I will get back to you as soon as I have their feedback.

With regards,

ALABSTM commented 3 years ago

Hi @pawelszramowski,

Our development teams confirmed the cast is missing. This will be logged into our internal database and a fix will be made available in the frame of a future release.

With regards,

ALABSTM commented 3 years ago

ST Internal Reference: 105369

ALABSTM commented 3 years ago

ST Internal Reference: 105621

ALABSTM commented 2 years ago

Hi @pawelszramowski,

I hope you are fine. Back to you about what you reported. Our development teams agreed to fix the point at USB Device library-level, but not at application-level as this would impact USB applications of all firmware packages and the Cube MX tool itself.

The fix has been published in the frame of v2.9.0 of the stm32_mw_usb_device library. Please notice that current version is v2.10.0.

Regarding the STM32CubeF3 firmware, integrated USB Device library version is v2.5.3. Unfortunately, there is no plan to integrate a newer version. However, all v2.y.z versions are compatible. Hence, you can get latest updates from the link above and integrate them into your firmware package if needed.

I hope all this helps. Please allow me to close this issue now. Thank you for your comprehension and thank you again for having reported.

With regards,