Important changes to forums and questions
All forums and questions are now archived. To start a new conversation or read the latest updates go to forums.mbed.com.
9 years, 11 months ago.
Generate .bin(only about 10KB) instead of .hex file after test
First I build target NRF51822 then I using workspace_tool for testing python make.py -m NRF51822 -t GCC_ARM -p 0 then Successfully create directory: MBED_A1 And command line show image: basic.hex , but actually only generate the basic.bin file, and only have about 10KB, not included softdevice I guess.
Does anyone know what's going on?
Question relating to:
1 Answer
9 years, 11 months ago.
Hi,
can you share the output from the make?
This is from the makefile for your platform:
$(PROJECT).hex: $(PROJECT).elf @$(OBJCOPY) -O ihex $< $@ $(PROJECT).lst: $(PROJECT).elf @$(OBJDUMP) -Sdh $< > $@ lst: $(PROJECT).lst size: $(SIZE) $(PROJECT).elf DEPS = $(OBJECTS:.o=.d) $(SYS_OBJECTS:.o=.d) -include $(DEPS) merge: $(SREC_CAT) $(SOFTDEVICE) -intel $(PROJECT).hex -intel -o combined.hex -intel --line-length=44
There should be hex file and then use merge command to merge softdevice with the application (I havent used this makefile for a while, so just interpreting what's there)
Thanks very much for reply. I can't find my makefile, so I post the output:
[WARNING] Using default settings. Define your settings in the file "workspace_tools/private_settings.py" or in "./mbed_settings.py" Building project BASIC <NRF51822, GCC_ARM> compile: main.cpp Compile: test_env.cpp Link: basic Elf2Bin: basic Image: ...\build\test\NRF51822\GCC_ARM\MBED_A1\basic.hex
But only basic.bin is generated. Do I need any mbed API to convert .bin to .hex automatically?
posted by 15 Dec 2014