Before logging an issue, please update to the latest release of Visual Micro from the Downloads Page.

When Logging a Support Issue in the Forum, please ensure you have also:-

  • Enabled vMicro > Compiler > Show Build Properties
  • Re-Compile your program with these settings enabled
 
Save the new Output to a Text File and....
  • Click the Reply button and attach as .txt file OR
  • Click here to Email us with the file attached, and a link to your post
Support requests without the output above may be impossible to answer, so please help us to help you
 
Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic Serial1 on Stm32 (Read 746 times)
infou
Junior Member
**
Offline


Posts: 18
Joined: Dec 23rd, 2020
Serial1 on Stm32
Aug 5th, 2024 at 1:40pm
Print Post  
I am using stm32 version 2.8.1, which I have updated to this new version via the Arduino IDE.
Microsoft Visual Studio Community 2022 (64-bit) - Current version 17.10.5
Arduino IDE for Visual Studio 2022 2024.722.2208.

A link error occurred:
Linking it all together ...
arm-none-eabi-gcc\13.2.1-1.1/bin/arm-none-eabi-gcc" -mcpu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard -mthumb -Os -DNDEBUG --specs=nano.specs -Wl,--defsym=LD_FLASH_OFFSET=0x0 -Wl,--defsym=LD_MAX_SIZE=262144 -Wl,--defsym=LD_MAX_DATA_SIZE=65536 -Wl,--cref -Wl,--check-sections -Wl,--gc-sections -Wl,--entry=Reset_Handler -Wl,--unresolved-symbols=report-all -Wl,--warn-common /ldscript.ld" \hardware\stm32\2.8.1\system/ldscript.ld" nF4\Debug/Saxo2.ino.map" -Wl,--no-warn-rwx-segments -o /Saxo2.ino.elf" ug" -Wl,--start-group "Saxo2.cpp.o" "src\CirquePinnacle.cpp.o" "src\MIDI.cpp.o" "VM_DBG\VM_DBG.cpp.o" "VM_DBG\VM_mem_check_sam.cpp.o" "SPI\SPI.cpp.o" "SPI\utility\spi_com.c.o" "Wire\Wire.cpp.o" "Wire\utility\twi.c.o" "Adafruit_BNO08x\sh2.c.o" "Adafruit_BNO08x\sh2_SensorValue.c.o" "Adafruit_BNO08x\sh2_util.c.o" "Adafruit_BNO08x\shtp.c.o" "Adafruit_BNO08x\Adafruit_BNO08x.cpp.o" "Adafruit_BusIO\Adafruit_BusIO_Register.cpp.o" "Adafruit_BusIO\Adafruit_I2CDevice.cpp.o" "Adafruit_BusIO\Adafruit_SPIDevice.cpp.o" "Adafruit_Unified_Sensor\Adafruit_Sensor.cpp.o" "SrcWrapper\syscalls.c.o" "SrcWrapper\HardwareTimer.cpp.o" "SrcWrapper\new.cpp.o" "SrcWrapper\HAL\stm32yyxx_hal.c.o" "SrcWrapper\HAL\stm32yyxx_hal_adc.c.o" "SrcWrapper\HAL\stm32yyxx_hal_adc_ex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_can.c.o" "SrcWrapper\HAL\stm32yyxx_hal_cec.c.o" "SrcWrapper\HAL\stm32yyxx_hal_comp.c.o" "SrcWrapper\HAL\stm32yyxx_hal_comp_ex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_cordic.c.o" "SrcWrapper\HAL\stm32yyxx_hal_cortex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_crc.c.o" "SrcWrapper\HAL\stm32yyxx_hal_crc_ex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_cryp.c.o" "SrcWrapper\HAL\stm32yyxx_hal_cryp_ex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_dac.c.o" "SrcWrapper\HAL\stm32yyxx_hal_dac_ex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_dcache.c.o" "SrcWrapper\HAL\stm32yyxx_hal_dcmi.c.o" "SrcWrapper\HAL\stm32yyxx_hal_dcmi_ex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_dfsdm.c.o" "SrcWrapper\HAL\stm32yyxx_hal_dfsdm_ex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_dma.c.o" "SrcWrapper\HAL\stm32yyxx_hal_dma2d.c.o" "SrcWrapper\HAL\stm32yyxx_hal_dma_ex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_dsi.c.o" "SrcWrapper\HAL\stm32yyxx_hal_dts.c.o" "SrcWrapper\HAL\stm32yyxx_hal_eth.c.o" "SrcWrapper\HAL\stm32yyxx_hal_eth_ex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_exti.c.o" "SrcWrapper\HAL\stm32yyxx_hal_fdcan.c.o" "SrcWrapper\HAL\stm32yyxx_hal_firewall.c.o" "SrcWrapper\HAL\stm32yyxx_hal_flash.c.o" "SrcWrapper\HAL\stm32yyxx_hal_flash_ex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_flash_ramfunc.c.o" "SrcWrapper\HAL\stm32yyxx_hal_fmac.c.o" "SrcWrapper\HAL\stm32yyxx_hal_fmpi2c.c.o" "SrcWrapper\HAL\stm32yyxx_hal_fmpi2c_ex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_fmpsmbus.c.o" "SrcWrapper\HAL\stm32yyxx_hal_fmpsmbus_ex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_gfxmmu.c.o" "SrcWrapper\HAL\stm32yyxx_hal_gfxtim.c.o" "SrcWrapper\HAL\stm32yyxx_hal_gpio.c.o" "SrcWrapper\HAL\stm32yyxx_hal_gpio_ex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_gpu2d.c.o" "SrcWrapper\HAL\stm32yyxx_hal_gtzc.c.o" "SrcWrapper\HAL\stm32yyxx_hal_hash.c.o" "SrcWrapper\HAL\stm32yyxx_hal_hash_ex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_hcd.c.o" "SrcWrapper\HAL\stm32yyxx_hal_hrtim.c.o" "SrcWrapper\HAL\stm32yyxx_hal_hsem.c.o" "SrcWrapper\HAL\stm32yyxx_hal_i2c.c.o" "SrcWrapper\HAL\stm32yyxx_hal_i2c_ex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_i2s.c.o" "SrcWrapper\HAL\stm32yyxx_hal_i2s_ex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_i3c.c.o" "SrcWrapper\HAL\stm32yyxx_hal_icache.c.o" "SrcWrapper\HAL\stm32yyxx_hal_ipcc.c.o" "SrcWrapper\HAL\stm32yyxx_hal_irda.c.o" "SrcWrapper\HAL\stm32yyxx_hal_iwdg.c.o" "SrcWrapper\HAL\stm32yyxx_hal_jpeg.c.o" "SrcWrapper\HAL\stm32yyxx_hal_lcd.c.o" "SrcWrapper\HAL\stm32yyxx_hal_lptim.c.o" "SrcWrapper\HAL\stm32yyxx_hal_ltdc.c.o" "SrcWrapper\HAL\stm32yyxx_hal_ltdc_ex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_mdf.c.o" "SrcWrapper\HAL\stm32yyxx_hal_mdios.c.o" "SrcWrapper\HAL\stm32yyxx_hal_mdma.c.o" "SrcWrapper\HAL\stm32yyxx_hal_mmc.c.o" "SrcWrapper\HAL\stm32yyxx_hal_mmc_ex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_nand.c.o" "SrcWrapper\HAL\stm32yyxx_hal_nor.c.o" "SrcWrapper\HAL\stm32yyxx_hal_opamp.c.o" "SrcWrapper\HAL\stm32yyxx_hal_opamp_ex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_ospi.c.o" "SrcWrapper\HAL\stm32yyxx_hal_otfdec.c.o" "SrcWrapper\HAL\stm32yyxx_hal_pccard.c.o" "SrcWrapper\HAL\stm32yyxx_hal_pcd.c.o" "SrcWrapper\HAL\stm32yyxx_hal_pcd_ex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_pka.c.o" "SrcWrapper\HAL\stm32yyxx_hal_pssi.c.o" "SrcWrapper\HAL\stm32yyxx_hal_pwr.c.o" "SrcWrapper\HAL\stm32yyxx_hal_pwr_ex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_qspi.c.o" "SrcWrapper\HAL\stm32yyxx_hal_ramcfg.c.o" "SrcWrapper\HAL\stm32yyxx_hal_ramecc.c.o" "SrcWrapper\HAL\stm32yyxx_hal_rcc.c.o" "SrcWrapper\HAL\stm32yyxx_hal_rcc_ex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_rng.c.o" "SrcWrapper\HAL\stm32yyxx_hal_rng_ex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_rtc.c.o" "SrcWrapper\HAL\stm32yyxx_hal_rtc_ex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_sai.c.o" "SrcWrapper\HAL\stm32yyxx_hal_sai_ex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_sd.c.o" "SrcWrapper\HAL\stm32yyxx_hal_sdadc.c.o" "SrcWrapper\HAL\stm32yyxx_hal_sdram.c.o" "SrcWrapper\HAL\stm32yyxx_hal_sd_ex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_smartcard.c.o" "SrcWrapper\HAL\stm32yyxx_hal_smartcard_ex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_smbus.c.o" "SrcWrapper\HAL\stm32yyxx_hal_smbus_ex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_spdifrx.c.o" "SrcWrapper\HAL\stm32yyxx_hal_spi.c.o" "SrcWrapper\HAL\stm32yyxx_hal_spi_ex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_sram.c.o" "SrcWrapper\HAL\stm32yyxx_hal_subghz.c.o" "SrcWrapper\HAL\stm32yyxx_hal_swpmi.c.o" "SrcWrapper\HAL\stm32yyxx_hal_tim.c.o" "SrcWrapper\HAL\stm32yyxx_hal_tim_ex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_tsc.c.o" "SrcWrapper\HAL\stm32yyxx_hal_uart.c.o" "SrcWrapper\HAL\stm32yyxx_hal_uart_ex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_usart.c.o" "SrcWrapper\HAL\stm32yyxx_hal_usart_ex.c.o" "SrcWrapper\HAL\stm32yyxx_hal_wwdg.c.o" "SrcWrapper\HAL\stm32yyxx_hal_xspi.c.o" "SrcWrapper\LL\stm32yyxx_ll_adc.c.o" "SrcWrapper\LL\stm32yyxx_ll_bdma.c.o" "SrcWrapper\LL\stm32yyxx_ll_comp.c.o" "SrcWrapper\LL\stm32yyxx_ll_cordic.c.o" "SrcWrapper\LL\stm32yyxx_ll_crc.c.o" "SrcWrapper\LL\stm32yyxx_ll_crs.c.o" "SrcWrapper\LL\stm32yyxx_ll_dac.c.o" "SrcWrapper\LL\stm32yyxx_ll_delayblock.c.o" "SrcWrapper\LL\stm32yyxx_ll_dlyb.c.o" "SrcWrapper\LL\stm32yyxx_ll_dma.c.o" "SrcWrapper\LL\stm32yyxx_ll_dma2d.c.o" "SrcWrapper\LL\stm32yyxx_ll_exti.c.o" "SrcWrapper\LL\stm32yyxx_ll_fmac.c.o" "SrcWrapper\LL\stm32yyxx_ll_fmc.c.o" "SrcWrapper\LL\stm32yyxx_ll_fmpi2c.c.o" "SrcWrapper\LL\stm32yyxx_ll_fsmc.c.o" "SrcWrapper\LL\stm32yyxx_ll_gpio.c.o" "SrcWrapper\LL\stm32yyxx_ll_hrtim.c.o" "SrcWrapper\LL\stm32yyxx_ll_i2c.c.o" "SrcWrapper\LL\stm32yyxx_ll_i3c.c.o" "SrcWrapper\LL\stm32yyxx_ll_icache.c.o" "SrcWrapper\LL\stm32yyxx_ll_lpgpio.c.o" "SrcWrapper\LL\stm32yyxx_ll_lptim.c.o" "SrcWrapper\LL\stm32yyxx_ll_lpuart.c.o" "SrcWrapper\LL\stm32yyxx_ll_mdma.c.o" "SrcWrapper\LL\stm32yyxx_ll_opamp.c.o" "SrcWrapper\LL\stm32yyxx_ll_pka.c.o" "SrcWrapper\LL\stm32yyxx_ll_pwr.c.o" "SrcWrapper\LL\stm32yyxx_ll_rcc.c.o" "SrcWrapper\LL\stm32yyxx_ll_rng.c.o" "SrcWrapper\LL\stm32yyxx_ll_rtc.c.o" "SrcWrapper\LL\stm32yyxx_ll_sdmmc.c.o" "SrcWrapper\LL\stm32yyxx_ll_spi.c.o" "SrcWrapper\LL\stm32yyxx_ll_swpmi.c.o" "SrcWrapper\LL\stm32yyxx_ll_tim.c.o" "SrcWrapper\LL\stm32yyxx_ll_ucpd.c.o" "SrcWrapper\LL\stm32yyxx_ll_usart.c.o" "SrcWrapper\LL\stm32yyxx_ll_usb.c.o" "SrcWrapper\LL\stm32yyxx_ll_utils.c.o" "SrcWrapper\stm32\bootloader.c.o" "SrcWrapper\stm32\clock.c.o" "SrcWrapper\stm32\core_callback.c.o" "SrcWrapper\stm32\dwt.c.o" "SrcWrapper\stm32\hw_config.c.o" "SrcWrapper\stm32\otp.c.o" "SrcWrapper\stm32\pinmap.c.o" "SrcWrapper\stm32\PortNames.c.o" "SrcWrapper\stm32\stm32_def.c.o" "SrcWrapper\stm32\system_stm32yyxx.c.o" "SrcWrapper\stm32\timer.c.o" "SrcWrapper\stm32\uart.c.o" "SrcWrapper\stm32\analog.cpp.o" "SrcWrapper\stm32\interrupt.cpp.o" "USBDevice\usbd_conf.c.o" "USBDevice\usbd_desc.c.o" "USBDevice\usbd_ep_conf.c.o" "USBDevice\usbd_if.c.o" "USBDevice\usb_device_core.c.o" "USBDevice\usb_device_ctlreq.c.o" "USBDevice\usb_device_ioreq.c.o" "USBDevice\USBSerial.cpp.o" "USBDevice\cdc\cdc_queue.c.o" "USBDevice\cdc\usbd_cdc.c.o" "USBDevice\cdc\usbd_cdc_if.c.o" "USBDevice\hid\usbd_hid_composite.c.o" "USBDevice\hid\usbd_hid_composite_if.c.o" "variant\generic_clock.c.o" "variant\PeripheralPins.c.o" "variant\PeripheralPins_BLACKPILL_F401Cx.c.o" "variant\PeripheralPins_PYBSTICK26_LITE.c.o" "variant\variant_BLACKPILL_F401Cx.cpp.o" "variant\variant_generic.cpp.o" "variant\variant_PYBSTICK26_LITE.cpp.o" \core.a" -lc -Wl,--end-group -lm -lgcc -lstdc++
ld.exe: \Debug\\core.a(HardwareSerial.cpp.o)Sad.bss.Serial2+0x0): multiple definition of Serial2; Saxo2.cpp.o:(.bss.Serial2+0x0): first defined here
 
ld.exe: Saxo2.cpp.o: in function __static_initialization_and_destruction_0()
Saxo2.ino: (.text._Z41__static_initialization_and_destruction_0v+0x3c): undefined reference to Serial1
 
collect2.exe*: error: ld returned 1 exit status

Error linking for board Generic STM32F4 series(STMicroelectronics_GenF4)
Debug build failed for project 

The error disappeared after I switched the toolbar from Debug to Release.
It also disappeared after I switched the toolbar from Release to Debug again.
  
Back to top
 
IP Logged
 
Simon@Visual Micro
Administrator
*****
Offline


Posts: 2695
Joined: Feb 13th, 2019
Re: Serial1 on Stm32
Reply #1 - Aug 5th, 2024 at 3:37pm
Print Post  
Thanks for the report.

From your description it sounds like the issue is now resolved in both Debug and Release Configurations?

If not can you attach the complete build output as a text file with the options enabled as shown at the top of the page?
  
Back to top
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint