at67 emulator

Using, learning, programming and modding the Gigatron and anything related.
Forum rules
Be nice. No drama.
at67
Posts: 129
Joined: 14 May 2018, 08:29

Re: at67 emulator

Post by at67 » 31 Jan 2020, 08:28

Ok I've built a 32bit version, attached relevant configuration and sample files and packaged them into a Zip file.

https://www.dropbox.com/sh/svotvu16txpt ... Ogbha?dl=0

I'm very confident that my machine is virus/malware free, but I can't guarantee it as I am connected to the internet. Therefore I take no responsibility for anything bad that happens to your machine, everything you do with this Zip is of your own free will :) So please scan it before running it!

With that out of the way: I tested this on a Win32 Win7 machine and it worked fine, the only issue was that the Visual Studio runtime was not installed on that laptop and hence upon initial startup I received a "Application could not start 0xC000007B" error.

Classic Windows error :/

If that happens to you, go here https://support.microsoft.com/en-au/hel ... -downloads and download and install this file : vc_redist.x86.exe

It's about 14MBytes and contains the VS 2015-2019 DLL's that are required.

dwesti
Posts: 15
Joined: 31 Jan 2020, 05:37

Re: at67 emulator

Post by dwesti » 31 Jan 2020, 08:49

it works \o/
Thank you very much

dwesti
Posts: 15
Joined: 31 Jan 2020, 05:37

Re: at67 emulator

Post by dwesti » 31 Jan 2020, 08:52

What version used as "test.rom"? I suppose it is v3. Can I rename v4 to test.rom?

at67
Posts: 129
Joined: 14 May 2018, 08:29

Re: at67 emulator

Post by at67 » 31 Jan 2020, 09:07

Stable ROM's are always built into the executable, so the executable you have has ROM's V1 to V4 built in, to access them you press CTRL+R, (CTRL+H displays a help screen).

When the ROM list pops up you'll see Grey ROM's and White ROM's, (the asterisk in the emulator GUI marks the currently selected ROM), Grey are internal, White are external. You can add external ROM's by editing the 'loader_config.ini' file.

Add whatever test ROM you want by copying it to the same directory as your executable, (or you can make a ROM directory, just make sure to get the paths correct), then add an entry into the INI file like so:

e.g.

Code: Select all

[ROMS]
RomName0    = ROMv3y.rom
RomType0    = 0x28
RomName1    = dev.rom
RomType1    = 0xf8
RomName2    = dev_irq.rom
RomType2    = 0xf8
RomName3    = test.rom
RomType3    = 0xf8
You need to get the path to the ROM correct, the RomType field is not important, it's just for display purposes.

dwesti
Posts: 15
Joined: 31 Jan 2020, 05:37

Re: at67 emulator

Post by dwesti » 31 Jan 2020, 10:27

There are some issues with build. Emulator chrashes on pressing Alt+F5 and responds to Ctrl+H very slow.

at67
Posts: 129
Joined: 14 May 2018, 08:29

Re: at67 emulator

Post by at67 » 31 Jan 2020, 11:22

What sort of computer/GPU do you have? The help screen is a simple full screen quad texture with an Alpha channel that is quickly faded in and out. On every PC I have tried it on, (even 8 year old laptops), it works fine.

You shouldn't be using ALT-F5 or CTRL-F5, they are for executing code at specific addresses, (ALT talks to real hardware). The ALT functions won't work until you setup an Arduino with a COM port to your real Gigatron hardware. You also have to configure loader_config.ini

Normally what you want to do without real hardware hooked up to the emulator is just left click on a file in the Browser, (CTRL + B). This will execute it automatically in the emulator.

The emulator understands *.gt1, *.gt1x, *.asm, *.gasm, *.gbas *.gtb and *.gcl files, it will do everything it needs to do, to build and execute each type of file automatically.

But for *.gcl files and *.gtb files you must configure the path in loader_config.ini to your gigatron-rom tools, like this:

Example for Windows: (obviously change the path to suit your directory structure).

Code: Select all

GclBuild = D:/Projects/Gigatron TTL/gigatron-rom  ;must be an absolute path, can contain spaces
Example for Linux: (obviously change the path to suit your directory structure).

Code: Select all

GclBuild = /ubu/home/gigatron-rom  ;must be an absolute path, can contain spaces
For MacOS, /shrug who knows :?:

P.S. You also have to have Python 3 installed and the gigatron-rom tool suite contained within it, up and running to be able to compile and execute *.gcl and *.gtb files. You get the gigatron-rom repo from here: https://github.com/kervinck/gigatron-rom

dwesti
Posts: 15
Joined: 31 Jan 2020, 05:37

Re: at67 emulator

Post by dwesti » 31 Jan 2020, 13:19

Intel Core i3-2100 3.10GHz+Intel HD Graphics Family

Finally, I assemble one xD
xor_ttl.zip
(631 Bytes) Downloaded 105 times

at67
Posts: 129
Joined: 14 May 2018, 08:29

Re: at67 emulator

Post by at67 » 31 Jan 2020, 13:34

Nice start, very psychedelic!

dwesti
Posts: 15
Joined: 31 Jan 2020, 05:37

Re: at67 emulator

Post by dwesti » 31 Jan 2020, 17:39

just a question:
where to read about registers X,Y and opcodes ?
http://www.iwriteiam.nl/PGigatron.html

at67
Posts: 129
Joined: 14 May 2018, 08:29

Re: at67 emulator

Post by at67 » 31 Jan 2020, 21:16

These are Native registers and opcodes, so you should probably start a new thread for this subject; but here is some reading material and suggestions:

https://gigatron.io/media/gigatron-hackerhotel.pdf
https://cdn.hackaday.io/files/207818890 ... -11-25.pdf
https://hackaday.io/project/20781-gigat ... subroutine

- Study the ROM *.lst files in the gigatron-rom repo.
- Study the native code examples *_ntv.gasm in my .gasm samples

VCPU:
- VCPU code runs from RAM.
- VCPU code is 16bit.
- VCPU code executes in a Von Nuemann architecture, (.gasm, .gcl, .gbas, etc).
- All applications are coded in VCPU, whether directly through assembly, or indirectly through compilers and interpreters.
- You can build/run VCPU code in a myriad of ways, assemblers, GCl compiler, BASIC/C compiler, BASIC interpreter, etc.

Native:
- Native code runs from ROM.
- Native code is 8bit.
- Native code executes in a Harvard architecture.
- You use Native code when creating new ROM's or creating new SYS functions for new ROM's.
- You can build Native code in one of only two ways that I am aware of:
1) Use Marcel's Python tools to build new Native ROM's.
2) Use my assembler to build new SYS functions or ROM's.
- You can test new Native code ROM's or SYS functions in my emulator, it can load different ROM's, but it can also load and execute SYS functions to it's fake ROM for testing, (check out the *_ntv.gasm examples).

P.S. A SYS function is an extension written in Native code, (so it must live in ROM), that VCPU code can call for extra speed or low level functionality that VCPU code is unable to provide. It has limitations in it's size and and cycle count and has a calling convention that you must adhere to, once again check out the *_ntv.gasm examples.

Post Reply