How to send C program argument(argv) when using openocd command

81 Views Asked by At

I was running openocd command as below

openocd -f interface/cmsis-dap.cfg -f target/max78000.cfg -s /home/Desktop/Tools/OpenOCD/scripts/ -c "program ./build/main_0.elf reset exit"

Now I want my main_0.elf to run with arguments, such as

./build/main_0.elf -t 2 3

How should I run openocd command to make sure the target .elf file run with given argument?

0

There are 0 best solutions below