EMon v2.09 Short user guide EMon is a Disassembler program for SAM Coupe. This version (2.09) is completely share ware and it's full version so you may use it and spread it if you want to. But if you like this program please send equivalent of `2 to Maciej Woloszyk Swietopelka 20/25 87-100 Torun Poland EMon is copyrighted to ESI and it's author MAT of ESI. First a few words about how to start with EMon. If you have 512K machine you must load it as normal CODE file. On 256K you have to prepare working version first. To do it you must type in: MERGE "EMON2_0"CODE 245760 SAVE OVER "EMON2_0"CODE 245760,LENGTH,245760 where LENGTH is number you first read from directory. Of course you may rename this file to "AUTO*" and then load it simply by pressing F9. After you load EMon you'll see copyright note and scrolling text "PRESS ANY KEY TO START...". Do it, and you'll go to EMon. When you're in, you can see part of disassembled memory. It starts from address called MEMBAS, and you may change it using: CURSUR UP - by one byte (or line in text mode) CURSOR DOWN - by one line CURSOR LEFT - by eight bytes (or lines) CURSOR RIGHT - by eight lines M - set MEMBAS to required address (0-65535) To change display mode use following commands: A - switch between ASSEMBLER and ASCII SHIFT+A - switch between ASSEMBLER and TEXT H - switch between DECIMAL and HEX When you're entering number (such as M command) and you're in HEX mode you may delete '&' mark and enter DEC number, and in DEC mode you may enter HEX number by entering '&' (it's also on F6 key). You may also enter single character as number using '$' mark first. And one more key is F0 which let you to enter current MEMBAS value. EMon let you to look into SAM memory, but it works just like Z80 - you may see only 65536 bytes. To work with all memory you use paging registers and in EMon you must do it exactly the same way. Lower Memory Page Register is key F1, and Higher Memory Page Register is F2. Next what you can do with EMon is searching memory. You may search both texts and bytes strings. To look for text you use T command. To look for bytes string use S command. When you enter all bytes you want to search just press RETURN. During entering number for searching you may press F5 what gives you 'MSK' text. It mean, that in this position may appear any byte. You may escape searching by ESC. To search the same item again simply press N. Now how to change memory content. You may use P command which works exactly like BASIC POKE command - first enter address, press RETURN then enter value you want and press RETURN again. If you want to POKE a few bytes starting from MEMBAS simply press SHIFT+P and then you don't need to enter address but only values. To finish it press ESC. You may also enter short texts (one line) using I command (it's entering starting from MEMBAS). Next two command are C - copy block and F - fill block of memory. First enter block start address then destination address and block length for copy or start address, length and value to fill with for fill (ESC terminate both fill and copy). There are two commands you may recount numbers from one system to another. D command let you change number from DEC to HEX, from HEX to DEC or from ASCII to DEC and HEX. B command let you to change DEC, HEX or ASCII to BIN. Of course you may load any data from disk. To select drive you want to use press SHIFT+D. To read a few sectors use SHIFT+R (sides are 0 or 1), to write use SHIFT+W. Last two commands works exactly like READ AT and WRITE AT from BASIC, but SHIFT+R will read real length of sectors not always 512 bytes. Last disk command is SHIFT+L. It let you to load block from disk when you know it's first sector and track numbers. But remember, that you're working on 64K and longer blocks will wrap in memory. BTW if you don't know, block is the number of sectors when each one has number of track/sector of next one in it's last two bytes (this is the way DOS works). Using EMon you may simply analyse programs with two keys. First is F7 which let you to change MEMBAS to address which is determined by first disassembled instruction. For example: you're looking at the program 13567 CD3D5C CALL 23613 Normally to check this subroutine you have to press M then 23613, check it and then... where was this CALL ??? With EMon it's no problem. Simply press F7, and you move to your subroutine check it and simply press F9 to return to place you jump from. You may use F7 twenty times and be sure that after twenty F9 you'll return to begin. If you use F7 more than 20 times first addresses will be lost. But F7 not only CALLs or JUMPs. You may also work with JR,DJNZ,RST and all other (which works just like call). To make work easier there are eleven POINTERS. Pointer is address you may go to using SYMBOL+number from 0 to 9. To set any pointer at MEMBAS simply press F3 and enter number of pointer you want to set. But 0 to 9 it's only ten pointers. There is one more you may set using SYMBOL+'.' and go to using just '.'. There is one more thing in EMon. You can see note in lower part of screen. It's not only note for you. You may use this place as simple and short notepad. Press space and you'll see cursor. You may use almost all normal editing keys with it. To exit notepad press ESC. To clear all note press F0 and to clear line with cursor press F1. You may also copy note to memory using F4 (all note is 256 bytes long). And that's almost everything about EMon. One more command is Q which let you to QUIT EMon. Now you may start working with this program. If you have any problems or something just write to me (my address is in this guide and in EMon). Good work with EMon wish you Maciej Woloszyk MAT of ESI Torun 1999-09-21