How it works
This design is derived from the allowed VGA Playground preset flow (using a lightweight animated pattern background). A VGA Pong match is rendered over this animated layer.
The left paddle is controlled by the human inputs. The right paddle is controlled by a pre-trained, INT8-quantized inference-only neural unit (perceptron):
- 2 signed INT8 inputs: ball vertical offset and vertical direction
- no hidden layer (single-neuron model)
- 1 signed INT8 output controlling paddle movement
- Fixed weights stored as Verilog constants
- One sequential inference every frame, avoiding large combinational multipliers
No neural-network training occurs in the chip. All weights are software-pretrained and quantized offline.
Controls
- ui_in[0] Human UP: move the left paddle up
- ui_in[1] Human DOWN: move the left paddle down
- ui_in[2] AI ENABLE: enable neural control of the right paddle
- ui_in[3] START: start the match
- ui_in[4] PAUSE: pause match motion
- ui_in[5] RESET: reset score and positions
- ui_in[6] SERVE: launch the ball after a score
- ui_in[7] ADAPTIVE: increase ball and neural challenge speed on paddle hits
How to test
- Connect a Tiny VGA PMOD (RGB222) to the Tiny Tapeout board.
- Connect it to a VGA monitor.
- Power the board and release reset.
- Set ui_in[2] high to enable the AI paddle.
- Pulse ui_in[3] to start and ui_in[6] to serve.
- Hold ui_in[0] or ui_in[1] to move the human paddle.
- Toggle ui_in[7] to enable adaptive difficulty.
- Assert ui_in[4] to pause or ui_in[5] to reset the match.
External hardware
- Tiny VGA PMOD (RGB222)
- VGA-compatible monitor