Page 1 of 1

Analog Circuit Video Game Concept

Posted: Thu Jul 23, 2020 3:50 pm
by 100goats
I am an electronics engineer by trade and I have been feeling some stress about how I spent too much free time
developing my programming skills over my circuit skills.

Then, the idea hit me. I can practice developing circuit systems by making a video game just from circuit logic.
I am specifically going to limit myself to analog circuits because I am more interested in analog circuit logic than digital circuit logic
or mixed-signal circuits.

It has been done by Tennis for Two in the 1950s using an analog computer and an oscilloscope.


However, the graphical display was an oscilloscope which limited it to only having 1 point per y-coordinate on a 1 channel oscilloscope.
A switching circuit had to be used to switch between display for tennis ball and net.

My game will try to use a circuit block to convert voltage signal information to a video signal for a composite or component cable
that will be connected to a television set.

I'm excited about this project! If this is successful, maybe this might be a different direction for the video game meta to take.

Re: Analog Circuit Video Game Concept

Posted: Fri Jul 24, 2020 10:03 am
by Deckhead
Man, I have only the most rudimentary understanding of what you're trying to do!

But, it sounds really cool.

How can you use circuit logic? Like... are you going to build a board with a tiny microprocessor on it? And how in the world do you translate that to a video signal?

Re: Analog Circuit Video Game Concept

Posted: Fri Jul 24, 2020 5:02 pm
by 100goats
Thanks, man! = )
Deckhead wrote:
Fri Jul 24, 2020 10:03 am

How can you use circuit logic? Like... are you going to build a board with a tiny microprocessor on it?
I am not going to use a microprocessor since it is a digital circuit component and I want to only use analog circuit components for analog circuit logic
for this project.

I can use analog circuit logic by manipulating a voltage representing the x coordinate of a player and another voltage representing the y coordinate of a player.

Op-amps allow me to do addition, subtraction, and comparison with voltages which is enough for collision detection and moving a player.

https://www.electronics-tutorials.ws/category/opamp
Deckhead wrote:
Fri Jul 24, 2020 10:03 am

And how in the world do you translate that to a video signal?
I still need to figure out how to convert a 2d image of the world into a video signal to pass to a tv set.

Fortunately, I have these resources that explain how analog video signals make an image on screen.
https://www.maximintegrated.com/en/desi ... /1184.html
https://www.maximintegrated.com/en/desi ... 7/734.html

---------------------------------------------------------------------------------------------------------------------------

The game I am going to develop will be a simple game in which players try to stab the back of the other player to win.
The player who gets their back stabbed dies. Last player standing is the winner.

It is a simple game that will only require collision detection and moving a few dots across the screen.

Re: Analog Circuit Video Game Concept

Posted: Sun Jul 26, 2020 2:13 am
by Deckhead
Oh I see what you mean by "analog" now; this sounds really cool.

Re: Analog Circuit Video Game Concept

Posted: Tue Jul 28, 2020 3:45 am
by 100goats
I started tracking this project on Github.

https://github.com/adct-the-experimente ... VG-Stabber

So far I was able to have player position and weapon position set by joystick input and center weapon around player.

I need to design a circuit that reacts to zero volt difference between a player's position and the other player's weapon
for collision detection.

Re: Analog Circuit Video Game Concept

Posted: Tue Aug 11, 2020 2:32 am
by 100goats
I have collision detection working well.

It was difficult, but rewarding.

I just made a circuit that subtracted voltages representing x,y coordinates of 2 objects.
Then, the subtraction result was passed to a positive negative indicator circuit with its output connected to a differentiator to get the moment
that a zero was crossed i.e. polarity of signal was changed.

sign = 5V if (position_obj_1 - position_obj_2) is positive, -5V if (position_obj_1 - position_obj_2) is negative
collision ~= d/dt * sign

Re: Analog Circuit Video Game Concept

Posted: Sun Aug 16, 2020 6:46 am
by Deckhead
I still am completely unaware of what you're saying, but I'm amazed that you're doing it just the same.

Do you have photos? I'm curious how this looks.

Re: Analog Circuit Video Game Concept

Posted: Sun Aug 16, 2020 10:27 pm
by 100goats
I'm using LTSpice circuit simulation software at the moment. I will move on to real parts soon.

This is a picture of the whole circuit. It uses 24 op-amps, 4 nmos, many resistors.
Image

This is the test circuit for collision detection.
The picture shows that whenever a player's x coordinate and a opponent's weapon x coordinate
are the same, the difference between them is zero, then zero detect signal changes sign, and the change in sign is indicated by the
derivative of the zero detect signal.
Image