Author Topic: [Project]Assemblex  (Read 18784 times)

0 Members and 1 Guest are viewing this topic.

Offline Munchor

  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 6199
  • Rating: +295/-121
  • Code Recycler
    • View Profile
[Project]Assemblex
« on: December 28, 2010, 08:47:42 am »
After getting some work done in the Z80 table, I though: "Why not a HEX to Assembly Converter". I decided to start this project as Python, but I could easily move to C# for a compiled language and integration on tiDE, what do you think of this?

Well, here's a working screenshot.



Note: The program did convert that, I didn't just type it.

Update: the engine is finished, all i need to do now is add opcodes/instructions to finish it
« Last Edit: December 31, 2010, 03:33:39 pm by ScoutDavid »

Offline JosJuice

  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1344
  • Rating: +66/-14
    • View Profile
Re: [Project]Hexadecimal to Assembly Converter
« Reply #1 on: December 28, 2010, 08:54:44 am »
Isn't that a disassembler?

Offline Fast Crash

  • LV4 Regular (Next: 200)
  • ****
  • Posts: 192
  • Rating: +45/-7
  • Virus of tomorrow
    • View Profile
Re: [Project]Hexadecimal to Assembly Converter
« Reply #2 on: December 28, 2010, 08:56:02 am »
yes that is. the reverse should be good also.

Offline Munchor

  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 6199
  • Rating: +295/-121
  • Code Recycler
    • View Profile
Re: [Project]Hexadecimal to Assembly Converter
« Reply #3 on: December 28, 2010, 08:57:13 am »
So, I'm making a disassembler? I hope that's a good thing :S

Offline Fast Crash

  • LV4 Regular (Next: 200)
  • ****
  • Posts: 192
  • Rating: +45/-7
  • Virus of tomorrow
    • View Profile
Re: [Project]Disassembler in Python
« Reply #4 on: December 28, 2010, 08:58:38 am »
yes because there are not many dissassemblers for z80 cpu

Offline Munchor

  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 6199
  • Rating: +295/-121
  • Code Recycler
    • View Profile
Re: [Project]Disassembler in Python
« Reply #5 on: December 28, 2010, 09:09:40 am »


Included a Message Box error for odd HEX input numbers :)

Offline LordConiupiter

  • LV6 Super Member (Next: 500)
  • ******
  • Posts: 339
  • Rating: +3/-0
  • Just one of the thousands of Axe-fans...
    • View Profile
Re: [Project]Hexadecimal to Assembly Converter
« Reply #6 on: December 28, 2010, 09:12:31 am »
nice work! I started coding a Tokenizer and detokenizer today! I'll also post some screenies soon.
everytime that I was down, you would always come around, and get my feedback on the ground. (modified part from 'Seasons in the sun')

No matter how many errors are bothering you, always try to stay rel-Axe!

The HoMM project will be resumed as soon Axe 1.0.0 will be released!
Projects:
Code: [Select]
HoMM:   [==--------]    Project 'resumed': I'm suffering overwhelming new ideas being popped up in my dreams :P
tiDE:   [----------]    Explored and understood the main part of the code: just started writing a Tokenizer.



password of the week: uvanapererubupa (Any pronunciation is the right one ;) )   :D click me, and you'll be raided :D

Offline Munchor

  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 6199
  • Rating: +295/-121
  • Code Recycler
    • View Profile
Re: [Project]Disassembler in Python
« Reply #7 on: December 28, 2010, 09:12:57 am »
nice work! I started coding a Tokenizer and detokenizer today! I'll also post some screenies soon.

For BASIC?

Offline LordConiupiter

  • LV6 Super Member (Next: 500)
  • ******
  • Posts: 339
  • Rating: +3/-0
  • Just one of the thousands of Axe-fans...
    • View Profile
Re: [Project]Disassembler in Python
« Reply #8 on: December 28, 2010, 09:19:00 am »
yes, and with Axe compatibility!
and any tokenized script language!
That's possible since the dictionaries are stored in XML files.
« Last Edit: December 28, 2010, 09:20:37 am by LordConiupiter »
everytime that I was down, you would always come around, and get my feedback on the ground. (modified part from 'Seasons in the sun')

No matter how many errors are bothering you, always try to stay rel-Axe!

The HoMM project will be resumed as soon Axe 1.0.0 will be released!
Projects:
Code: [Select]
HoMM:   [==--------]    Project 'resumed': I'm suffering overwhelming new ideas being popped up in my dreams :P
tiDE:   [----------]    Explored and understood the main part of the code: just started writing a Tokenizer.



password of the week: uvanapererubupa (Any pronunciation is the right one ;) )   :D click me, and you'll be raided :D

Offline Munchor

  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 6199
  • Rating: +295/-121
  • Code Recycler
    • View Profile
Re: [Project]Disassembler in Python
« Reply #9 on: December 28, 2010, 09:20:27 am »
yes, and with Axe compatibility!

Just like Tokens then. Well, adding all the instructions for this program will be really easy, but will take a long time, so I expect to finish a Alpha version in the 1st week of January. Also, has anybody in Omnimaga ever made a disassembler?

Also, I have 1 bug at the moment, the HEX code needs to be all in one line, only problem so far :)

Offline LordConiupiter

  • LV6 Super Member (Next: 500)
  • ******
  • Posts: 339
  • Rating: +3/-0
  • Just one of the thousands of Axe-fans...
    • View Profile
Re: [Project]Disassembler in Python
« Reply #10 on: December 28, 2010, 09:22:03 am »
use the following code:
Code: (c#) [Select]
string HEX = textbox1.Text.Replace("\r\n", "");
EDIT: I voted for the most flexible one: Editable, we can get it in the program itself and in the saved .asm too.
Nobody could have problems with this one, since everything is possible this way, and nothing too :P
« Last Edit: December 28, 2010, 10:10:05 am by LordConiupiter »
everytime that I was down, you would always come around, and get my feedback on the ground. (modified part from 'Seasons in the sun')

No matter how many errors are bothering you, always try to stay rel-Axe!

The HoMM project will be resumed as soon Axe 1.0.0 will be released!
Projects:
Code: [Select]
HoMM:   [==--------]    Project 'resumed': I'm suffering overwhelming new ideas being popped up in my dreams :P
tiDE:   [----------]    Explored and understood the main part of the code: just started writing a Tokenizer.



password of the week: uvanapererubupa (Any pronunciation is the right one ;) )   :D click me, and you'll be raided :D

Offline TC01

  • LV6 Super Member (Next: 500)
  • ******
  • Posts: 344
  • Rating: +9/-0
    • View Profile
Re: [Project]Disassembler in Python
« Reply #11 on: December 28, 2010, 10:56:01 am »
In Python that would be:

Code: [Select]
text = text.replace("\r\n", "")
Also, you'll need (or, at least, probably want) to include a .8xp extractor to get the code out of a .8xp file so it could be ran over .8xp as well as .hex.



The userbars in my sig are links embedded links.

And in addition to calculator (and Python!) stuff, I mod Civilization 4 (frequently with Python).

Offline Munchor

  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 6199
  • Rating: +295/-121
  • Code Recycler
    • View Profile
Re: [Project]Disassembler in Python
« Reply #12 on: December 28, 2010, 11:48:56 am »
In Python that would be:

Code: [Select]
text = text.replace("\r\n", "")
Also, you'll need (or, at least, probably want) to include a .8xp extractor to get the code out of a .8xp file so it could be ran over .8xp as well as .hex.

I may do that after I finish the program, but huh... that was not my original goal, but everybody shouted 'DISASSEMBLER' and now I really have to make one and so I'll do what you asked TC01.

SirCmpwn

  • Guest
Re: [Project]Disassembler in Python
« Reply #13 on: December 28, 2010, 01:59:56 pm »
*-* want for tiDE

Offline Munchor

  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 6199
  • Rating: +295/-121
  • Code Recycler
    • View Profile
Re: [Project]Disassembler in Python
« Reply #14 on: December 28, 2010, 02:02:47 pm »
*-* want for tiDE

SirCmpwn, this is not really an Assembly disassembler, it's more of a HEX text editor that displays the Assembly Code on the right pane.

Do you still need it? (C# Conversion would be easy)