📜 ⬆️ ⬇️

GMC-4 microcomputer

On a tip from Sergei Vakulenko , I bought GMC-4 . Still, in such devices there is some unique charm. Ordered in a fun Japanese gadget store Japan Trend Shop .



GMC-4 is a four-bit micro computer. Computer Features:


The whole architecture is described in one small document - Programming the Gakken GMC-4 Microcomputer .
')
Today my package arrived. GMC-4 is an appendix to one of the issues of Otona no Kagaku magazine published by Gakken, the 24th issue for 2009. The box with the designer is glued to the magazine. Everything is in Japanese.



Funny, on the back of the box are machine instructions GMC-4. Everything fits in one table.



Board, beeper, stand, keyboard fragments and screws.



The instruction in Japanese is tough.



We put the batteries and fix the squeaker.



Pay.





Paste the keyboard.





Turning on ... It's alive! Alive !!!



So: a keyboard, a seven-segment, below it a processor, then a hard reset pipka. Above, seven LEDs, controlled individually. For example, they are used to display the current address. It reminded me all of the UT-88 . In its first modification there was only a seven-segment indicator and a similar keyboard.



Let's try to write something. For example, a simple program that waits for pressing on the keyboard and then displays the code of the pressed button on a seven-segment display.

00: 0 KA 0 ;    (0-F)  A.  ,  Flag=0,  Flag=1. 01: F00 JUMP 00 ;  Flag=1 ( ),    00. 04: 1 AO ;  A     Flag=1 05: F00 JUMP 00 ;  Flag=1 (  1),    00. 

To enter click:

 RESET 0 INCR F INCR 0 INCR 0 INCR 1 INCR F INCR 0 INCR 0 INCR RESET 

To run: RESET 1 RUN



Interestingly, this piece of hardware allows you to trace the program step by step . If you run the program through RESET 6 RUN , then it will stop after each instruction, and the current address will be on the upper LEDs in binary code. To perform the following instructions, you must press INCR , etc. You can interrupt the program by pressing RESET , and, for example, view the contents of the registers. They are memory cells. What a no debugging.

Now the program is more complicated: a running light on the top seven LEDs with the current number displayed on the seven segment.

 00: 80 TIA 0 ; A=0 02: 1 AO ;  A  . 03: 3 CY ;  A  Y. 04: E1 CAL SETR ;  ,    Y. 06: 84 TIA 4 ; A=4 08: EC CAL TMR ;  (A+1)*0.1  (0.5 ). 0A: E2 CAL RSTR ;  ,    Y. 0C: 3 CY ;  A  Y. 0D: 91 AIA 1 ; A = A + 1 0F: C7 CIA 7 ;  A=7,  Flag=0.  Flag=1. 11: F02 JUMP 02 ;   02,  Flag=1.   Flag=1. 13: F00 JUMP 00 ;    00 (Flag=1   ). 

Codes: 8 0 1 3 E 1 8 4 ECE 2 3 9 1 C 7 F 0 2 F 0 0



What is from development tools


Alas, almost all the resources are in Japanese, but Google Translate works wonders.

Simulator



Automatic loader



Programming languages




Instead of conclusion


Cool toy. I started programming on Radio-86RK in machine codes, stuffing them in the Monitor. There are almost the same sensations. The issue of the magazine, whose application is GMC-4, judging by the pictures (I don’t read Japanese, alas) contains an illustrated history of microprocessors starting with Intel 4004 . Next come dozens of different examples of programs and projects that use GMC-4. Beauty!

Source: https://habr.com/ru/post/147157/


All Articles