Skip to content

Releases: tullulah/uvmc2-starter-kit

v1.3.2

Choose a tag to compare

@tullulah tullulah released this 06 Oct 17:57

Everything since v1.3 (this release also carries v1.3.1, which had no release of its own).

New

Hardware and performance

  • The core clock on request (make uvm2 UVM2_SYS_MHZ=300): raises the core voltage and clock before anything calibrates, and keeps the bus, PSRAM and SD at their measured speeds. On one console Star Wars went from ~22–25 ms to ~12 ms of core time a frame, enough for the 50 Hz pace. Opt-in until a second console agrees.
  • The console's reset button (builds with -DUVM2_RESET_BUTTON): held 1–3 s the game starts again; held 3 s, back to the UVMC2's menu without the console's logo. Off by default — on the UVMC2 the watch misfired and briefly stopped the controllers being read.
  • Closing gaps as live knobs (MT_CLOSE, MT_CLOSE_LONG, MT_CLOSE_BLANK): the gap that lets a lit stroke finish before the beam blanks, tunable over SWD or at build time. Defaults unchanged.

Drawing and 3D

  • Shapes that come apart where they are shot and reassemble (vpyfx_disintegrate, vpyfx_assemble).
  • Punctuation in the vector font — comma, question mark, hyphen, colon, quotes, slash, brackets and the Spanish openers — and UTF-8 text, accented letters folded to the bare capital as the Vectrex wrote them.
  • Entity extras and sort bias (vpyent_set_extra, vpyent_set_sort_bias): lines drawn in an entity's place in the depth order, so a figure standing on a platform no longer loses its legs.
  • vpy3d pools given back (vpy3d_pool_mark / vpy3d_pool_release): a game's levels no longer all live in the pools at once.

Diagnostics

  • A HUD you can read on the tube: the figures hold still for a second (means over the window, worst frame for dropped and clamped), the core clock is shown as M, and a game can add two lines of its own (uvm2_hud_game).

Simulator

  • The full drawing contract in the simulator: gapped strokes, the shift-register text sweep, analog axes and the sample cursor (v_directGapped, v_directSweepSR, v_setAnalog, v_samplePos) now link, so ports that use them run in the IDE's simulator.

Fixes

  • Up on the stick reached only two thirds of its travel in every analog game: each half of an axis is now scaled on its own.
  • A 3D build that does not fit the pools is left empty and counted instead of reading outside them (a crash on the host).
  • The frame filler's last gap could wrap with a remainder of 7 or 8 cycles.
  • The jump's ramp was computed twice per move.

Demos

  • playroom — a small game through the whole SDK: a wireframe figure walks a hub to four rooms (crates, jelly, shapes, a flyer over terrain), earns pieces and opens a finale.
  • fx_demo — a cube, an octahedron and a pyramid that break from the hit outwards and assemble edge by edge.

The SDK is at uvmc2-sdk v1.3.2 (7698696).

v1.3

Choose a tag to compare

@tullulah tullulah released this 03 Oct 07:44

New

Physics

  • Rigid bodies with gravity and collisions (vpyphys): spheres, boxes and checked convex hulls; bodies turn, tip, tumble and roll; friction, restitution, sleeping, speculative contacts so fast bodies do not tunnel; box against box tests all fifteen separating axes.
  • Joints: ball joints and hinges between bodies or to the world, with the joint's stretch reported.
  • Ray casts against bodies (vpyp_raycast) and against any mesh, dented or morphed (vpy3d_ray_mesh).
  • Blasts that throw nearby bodies, spinning.
  • Ropes and chains (vpyrope) and soft bodies (vpysoft): cloth and flags, blobs that keep their area, any mesh as a jelly.

Impact and effects

  • Sparks, bursts and shattering (vpyfx): every edge of a broken object becomes a spinning stick; expanding rings and trails; a stroke budget at the lowest priority.
  • Dents that stay where an object was hit, and shot marks (rings or cracks) kept in the object's own space.
  • Camera shake and hit-stop (vpycam), and easing curves (vpyease).

Sound

  • Impact sounds (vpyimpact) synthesised on the PSG from the hit itself: volume from the impulse, voice from the material.
  • Positional sound: quieter with distance from a listener; on a cartridge with a DAC (the UVMC2's jack), stereo panning, several hits at once, and continuous sources with a Doppler shift.

Animation

  • Skeletal animation (vpybone): rigid bones, keyframed clips with looping and blending, limbs placed by two-bone IK (vpyik).
  • Morphing between two poses of a mesh.

3D rendering

  • Hidden-line terrain from a height map (floating horizon).
  • Fog, projected shadows, screen size and level of detail.
  • Text in the world: the vector font on any plane, or as billboards that always face the camera.
  • Stereo: one view per eye with a convergence plane — the picture half of 3D Imager support.

Gameplay

  • An entity layer (vpyent): transform, mesh, body, marks and material in one table; the scene drawn near to far through the occluder and stepped in the right order in one call each.
  • Steering and pathfinding (vpyai): seek, flee, arrive, separation, and A* on a grid.
  • Deterministic replays (vpyreplay): record the input, play it back frame for frame.

Calibration and display

  • The screen's shape per console in the calibration screen: aspect, and the visible window; vpy3d uses them.
  • Frames redrawn while no new one arrives (UVM2_REPLAY_LAST): a slow game keeps its picture instead of flickering.

Diagnostics and tools

  • A diagnostics HUD on any .um2: hold buttons 1 and 4 for two seconds to see fps, bus cycles, dropped commands, clamped ramps and stack use on the screen.
  • Stack measurement: both cores' stacks are painted and their peaks reported in uvm2_stats, with a sticky overflow flag.
  • The command list to the SD card (uvm2_dump_list), and readers for it from the card, from RAM over SWD, or from RTT.
  • A beam simulator that replays a command list and flags what cannot be right, including a dark beam left running free.
  • SWD tools: read or write any variable by name on a running console, and read the command list straight from RAM.
  • Documentation: setting up a Raspberry Pi Pico as the SWD probe from scratch; live A/B comparisons over SWD; the 4 KB stack limit of a game's core and how to measure it.

Fixes

  • A diagonal line across the screen with the brightness turned up. The padding at the end of each frame left the beam's integrators running with the zero clamp released, and the dark beam swept a corner-to-corner diagonal. Fix: the padding keeps the zero clamp on.
  • A bright dot that followed the joystick. The digital stick read probed the comparator with the DAC at ±64 and left the beam parked off-centre between frames. Fix: the axes are read with the BIOS's analog method only, centred on the stick's own rest position; games still get -127 / 0 / +127 by default.
  • Hang on the UVMC2 as soon as two boxes touched. The box collision path used ~4.7 KB of stack, more than the 4 KB a game's core has, and overwrote the drawing core's stack. Fix: the large temporary lists are static; the same path now uses ~1.7 KB.
  • Off-centre impulses spun bodies too fast, by a factor of their mass.
  • Ray casts with short direction vectors reported distances about 6% too long.
  • The calibration syscall clashed with raster text: it now has its own number (30) on both cartridges.
  • Hit-stop held one frame less than asked for in the physics demo.
  • The floating-point unit is switched on before anything in a game runs.
  • A firmware build missing a required hook now fails to link instead of running silently without it.
  • Every host tool builds again, from one script.

Demos

  • physics_demo — crates, balls, a hinged door and convex pieces in a pit: drop them, shoot them; crates dent, take shot marks and shatter on the third hit; impacts throw sparks and sound, in stereo on the UVMC2's jack.
  • soft_demo — a flag flying in a wind you steer, a jelly blob you drop and punch, and a jelly cube.
  • bone_demo — a 13-bone figure walking and running up and down steps, feet placed by IK, walk and run blended with the stick.
  • scene_demo — a scene built only from entities under an orbiting camera, with a turning 3D sign, words painted on the floor and labels that always face the camera.

v1.2.2

Choose a tag to compare

@tullulah tullulah released this 01 Oct 12:04

New

  • Occlusion for meshes. vpy3d_set_mesh_occlusion(1) makes meshes drawn with vpy3d_draw_mesh hide each other, moving or not. Draw each mesh, then register it as an occluder, nearest first. It is opt-in, so existing games keep their picture.
  • Camera-space occluded lines. vpy3d_occl_line_cam is the camera-space counterpart of vpy3d_occl_line.
  • New counter, ramps_clamped. It counts ramps started while the beam was clamped to the centre, and must always read 0.
  • Occlusion demo: now three turning meshes, one of them passing in front of and behind the others, with occlusion on and off for comparison.

Fixes

  • First strokes lost, and stray lines from the centre of the screen. When a frame's first stroke started near the middle of the screen, the first jump was too short to trigger a re-zero. The beam's zero clamp, which the frame prologue sets, was then never released, and the frame's first strokes were drawn with the beam held at the centre. They disappeared from the picture and showed up as lines radiating from the middle: one line without stroke chaining, a star of several arms with it. Any 3D scene centred on its subject could hit this. Fix: the frame's first jump now always re-zeroes while the clamp is still on, whatever its length. This costs six commands per frame. The new ramps_clamped counter proves it stays fixed.
  • Host tools link again. The command-list counter and the sample-player test had stopped linking after the microsecond clock was added.

v1.2.1

Choose a tag to compare

@tullulah tullulah released this 01 Oct 10:01

3D

  • Occlusion between solids. A solid can now hide what is behind it. Lines drawn after a solid has been registered as an occluder are cut by its silhouette. When no occluders are registered, the cost is negligible. Counters report how many lines were cut and how many occluders were refused, so the feature can be verified at run time.
  • Correct proportions. The projection uses the same scale on both axes, so squares come out square and circles round.
  • Per-axis view window. The visible window can be set independently in x and y to use the full portrait screen.
  • Field-of-view queries. Games can ask for the horizontal and vertical field of view actually on screen, instead of hard-coding it.

Drawing

  • Stable brightness on static screens. A screen drawn at a single intensity no longer fades out over time.

Calibration

  • New ring-burst test figure. It separates the per-stroke error from the length-proportional error. It also shows whether the frame fitted, so overload is not mistaken for distortion.
  • Figure selector on button 1. The same setting can be judged on the text, the wheel or the rings without leaving it.
  • Audio output setting on screen. Switches show words instead of numbers.
  • Joystick centre measured on entry, so navigation works on consoles whose stick does not rest at zero.

Audio and storage

  • Stereo output on the audio jack.
  • Hardware SPI for the SD card at 12.5 MHz, much faster than before.
  • Microsecond clock available to games.

Examples

  • Geometry test card: checks screen proportions and visible extent on a console.
  • Occlusion demo: the same scene with occlusion on and off, and a worked example of how to use it.