English Amiga Board


Go Back   English Amiga Board > Coders > Coders. General

 
 
Thread Tools
Old 06 September 2001, 19:03   #1
Uukrul
 
Posts: n/a
Arexx script (txt => hex)

I have a big problem. With my new A600 I can only transfer text files with the command 'type'.

'Type' coming with Workbench 2.04 cuts binary files, so I can't transfer any program to the Amiga (I only have Workbech 2.04 disks)

The only solution Akira has pointed me is use an Arexx script that converts a text into hex.

For example:

text=>

3C21444F4354

into

bin=>

<!DOCT

I can write a Delphi program that translate hex chars of a binary file into a text file like above. Then transfer that text file with 'type ser: >ram:file' and convert it with the Arexx script.

Is possible write such script?

Thanks in advance and excuse my weird english.
 
Old 06 September 2001, 23:49   #2
Amiga1992
Registered User
 
Join Date: May 2001
Location: ?
Posts: 19,645
Hmm.. Now taht I remember, I think Khephren once mentioned an option in Type that could make you dump an HEX file.

Kheph, can it be done?
Amiga1992 is offline  
Old 07 September 2001, 01:52   #3
Uukrul
 
Posts: n/a
With the option HEX 'type' dumps a text file with the hex value of the chars of the file passed as parameter (like a hex editor).
 
Old 07 September 2001, 05:03   #4
Amiga1992
Registered User
 
Join Date: May 2001
Location: ?
Posts: 19,645
and that means... ?

ah, instead of garbage, you get the hexa. right?
Amiga1992 is offline  
Old 07 September 2001, 05:17   #5
Uukrul
 
Posts: n/a
I get the same garbage but in hex format
 
Old 08 September 2001, 07:46   #6
Uukrul
 
Posts: n/a
After learning some Arexx programming, I've found a solution =>

Here goes the script:


/* TXT2HEX */

SAY "ESPERO QUE FUNCIONES MAMONAZO"

NameFile_Out = "type2"

CALL OPEN("LogFile_Out", "RAM:"||NameFile_Out, "W")

WRITECH("LogFile_Out", "EF"x"00"x"34"x"4F"x) /* Here goes the hex values of the binary file (EF 00 24 4F .....) */

CALL CLOSE("LogFile_Out")

SAY "OK"


Now I'm writing a Delphi program that gives me the WRITECH("....... "HEX VALUES") complete line(s) of the file I want to transfer (this is the 'type' command of WB 1.2 (2176 bytes long))

So, I'll transfer the complete script without problems coz is a text file and execute it with the Amiga to obtain a working 'type2' file.

If someone is interested in the Delphi program just drop a reply.

I need some sleep, now 7:45 AM at Spain
 
Old 08 September 2001, 19:03   #7
Amiga1992
Registered User
 
Join Date: May 2001
Location: ?
Posts: 19,645
wow, you learned pretty fast or something? I never got to those levels.

Do you have a clue where I could find some AREXX guide, or something to learn it, on the net?
Amiga1992 is offline  
Old 08 September 2001, 19:35   #8
Uukrul
 
Posts: n/a
Google is the best

Here you'll find an amiga guide pretty good.

http://www.amigarealm.com/computing/nkb11.htm

, here

http://www.halcyon.com/robin/www/arexxguide/main.html

another reference manual, but the above link is a lot better

and here

http://www.amigarealm.com/resources/coding/pr3.htm

more Arexx links (mostly useless)

I love programming and cracking MS-DOS games , as a matter of fact my first cracked game was The Dark Heart of Uukrul (I lost copy protection runes of my original copy)

- I cracked myself
 
Old 08 September 2001, 19:53   #9
Amiga1992
Registered User
 
Join Date: May 2001
Location: ?
Posts: 19,645
Thanks a million! I got to get learning AREXX again )
Amiga1992 is offline  
Old 09 September 2001, 02:07   #10
Amigaboy
 
Posts: n/a
hehe. The way I learnt Arexx is by reading the Arexx manual. I think it comes with Workbench 3 and above, but possibly Workbench 2 as well
 
Old 09 September 2001, 04:02   #11
Amiga1992
Registered User
 
Join Date: May 2001
Location: ?
Posts: 19,645
Nope, it doesn't ... Perhaps 2.1 had it (since 2.1 is 3.0 without the AGA bits )

I wouldn't be asking for a manual if I had it!
Amiga1992 is offline  
 


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Similar Threads
Thread Thread Starter Forum Replies Last Post
Problem executing DOpus5 Arexx Script ... beltrixx support.Apps 1 01 August 2015 22:16
Little hex editing help please Aria support.Games 4 16 June 2011 20:20
Hex Comp mai support.Other 2 28 May 2010 20:00
Hex to Decimal -Rob- Coders. General 8 21 June 2006 19:22
Hex Editor Help misguided_fool request.Apps 5 22 March 2006 09:53

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 13:53.

Top

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Page generated in 0.10205 seconds with 13 queries