This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Convert .axf into a .bin that only includes 0 & 1 digits

Hi,

I'm using Arm Development Studio Gold Edition 2022.2

I was using the "fromelf" utility with "--bin" option (for a plain binary) to convert a given .axf file into .bin file.

However i would like to know with your help how to convert my .axf or.bin file into a binary that only includes 0 & 1 digits?
Something like "hex2bin" utility, that convert hex digits into binary digits?


Thanks,

Ronen

  • Hi Ronen

    I'm not aware of any Arm-provided tool that can do this.  If hex2bin works for you then I suggest you use that.

    Perhaps I've misunderstood, but the picture you gave doesn't seem to show the correct conversion,
    e.g. the first hex digit '4' should be transformed into binary digits '0','1','0','0', not '1','1','0','1' ?

    Can you explain why you want to do this?  Surely the resulting file will be 8-times larger than the original...

    Stephen

  • Hi Stephen,

    Thanks for your reply.


    I admit the picture i gave was not much helped.
    I meant for the data on the right side, pls see below picture

    This requirement arrived from a third party which i'm working with (TSMC).

    BR,
    Ronen

  • Thanks for the pictorial clarification :)

    As I wrote before, I'm not aware of any Arm-provided tool that can do this.

    It should be straightforward for you to write some simple C code or Python script to read bytes from the file, perform the conversion, and write the 0s & 1s to an output file.

    Stephen