5 years, 10 months ago.

Cannot Transfer the mbed os to STM32F103RC in VISUAL STUDIO CODE

RT

1> C:/Users/Administrator/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.mbed/targets/TARGET_STM/TARGET_STM32F1/TARGET_NUCLEO_F103RB/device/TOOLCHAIN_GCC_ARM/STM32F103XE.ld:171: undefined symbol `HeapLimit' referenced in expression 1>collect2.exe : error : ld returned 1 exit status 1> make: * [Release/cmnode.elf] Error 1 1> D:/Keil_v5/SysGCC/bin/arm-eabi-g++.exe -o Release/cmnode.elf -Wl,-gc-sections specs=nano.specs specs=nosys.specs -TC:/Users/Administrator/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.mbed/targets/TARGET_STM/TARGET_STM32F1/TARGET_NUCLEO_F103RB/device/TOOLCHAIN_GCC_ARM/STM32F103XE.ld -mcpu=cortex-m3 -mthumb -Wl,start-group Release/ATParser.o Release/BufferedSerial.o Release/ESP8266.o Release/ESP8266Interface.o Release/MyBuffer.o Release/device_configuration.o Release/eeprom_flash.o Release/DnsQuery.o Release/NetworkStack.o Release/Socket.o Release/SocketAddress.o Release/TCPServer.o Release/TCPSocket.o Release/UDPSocket.o Release/ntlibc.o Release/ntopt.o Release/ntshell.o Release/ntstdio.o Release/text_editor.o Release/text_history.o Release/vtrecv.o Release/vtsend.o Release/RF24.o Release/RF24Network.o Release/Sync.o Release/main.o Release/mbed_flash_api.o Release/mbed_gpio.o Release/mbed_lp_ticker_api.o Release/mbed_pinmap_common.o Release/mbed_sleep_manager.o Release/mbed_ticker_api.o Release/mbed_us_ticker_api.o Release/mbed_application.o Release/mbed_assert.o Release/mbed_board.o Release/mbed_critical.o Release/mbed_error.o Release/mbed_interface.o Release/mbed_mem_trace.o Release/mbed_mktime.o Release/mbed_sdk_boot.o Release/mbed_semihost_api.o Release/mbed_stats.o Release/mbed_wait_api_no_rtos.o Release/stubs.o Release/ATCmdParser.o Release/CallChain.o Release/FileBase.o Release/FileHandle.o Release/FilePath.o Release/FileSystemHandle.o Release/LocalFileSystem.o Release/mbed_alloc_wrappers.o Release/mbed_poll.o Release/mbed_retarget.o Release/mbed_rtc_time.o Release/mbed_wait_api_rtos.o Release/Stream.o Release/analogout_api.o Release/can_api.o Release/gpio_api.o Release/gpio_irq_api.o Release/hal_tick_16b.o Release/hal_tick_32b.o Release/i2c_api.o Release/lp_ticker.o Release/mbed_overrides.o Release/pinmap.o Release/port_api.o Release/pwmout_api.o Release/rtc_api.o Release/serial_api.o Release/sleep.o Release/stm_spi_api.o Release/trng_api.o Release/us_ticker_16b.o Release/us_ticker_32b.o Release/analogin_api.o Release/gpio_irq_device.o Release/pwmout_device.o Release/serial_device.o Release/spi_api.o Release/stm32f1xx_hal.o Release/stm32f1xx_hal_adc.o Release/stm32f1xx_hal_adc_ex.o Release/stm32f1xx_hal_can.o Release/stm32f1xx_hal_cec.o Release/stm32f1xx_hal_cortex.o Release/stm32f1xx_hal_crc.o Release/stm32f1xx_hal_dac.o Release/stm32f1xx_hal_dac_ex.o Release/stm32f1xx_hal_dma.o Release/stm32f1xx_hal_eth.o Release/stm32f1xx_hal_flash.o Release/stm32f1xx_hal_flash_ex.o Release/stm32f1xx_hal_gpio.o Release/stm32f1xx_hal_gpio_ex.o Release/stm32f1xx_hal_hcd.o Release/stm32f1xx_hal_i2c.o Release/stm32f1xx_hal_i2s.o Release/stm32f1xx_hal_irda.o Release/stm32f1xx_hal_iwdg.o Release/stm32f1xx_hal_mmc.o Release/stm32f1xx_hal_nand.o Release/stm32f1xx_hal_nor.o Release/stm32f1xx_hal_pccard.o Release/stm32f1xx_hal_pcd.o Release/stm32f1xx_hal_pcd_ex.o Release/stm32f1xx_hal_pwr.o Release/stm32f1xx_hal_rcc.o Release/stm32f1xx_hal_rcc_ex.o Release/stm32f1xx_hal_rtc.o Release/stm32f1xx_hal_rtc_ex.o Release/stm32f1xx_hal_sd.o Release/stm32f1xx_hal_smartcard.o Release/stm32f1xx_hal_spi.o Release/stm32f1xx_hal_spi_ex.o Release/stm32f1xx_hal_sram.o Release/stm32f1xx_hal_tim.o Release/stm32f1xx_hal_tim_ex.o Release/stm32f1xx_hal_uart.o Release/stm32f1xx_hal_usart.o Release/stm32f1xx_hal_wwdg.o Release/stm32f1xx_ll_adc.o Release/stm32f1xx_ll_crc.o Release/stm32f1xx_ll_dac.o Release/stm32f1xx_ll_dma.o Release/stm32f1xx_ll_exti.o Release/stm32f1xx_ll_fsmc.o Release/stm32f1xx_ll_gpio.o Release/stm32f1xx_ll_i2c.o Release/stm32f1xx_ll_pwr.o Release/stm32f1xx_ll_rcc.o Release/stm32f1xx_ll_rtc.o Release/stm32f1xx_ll_sdmmc.o Release/stm32f1xx_ll_spi.o Release/stm32f1xx_ll_tim.o Release/stm32f1xx_ll_usart.o Release/stm32f1xx_ll_usb.o Release/stm32f1xx_ll_utils.o Release/system_stm32f1xx.o Release/PeripheralPins.o Release/system_clock.o Release/AnalogIn.o Release/BusIn.o Release/BusInOut.o Release/BusOut.o Release/CAN.o Release/Ethernet.o Release/FlashIAP.o Release/I2C.o Release/I2CSlave.o Release/InterruptIn.o Release/InterruptManager.o Release/RawSerial.o Release/Serial.o Release/SerialBase.o Release/SPI.o Release/SPISlave.o Release/Ticker.o Release/Timeout.o Release/Timer.o Release/TimerEvent.o Release/UARTSerial.o Release/mbed_boot.o Release/mbed_rtx_handlers.o Release/cmsis_os1.o Release/RTX_Config.o Release/rtx_delay.o Release/rtx_evflags.o Release/rtx_evr.o Release/rtx_kernel.o Release/rtx_lib.o Release/rtx_memory.o Release/rtx_mempool.o Release/rtx_msgqueue.o Release/rtx_mutex.o Release/rtx_semaphore.o Release/rtx_system.o Release/rtx_thread.o Release/rtx_timer.o Release/rt_OsEventObserver.o Release/EventFlags.o Release/Mutex.o Release/RtosTimer.o Release/Semaphore.o Release/Thread.o Release/mbed_rtx_idle.o Release/irq_cm3.o Release/startup_stm32f103xb.o -Wl,end-group 1> ------------- 1> Command exited with code 2 1> Executable: D:\Keil_v5\SysGCC\bin\make.exe 1> Arguments: CONFIG=Release -j4 1> Directory: F:\00_SOFTWARE\cmnode\cmnode 1>VisualGDB : error : Command-line action failed 1>VisualGDB : error : Build has failed. See the Output window for more details. 1>C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V140\Microsoft.MakeFile.Targets(37,5): error MSB3073: 命令“"D:\Program Files (x86)\Sysprogs\VisualGDB\VisualGDB.exe" /build "F:\00_SOFTWARE\cmnode\cmnode\cmnode.vcxproj" "/solution:F:\00_SOFTWARE\cmnode\cmnode.sln" "/config:Release" "/platform:Win32"”已退出,代码为 1。

==== 生成: 成功 0 个,失败 1 个,最新 0 个,跳过 0 个

THE .LD file

/* Linker script to configure memory regions. */ MEMORY { FLASH (rx) : ORIGIN = 0x08000000, LENGTH = 256K /*128K*/ RAM (rwx) : ORIGIN = 0x20000130, LENGTH = 48K - 0x130 /* 20K - 0xEC 130*/ }

Be the first to answer this question.