Jun 1, 2015

ICU64 for Frodo Redpill v0.1.6 - Released

The creation of memory maps gets easier with this release.

New features in the memory view:

BASIC program layout
Load or type a BASIC program and hit ctrl-L in the memory view to watch the memory map of its code. After RUN, you have to press ctrl-L periodically to update that map, because a running BASIC program updates the layout of the data area (which is located after the code area) as it meets new variables for the first time. Enable the text view (ctrl-A) to get a more meaningful view (or type LIST in the emulator but this is like cheating!)

Data Classification (Order In Chaos)
The data classification view colorize the memory in a chaotic still consistent way. And using only your pattern recognition abilities you can organize the data even if you don't understand their meaning!
So far, watching the internals of the C64 in action may was something, yet you may have this feeling: "wow! I see everything :) but still I understand almost nothing :(". Well, the new feature lets the CPU to interpret  to us the meaning of the data using a color language. And no, you don't have to learn another color code, since these colors are meaningless this time (it's just a meaningless 'alphabet'). What's important is their patterns (i.e. the 'words' and 'phrases' that they form). These patterns are not the usual data patterns (as in the grayscale view), they are event patterns arranged in space that highlight the internal structure of the data as being used by the code (who always knows their meaning, and this is where we rely).
More particular, this visualization is based on 'what code access what data', and actually it's a simple hash function of the "last access" address that located in the upper left corner of every cell (visible in deep zoom). So, actually, this information was always there in a numerical/textual form, proper only for serial/boring reading. By translating this information into colors, patterns emerge (from chaos!) that can be recognized immediately by the human brain in parallel way, and organized manually. This view is especially useful to find large internal structures like arrays or lists of data, and analyze their entries down to their most individual parts.

Map Editing
Some new functions that will help you with your memory maps:
    Enter / Shift-Enter                  : Split / Join line
    Backspace / Shift-Backspace    : Move line Left / Right

(the above operations never overwrite non empty cells)
    Delete / Shift-Delete                : Delete cell / line
    right click / Insert*                  : Pick cell / Put cell++ 

    F2*                                       : Rename cell (change address)
Note that the editing functions are minimal yet, and they are line oriented. If you want to move blocks around you must export the map and use some spreadsheet application.
 * edit: bugs found on these operations that may mess your map, so avoid them

Drag 'n' Drop
If you drop a .txt file in the memory view, it will open as a memory map. Any other file will be imported as a .prg file (i.e. will be loaded in the RAM at the location that the first two bytes specify). BTW, the Frodo Redpill window accepts .fss files (Frodo snapshots).

Press F1 on every window (even in the main menu) to see more functions.

You can also download some generic memory maps that may help you. Especially the RAM only map, it's a good start point to create the map of a game.

How to create a memory map, in practice:
- start a game in the emulator and wait until it gets into its main loop
- from the memory view of icu64, import (ctrl-i or drag'n'drop) the RAM only map (so you don't mess with the ROM and the MMIO while editing the map)
- press shift-ctrl-X to clear the colors and thus start a new log (do this at any time)
- (optional) switch to view '1' or '3' (cpu events) and play with the game for a while until you locate its code areas to remove them (since the data classification is meaningless with the code parts). Use 'shift-delete' to delete entire lines.
- switch to view '2' (vic events) to find the bitmaps, text screens, charsets, and sprites, all of which have 'standard' layouts usually (the graphics view will help you with this).
- switch to view '4' (data classification) and play with the game as much as possible, so the code to exploit  much (if not all) of its data. As you start seeing similar patterns in the memory view,  hit 'enter' over the beginning of each pattern to send it to a new line. The goal is to align the similar patterns vertically. To join two lines, hit 'shift-enter' on the first line.
- if some colors are very similar, hit '0' to get a different set of colors
- note that even with an incomplete map, you can probably locate lists of pointers/offsets (they have very characteristic patterns) to the patterns you have found so far, and this way you can find ALL the addresses of the entries in a list/table/etc.
- to neat your map export it (ctrl-O) as a text file, open it with Notepad, and copy everything or a part. Start a new sheet on Excel, select all of its cells and mark them as 'Text' (ctrl-A > right click > Format cells > Text). Paste the map to the sheet and do your edits (e.g. move blocks around). Finally, copy & paste everything  back to Notepad, save the map, and import it again to icu64.
- enjoy the new view!

Oct 28, 2012

ICU64 for VICE 2.3 v0.1.2 - Released

An update of the ICU64 for the VICE emulator is available for download (you also need the VICE 2.3 emulator). There are no new features, only better functionality. My goal is to inject the REDPILL into the VICE, so more features could be supported in the future. I'm working on it...
(see the included readme file for instructions)

Note for programmers:
This time I modified the VICE source code to fix the bank issues of the memmap feature (the mod is here).

EDIT: I forgot to fix the zoom-out crash bug that occurs in the 64-bit versions of Windows. A patch is available in the download page.

Sep 30, 2012

ICU64 for Frodo Redpill v0.1.5 - Released

Eventually, after 3 years, a new version of ICU64 is ready for download. Several bugs and issues have fixed, additional functionality and features have added. Note however, that this version is not the one that I was working on the last years (i.e. v0.2). This is only an update of the initial release, where I have paste as much code as I could from v0.2 without corrupting the functionality. My goal is to make the raster view equally significant with the memory (matrix) view, so the development is being continued...

Report any bug/issue/request in the comments or via e-mail.

Good hack!

Sep 16, 2010

Release Delay

Unfortunately, the cleanup task of the Frodo Redpill source code was underestimated. More time is needed before it's released. Also, the changes have effects to the ICU64, which has a GREAT progress these days, after a year of suspension.

The pending releases are:
- a great new version of ICU64 / Frodo Redpill
- the source code of Frodo Redpill
- sample code (C++/C#/Mathematica) that handles Frodo Redpill

I'll try to make them available as soon as possible and, in any case, before the 2011.

My apology to all those who follow this project
and they were waiting for a new release now,


Feb 26, 2010

Interview in Commodore Free Magazine

The Commodore Free Magazine is a free electronic magazine dedicated to the Commodore. Some days ago, Nigel Parker (the editor) asked me for an interview about my project. So if anyone looks for information about the ICU64, they can be found on the current issue (Issue 37).

I would like to thank Nigel Parker for his questions because they really pushed me to think some things better. Also I want to thank him for his patience because my text was full of spelling errors and several corrections had to be made.

Any comment or question after reading the interview is welcome.

Sep 30, 2009

Custom Display for Paradroid

A hack for the game Paradroid (1985):

(watch in full-screen)

This game is set on a spaceship with 20 decks. There is an off-screen with a full deck, somewhere in the RAM, but only a small part of it is visible on the display while playing. ICU64 reads directly from the off-screen and visualizes it whole in a custom display.

This case wasn't so trivial as was the 'Boulder Dash':

(read more on this and other future applications at lemon64)

Paradroid uses sprites (in a swap mechanism) and splits the screen using raster effects. But it's done now, proving that any game can be hacked like this.

(During this hack several missing features from ICU64 were pointed out and they are on their way now)

Sep 12, 2009

ICU64 for VICE 2.1

It was asked by many, so here it is:

ICU64 for VICE 2.1 
- a PC with Windows XP and .NET Framework 2.0
- the WinVICE 2.1 emulator

Have fun! 
(Read the included README.TXT for the installation instructions)

In this version ICU64 operates as a common debugger over the x64 process. This approach reduces the features that can be supported, in comparison to the Frodo Redpill version. But since it is slightly newer, it has some more functionality and some bugs are fixed. The notable addition is a simple 'memory scanner'.

Also, this version can be connected with other C64 emulators. However, the procedure to do this is a little hard, for safety reasons.

The included file 'x64mm.exe' comes from a recompilation of the VICE 2.1 source code with the -memmap option. (The source code is NOT altered this time, in contrast to the Frodo version). With this option, the x64 tracks the memory accesses made by the CPU (unfortunately with some issues: some RAM accesses reported incorrectly by the x64 as ROM accesses).

I hope that the VICE team will notice the possibilities, so that one day they fully expose the C64 virtual machine to the external applications.