Hey, I don't find a solution to "mergehex" the softdevice with my application in linux. Is there any way to do this in Linux?
Hey, I don't find a solution to "mergehex" the softdevice with my application in linux. Is there any way to do this in Linux?
The reason you don't need a utility is that standard Linux tools+ scripting do this sort of thing very well.
Try something like:
#! /bin/sh
#
# Combines the Nordic s120 stack and app hex files and generate a
# combined binary.
# Stack at 0k, app at 96k
set -e -x
STACK_HEX=s120.hex
STACK_BIN=s120.bin
APP_HEX=app.hex
APP_BIN=app.bin
COMBINED_BIN=app.bin
objcopy -O binary -I ihex $STACK_HEX $STACK_BIN
objcopy -O binary -I ihex $APP_HEX $APP_BIN
dd if=/dev/zero ibs=1024 count=128 | tr "\000" "\377" > $COMBINED_BIN
dd if=$STACK_BIN of=$COMBINED_BIN bs=1024 seek=0 conv=notrunc
dd if=$APP_BIN of=$COMBINED_BIN bs=1024 seek=96 conv=notrunc
Any updates on this?
Any updates on this?