ARM tool (assembler, disassembler, emulator) developing - DSLR Hack development - CHDK Forum  

ARM tool (assembler, disassembler, emulator) developing

  • 39 Replies
  • 49564 Views
ARM tool (assembler, disassembler, emulator) developing
« on: 26 / April / 2010, 21:13:39 »
Advertisements
I started to develop a tool yesterday to help ARM firmware developing.
The IDA Pro is just too expensive for a lot of people...

ARMu (at this moment) can disassemble ARM binary files, automatically generates labels for subroutines, local branches, data words. It can get names from IDC files, so you can use the previous CHDK .idc files.
It handles segments, you can load more memory area at the same time.

Feature plans:
- Assembler
- Emulator (run commands step by step)
- Firmware file generator

If you could help with testing please send me a message.
Thoughts, ideas, opinions are welcome.

pelican
pel.hu

*

Offline OldGit

  • ****
  • 303
Re: ARM tool (assembler, disassembler, emulator) developing
« Reply #1 on: 27 / April / 2010, 00:51:51 »
@pelican
ambitious project, good luck with it, I am sure many would find this very useful.

What operating system are using, linux ?
OldGit
SX200 IS-100C

Re: ARM tool (assembler, disassembler, emulator) developing
« Reply #2 on: 27 / April / 2010, 09:42:33 »
It's Windows...

Re: ARM tool (assembler, disassembler, emulator) developing
« Reply #3 on: 27 / April / 2010, 10:49:02 »
Another attempt: http://chdk.setepontos.com/index.php/topic,3393.15.html

Some useful features would be:
  • back/cross references (and jumping between them)
  • support for constants (i.e. those that do not fit in an instruction)
  • support for strings
  • searching for byte sequences (strings and hex at least)
  • being able to add/change labels (and have references use them)
  • comments
  • list of {strings,functions,...}
  • some way to achieve the same as the IDA signatures and scripts for CHDK

I'm not so sure about the use of an assembler, emulator or firmware generator (at least w.r.t. CHDK).

Looking at the screen shot, I suggest using a fixed-width font for at least the first three columns (but why not for all of them?); that should be a bit easier on the eyes.

I don't know what your developing this in, but if you use .NET your tool might also be used on other platforms (with Mono). Something that would be worth mentioning.



Re: ARM tool (assembler, disassembler, emulator) developing
« Reply #4 on: 27 / April / 2010, 14:50:05 »
Thank you.
1: OK
2,3: What do you mean support of strings and constants?
4: OK
5: Working
6: Yes maybe useful
7: OK
8: It reads/writes IDA idc (dump database) files. I don't know the sig structure...

The assembler is not really important, but I think an emulator can accelerate the reverse engineering or at least to understand the code.
The font is not perfect I know but I didn't find better yet, it's a semi-fixed... :)


Re: ARM tool (assembler, disassembler, emulator) developing
« Reply #5 on: 27 / April / 2010, 17:05:03 »
2,3: What do you mean support of strings and constants?
An alternative for DCD in case of (ASCII) strings so you don't have to read across the text column:

Hello world.. | ASC "Hello world\n"

instead of

4.He | DCD 0x65481234
llo  | DCD 0x206f6c6c
worl | DCD 0x6c726f77
d..Q | DCD 0x51000a64


And with constants I refer to (the c in) instructions like LDR Rn, [PC, o] that are typically written as LDR Rn, =c (with c the value at PC+o).

Quote
The assembler is not really important, but I think an emulator can accelerate the reverse engineering or at least to understand the code.
The problem with an emulator is that I don't see how you'd make it work good enough to be of use. You essentially have to implement the all the relevant hardware in software to get anything useful out of it. Or am I missing something?

*

Offline fe50

  • ******
  • 3147
  • IXUS50 & 860, SX10 Star WARs-Star RAWs
    • fe50

Re: ARM tool (assembler, disassembler, emulator) developing
« Reply #7 on: 28 / April / 2010, 13:38:35 »
Thanks.
I've refreshed the screenshot.


Re: ARM tool (assembler, disassembler, emulator) developing
« Reply #8 on: 29 / April / 2010, 05:35:36 »
Two things: LDR R0, =#0x1928 should be LDR R0, =0x1928 and I wonder how you deal with data that is not aligned to dword boundries.

Re: ARM tool (assembler, disassembler, emulator) developing
« Reply #9 on: 29 / April / 2010, 09:56:51 »
Thank you!  Fixed.
What do you suggest?

 

Related Topics