Log In  


Cart #spotytron-1 | 2025-08-31 | Embed ▽ | No License
1

Controls in Spotytron

  • Up / Down arrows: Navigate albums or tracks (scroll is automatic)
  • Left arrow: Return to album selection from track mode
  • Button O: Enter album / Play selected track
  • Button X: Stop music

Where to Place POD Files

To use your albums in Spotytron, place all .pod files in this folder:
/appdata/albums
Spotytron will automatically detect them and show them in the album list.

Overview

The encodepod() function is a simple utility for creating a music POD file in Picotron.

It takes one or more SFX files, encodes them into POD-compatible binaries, and packages them into an album with multiple tracks.

How It Works

  1. Fetch SFX files: The function fetches SFX files from /desktop/.

  2. Encode to POD binary: Each SFX userdata is converted into a POD binary using the pod() function.

  3. Define album structure:

    • sfx_files: List of encoded SFX binaries used in the album.
    • tracks: Table of tracks, each containing:
      • name: Track name
      • sfx_file: Number referencing the SFX used
      • pattern: Starting pattern number
  4. Define metadata: Metadata includes album name and artist.

  5. Save the POD: The album and metadata are saved into /appdata/<AlbumName>.pod using the store() function.

Example Code

function encodepod()
	local sfx_pod1 = fetch("/desktop/sfx1.sfx")
	local sfx_bin1 = pod(sfx_pod1) -- encode the userdata into POD binary

	local sfx_pod2 = fetch("/desktop/sfx2.sfx")
	local sfx_bin2 = pod(sfx_pod2)

	local album = {
		sfx_files = { sfx_bin1, sfx_bin2 },
		tracks = {
			{ name = "Intro", sfx_file = 1, pattern = 0 },
			{ name = "Theme principal", sfx_file = 2, pattern = 10 },
			{ name = "Outro", sfx_file = 1, pattern = 20 },
		}
	}

	local meta = {
		album = "Test Album",
		artist = "Me",
	}

	store("/appdata/test_album.pod", album, meta)
1



[Please log in to post a comment]