diff --git a/docs/en/man_index.html b/docs/en/man_index.html new file mode 100644 index 0000000..26731d6 --- /dev/null +++ b/docs/en/man_index.html @@ -0,0 +1,950 @@ + + + + + + + + + + +knloader English Manual + + + + + + +
+
+
+
+
+
+
+

Description

+
+
+

Do you have a ZX Spectrum Next, but you are tired to remember which is the best option to launch your programs? knloader to the rescue!

+
+
+

This a set of NextBASIC programs which you can configure to remember, and then use, your preferred way to launch other programs (Next/+3e Mode, 128K mode, USR 0, etc.). As a bonus, you can put some images (like cassette covers or loading screens).

+
+
+

These programs aren’t a replacement for the incoportaded Browser, nor offer any other function than to launch other programs.

+
+
+
+
+

Requirements

+
+
+

Download

+
+

A ZIP file with the latest version is available following this link.

+
+
+
+

Software Requirements

+
+
    +
  • +

    NextZXOS (version 1.3.2). Docs, downloads, etc. here.

    +
  • +
  • +

    Python (version 3.6 or later), optionally, to use the included BDT and cache creation scripts. Docs, downloads, etc. here.

    +
  • +
+
+
+
+
+
+

Installation

+
+
+

Create knloader.bdt file using the text editor of your choice or the included utility script and, optionally, create cache file(s) with the included utility (see below for more instructions).

+
+
+

Copy together knloader.bas, knlauncher, knzml, from one of the distribution language folders (en for english, es for spanish, etc.), and the new knloader.bdt or the cache file(s) to any place in your SD card.

+
+
+
+
+

Use

+
+
+

Use the browser or command line to navigate to the folder where knloader.bas, knlauncher, knzml and knloader.bdt are. Load knloader.bas.

+
+
+

On first run, if they do not exist, cache files are created from the data inside database file knloader.bdt.

+
+
+
+FirstBoot +
+
+
+

The main interface shows a list of the programs found in the database file.

+
+
+
+CoverOff +
+
+
+
+

You can use the cursor keys or a joystick (Kempston or MD) to move and select the program that you want to load. Then, press ENTER, 0 or the joystick button to launch.

+
+
+
+LoadDetails +
+
+
+

After a brief period of time, the program should load using the desired mode.

+
+
+
+knlauncher +
+
+
+
+

If you have made a change to the database file, press R to rebuild the cache.

+
+
+

Press C or the joystick secondary button (in MD mode) to hide/show images.

+
+
+
+CoverOn +
+
+
+

Press A to enable/disable automatic save of the currently selected program position and the selection to show or hide images.

+
+
+

Press X or the third joystick button to exit the program.

+
+
+

Press H to show some help.

+
+
+
+
+

Database file format

+
+
+

The main database is stored in a text file (ANSI encoding), named knloader.bdt, and which has to be in the same directory where knloader.bas is in the SD card. You can create manually the database file or using the included utility script bdt_builder.py.

+
+
+

BDT file size is limited to 16384 bytes when the cache files are created from within the ZX Spectrum Next. This limit disappears when the cache files are created externally, for example, using the utility script cache_builder.py.

+
+
+

All paths in the database file must use / (slash) as separator for directories. Using \ (backslash) is not supported.

+
+
+

The first line has to be the base path where to start looking for programs (for example: /games). It’s length cannot exceed 128 characters.

+
+
+

Starting from line 2, each line must have the following format:

+
+
+
+
Program Name,Loading Mode,<Directory>,File,<Image File>
+
+
+
+

Where each of the fields between ',' are as follows:

+
+
+

Program Name: Name to show in the interface (no commas , allowed)

+
+
+

Loading Mode: A number indicating how to load the program file. See the Table below

+
+
+

Directory: (Optional) Subdirectory where file and image file are located (maximum 64 characters, no commas , allowed)

+
+
+

File: Name of the file to execute (maximum 64 characters, no commas , allowed). If Mode 8 (DSK Custom Boot) is selected, it must have the name of both the DSK file and the file to load inside the disk image, separated by : (e.g. Bounder.dsk:BOUNDER.BAS)

+
+
+

Image File: (Optional) Name (maximum 64 characters, no commas , allowed) of a full screen image file to show behind the program listing. It can be in SCR, SLR, SHC, SL2 or BMP format. BMP file has to be 256x192 pixels, 256 colours (with Next palette and no colour space information).

+
+
+
+

Loading Mode Reference Codes

+
+
+
0  - 3DOS (Next)
+1  - TAP
+2  - TZX (fast)
+3  - DSK (AUTOBOOT)
+4  - TAP (USR 0)
+5  - TZX (USR0 - Fast)
+6  - TAP (Next)
+7  - TZX (Next - Fast)
+8  - DSK (Custom Boot)
+9  - TAP (PI Audio)
+10 - TZX
+11 - TAP (USR 0 - PI Audio)
+12 - TZX (USR 0)
+13 - TAP (PI Audio - Next)
+14 - TZX (Next)
+15 - NEX (Next)
+16 - Snapshot
+17 - Z-Machine Program (Next)
+18 - 3DOS
+19 - TAP (48K)
+20 - TZX (48K - Fast)
+21 - TAP (48K - Pi Audio)
+22 - TZX (48K)
+23 - TAP (LOAD "" CODE)
+24 - TZX (LOAD "" CODE - Fast)
+25 - TAP (LOAD "" CODE - USR 0)
+26 - TZX (LOAD "" CODE - USR0 - Fast)
+27 - TAP (LOAD "" CODE - USR 0 - PI Audio)
+28 - TZX (LOAD "" CODE - USR 0)
+29 - TAP (LOAD "" CODE - 48K)
+30 - TZX (LOAD "" CODE - 48K - Fast)
+31 - TAP (LOAD "" CODE - PI Audio - 48K)
+32 - TZX (LOAD "" CODE - 48K)
+
+
+
+ + + + + +
+ + +
+

Unless stated otherwise (e.g. on modes 6,7), all modes set the ZX Spectrum Next in 128K mode, disabling Next special hardware.

+
+
+

All TZX (fast) modes run at 14Mhz. Once the program is loaded, you can get back to 3.5MHz speed using the NMI menu or pressing NMI and 8 at the same time.

+
+
+

Mode 3 (DSK AUTOBOOT) will mount the DSK file at drive A: and execute LOAD "*".

+
+
+

Mode 8 (DSK Custom Boot) will mount the DSK file at drive A: and execute LOAD "diskfile", where diskfile is obtained from the File field.

+
+
+
+
+
+
+

Examples

+
+

This are all valid lines:

+
+
+
+
Albatrossity,1,,Albatrossity.tap
+
+Alter Ego,4,Alter Ego,Alter Ego.tap
+
+Altered Beast,3,Altered Beast,Altered Beast.dsk,Altered Beast.bmp
+
+Astronut,16,../Next/,Astronut.snx
+
+
+
+

But these are not:

+
+
+
+
Albatrossity,,,Albatrossity.tap
+
+
+
+

(missing Load Mode Code)

+
+
+
+
,1,,Albatrossity.tap
+
+
+
+

(missing Name)

+
+
+
+
Albatrossity,1,,
+
+
+
+

(Missing File)

+
+
+
+

This is an example of a small database file:

+
+
+
+
/all/Games
+Albatrossity,1,,Albatrossity.tap
+Alter Ego,4,Alter Ego,Alter Ego.tap
+Altered Beast,3,Altered Beast,Altered Beast.dsk,Altered Beast.bmp
+Amaurote,2,Amaurote,Amaurote.tzx
+Aquanoids,5,Aquanoids,Aquanoids.tzx
+Auf Wiedersehen Monty,10,Auf Wiedersehen Monty,Auf Wiedersehen Monty - 128k.tzx
+Astronut,16,../Next/,Astronut.snx
+Barbarian: The Ultimate Warrior,0,Barbarian/3DOS,BARB.BAS,../Barbarian.bmp
+Batty,9,Batty,Batty.tap,
+Bounder,8,Bounder,Bounder.dsk:BOUNDER.BAS
+Hitchhiker's Guide to The Galaxy,17,../Z-Machine,hitchhiker-r60-s861002.z3
+
+
+
+

So, using this example, when you choose Barbarian: The Ultimat in the user interface, the program will try to load /all/Games/Barbarian/3DOS/BARB.BAS, and it will also try to show the image located at /all/Games/Barbarian/Barbarian.bmp.

+
+
+
+
+
+

BDT Builder Script

+
+
+

This script tries to analyze all the contents of a directory (including subdirectories), finding ZX Spectrum Next files and images, and creates a new BDT file accordingly. Python (version 3.6 or later) is needed for it to run.

+
+
+

The script has a rudimentary intelligence and, when there are several files with the same name but different extensions (nex, snx, tap, etc.) it selects only one of them, following this priority:

+
+
+
+
nex >  snx > tap > bas > dsk > p > tzx > z8 > z5 > z3 > z80
+
+
+
+

The default mode for each of these file types is as follows:

+
+ ++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

Extension

Mode

nex

15

snx

16

tap

1

bas

0

dsk

3

p

16

tzx

2

z8

17

z5

17

z3

17

z80

16

+
+

Also, when finding several image files with different extension, only one is selected using this priority:

+
+
+
+
bmp > sl2 > scr > slr > shr > shc
+
+
+
+

Script usage: python3 bdt_builder.py -i INPUT_PATH [-o OUTPUT_PATH] [-c SD_PATH] [--tap NUMBER] [--tzx NUMBER] [--bas NUMBER]

+
+
+

Where INPUT_PATH is the path to the directory to analyze,OUTPUT_PATH, optionally, is the path to the new BDT file. If there is no output path argument, the BDT file is created in the current directory. Finally, SD_PATH, optionally, is the path in the SD where the programs are stored (first line of the BDT file). If no SD_PATH is provided, OUTPUT_PATH will be used.

+
+
+

By default, the script treats each found filename (without extension) as a different program to catalog. However you can change this behaviour to use the instead the name of the containing folder, and then take all the appropriate files inside as the same program, regardless of their name. To activate this feature, you must add -t d to the command, like this: python3 bdt_builder.py -i INPUT_PATH -t d [-o OUTPUT_PATH] [-c SD_PATH]

+
+
+

Also, the script orders by program name (lexicographically) all the results. If you want to order the results by file name (ASCII ordering), you can add the -u switch (e.g. python3 bdt_builder.py -u -i INPUT_PATH …​).

+
+
+

You can change the default loading mode for tap, tzx or bas extensions, using --tap NUMBER, --tzx NUMBER or --bas NUMBER, using the desired mode number. For example, to change loading mode for tap files to USR 0: python3 bdt_builder.py -i INPUT_PATH --tap 4 …​

+
+
+

After the BDT file is created, you can review and change its contents with a text editor, and then copy it to your SD card, next to where knloader.bas is, or you can create cache data (using the Cache Builder Script) and copy it to the SD card.

+
+
+
+
+

Cache Builder Script

+
+
+

These programs use one or more cache files inside /tmp/knloader in the SD card. This is necessary to speed up program execution limitations. You can let knloader.bas create the cache data automatically for you on first run (or using the R key from within the program), or you can create externally the cache using the included cache_builder.py script. Python (version 3.6 or later) is needed for this script to be run.

+
+
+

One cache file is needed for each RAM memory bank (16K) that the program uses, and a maximum of 74 programs data can be stored in one bank. This means that, at most, 2590 programs can be managed with a base ZX Spectrum Next (1MiB of RAM) or 7326 when using an expanded configuration (2MiB of RAM).

+
+
+

Script usage: python3 cache_builder.py -i INPUT_PATH [-o OUTPUT_PATH]

+
+
+

Where INPUT_PATH is the path to the DBT file, and OUTPUT_PATH, optionally, is the directory path where the cache data will be created. If there is no output path argument, cache data is created in the current directory.

+
+
+

After the cache data files are created, you have to copy them to your SD card into /tmp/knloader.

+
+
+
+
+

Autoexec NextBASIC program

+
+
+

Also included there is a small autoexec.bas that you can use to autostart knloader when the ZX Spectrum Next is started.

+
+
+

To install it, rename the file /nextzxos/autoexec.bas in the SD card to /nextzxos/autoexec.bas.bak, and then copy the file autoexec.bas from the utils folder into /nextzxos in the SD card. Copy also all the knloader files (knloader.bas, knlauncher, knzml and BDT file), from one of the distribution language folders (en for english, es for spanish, etc.), to a directory named /knloader/ in the root of the SD card.

+
+
+

As an extra, you can use the following keys on startup to change the behaviour:

+
+
+
    +
  • +

    Press A or the main joystick button (Kempston or MD mode) to start the original autoexec.bas that was renamed as autoexec.bas.bak

    +
  • +
  • +

    Press Space or the secondary joystick button to start ZX Spectrum Next Browser instead of knloader

    +
  • +
+
+
+
+
+

Notes

+
+
+

These programs create a preferences file named opts.tmp inside the same folder where knloader.bas is installed.

+
+
+
+
+ +
+
+

Copyright (c) 2020 kounch

+
+
+

Some of the code used to launch programs has been adapted from the official NextZXOS distribution (especifically from browser.cfg, tapload.bas and tzxload.bas).

+
+
+

Spectrum Next and System/Next are © SpecNext Ltd.

+
+
+

Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted, provided that the above copyright notice and this permission notice appear in all copies.

+
+
+

THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE

+
+
+
+
+ + + \ No newline at end of file diff --git a/docs/en/manual.html b/docs/en/manual.html new file mode 100644 index 0000000..30b30e1 --- /dev/null +++ b/docs/en/manual.html @@ -0,0 +1,63 @@ + + + + + Elements - Introspect by TEMPLATED + + + + + + + + + + + +
+ + +
+ + + + + + + + + + + + + \ No newline at end of file diff --git a/docs/es/man_index.html b/docs/es/man_index.html new file mode 100644 index 0000000..c2d1f07 --- /dev/null +++ b/docs/es/man_index.html @@ -0,0 +1,950 @@ + + + + + + + + + + +Manual de knloader + + + + + + +
+
+
+
+
+
+
+

Descripción

+
+
+

¿Tiene usted un ZX Spectrum Next, pero está cansado de tener que recordar cuál es la mejor opción para lanzar sus programas? Entonces knloader puede ser la solución.

+
+
+

Este es un conjunto de programas NextBASIC que se pueden configurar para recordar, y entonces utilizar, el método preferido para lanzar otros programas (Modo Next/+3e, Modo 128K, USR 0, etc.). Como extra, además se pueden utilizar imágenes (como carátulas de cassette o pantallas de carga).

+
+
+

Estos programas no reemplazan el programa Browser incorporado, ni ofrecen otra función que no sea lanzar otros programas.

+
+
+
+
+

Requisitos

+
+
+

Descarga

+
+

Se puede obtener un fichero ZIP con la última versión siguiendo este enlace.

+
+
+
+

Requisitos de Software

+
+
    +
  • +

    NextZXOS (versión 1.3.2). Documentos, descargas, etc. aquí.

    +
  • +
  • +

    Python (versión 3.6 o superior), opcionalmente, para usar los scripts incluídos de creación de BDT y de datos de caché. Documentación, descarga, etc. aquí.

    +
  • +
+
+
+
+
+
+

Instalación

+
+
+

Crear un archivo knloader.bdt con un programa editor de texto o con el script incluido y, opcionalmente, crear datos de caché (leer a continuación para más instrucciones).

+
+
+

Copiar, juntos, knloader.bas, knlauncher, knzml, desde una de las carpetas de idioma de la distribución (en en inglés, es para castellano, etc.), y el nuevo archivo knloader.bdt o los datos de caché al lugar que se desee de la tarjeta SD.

+
+
+
+
+

Uso

+
+
+

Acceder usando el programa Browser, o con otro método, hasta la carpeta donde están knloader.bas, knlauncher, knzml y knloader.bdt. Cargar knloader.bas.

+
+
+

En la primera ejecución, si no existieran, se crearán archivos de caché desde la información del archivo de datos knloader.bdt.

+
+
+
+FirstBoot +
+
+
+

La interfaz principal muestra una lista de los programas encontrados en el archivo de datos.

+
+
+
+CoverOff +
+
+
+
+

Se pueden utilizar las teclas de cursor o un joystick compatible (modo Kempston o MD) para moverse y elegir el programa a cargar. Entonces, pulsar ENTER, 0 o el botón del joystick para ejecutarlo.

+
+
+
+LoadDetails +
+
+
+

Después de unos instantes, el programa debería cargarse usando el modo deseado.

+
+
+
+knlauncher +
+
+
+
+

Si se han introducido cambios en el archivo de datos, pulsar R para reconstruir la caché con la nueva información.

+
+
+

Pulsar C o el botón secundario del joystick (en modo MD ) para ocultar o mostrar las imágenes.

+
+
+
+CoverOn +
+
+
+

Pulsar A para activar o desactivar el guardado automático del programa seleccionado y la opción de ocultar o mostrar imágenes.

+
+
+

Pulsar X o el tercer botón del joystick para salir del programa.

+
+
+

Pulsar H para mostrar una pequeña ayuda (en inglés).

+
+
+
+
+

Formato del archivo de datos

+
+
+

La base de datos principal se almacena en un archivo de texto (codificación ANSI, sin acentos u otros caracteres similares), que se ha de llamar knloader.bdt, y que debe estar en el mismo directorio en el que esté knloader.bas en la tarjeta SD. El archivo de datos se puede crear de forma manual, o bien utilizando el script bdt_builder.py incluído.

+
+
+

El fichero BDT tiene un tamaño máximo de 16384 bytes si los archivos de cache se crean en el ZX Spectrum Next. Este límite no existe cuando los archivos de cache se crean de forma externa, por ejemplo, usando el script cache_builder.py.

+
+
+

Todas las rutas que se indiquen deben usar / como separador para indicar directorios. El uso de \ no está soportado.

+
+
+

La primera linea del archivo ha de ser la ruta principal de la SD desde la que empezar a buscar programas (por ejemplo: /Juegos). No debe exceder los 128 caracteres de longitud.

+
+
+

A partir de la segunda, cada línea debe ser según el siguiente formato:

+
+
+
+
Nombre,Modo de carga,<Directorio>,Archivo,<Archivo de Imagen>
+
+
+
+

Donde cada uno de los campos entre ',' son de la siguiente manera:

+
+
+

Nombre: Nombre a mostrar en la interfaz (máximo de 22 caracteres, las comas , no están permitidas)

+
+
+

Modo de carga: Un número indicando cómo cargar el archivo de programa. Véase la tabla a continuación

+
+
+

Directorio: (Opcional) Subdirectorio donde se encuentran Archivo y Archivo de Imagen (máximo de 64 caracteres, las comas , no están permitidas)

+
+
+

Archivo: Nombre del archivo a ejecutar (máximo 64 caracteres, las comas , no están permitidas). Si se elige el modo 8 (DSK con arranque personalizado), debe contener el nombre, tanto del archivo DSK, como el del archivo a ejecutar de dentro de la imagen de disco, separados por : (por ejemplo: Bounder.dsk:BOUNDER.BAS)

+
+
+

Archivo de imagen: (Opcional) Nombre (máximo 64 caracteres, las comas , no están permitidas) de una imagen de pantalla completa para mostrar por debajo del listado de programas. Puede ser en el formato SCR, SLR, SHC, SL2 o BMP. En el caso de BMP, este ha de ser de 256x192 píxeles, 256 colores, usando la paleta de color de Next y sin información del espacio de color.

+
+
+
+

Códigos de referencia de los modos de carga

+
+
+
0  - 3DOS (Next)
+1  - TAP
+2  - TZX (rápido)
+3  - DSK (auto arranque)
+4  - TAP (USR 0)
+5  - TZX (USR0 - rápido)
+6  - TAP (Next)
+7  - TZX (Next - rápido)
+8  - DSK (arranque personalizado)
+9  - TAP (PI Audio)
+10 - TZX
+11 - TAP (USR 0 - PI Audio)
+12 - TZX (USR 0)
+13 - TAP (PI Audio - Next)
+14 - TZX (Next)
+15 - NEX (Next)
+16 - Snapshot
+17 - Programa de Z-Machine (Next)
+18 - 3DOS
+19 - TAP (48K)
+20 - TZX (48K - rápido)
+21 - TAP (48K - Pi Audio)
+22 - TZX (48K)
+23 - TAP (LOAD "" CODE)
+24 - TZX (LOAD "" CODE - rápido)
+25 - TAP (LOAD "" CODE - USR 0)
+26 - TZX (LOAD "" CODE - USR0 - rápido)
+27 - TAP (LOAD "" CODE - USR 0 - PI Audio)
+28 - TZX (LOAD "" CODE - USR 0)
+29 - TAP (LOAD "" CODE - 48K)
+30 - TZX (LOAD "" CODE - 48K - rápido)
+31 - TAP (LOAD "" CODE - PI Audio - 48K)
+32 - TZX (LOAD "" CODE - 48K)
+
+
+
+ + + + + +
+ + +
+

Salvo que se indique lo contrario (por ej. en los modos 6, 7), todos los modos configuran el ZX Spectrum Next en modo 128K, deshabilitando el hardware especial de Next.

+
+
+

Totos los modos TZX (rápido), se ejecutan a 14 MHz. Una vez que el programa haya cargado, se puede volver a la velocidad de 3,5MHz desde el menú NMI, o pulsando NMI y 8 a la vez.

+
+
+

El modo 3 DSK (auto arranque) monta el archivo DSK en la unidad A: y ejecuta LOAD "*".

+
+
+

El modo 8 DSK (arranque personalizado) monta el archivo DSK en la unidad A: y ejecuta LOAD "archivo", donde archivo, se obtiene desde el campo Archivo.

+
+
+
+
+
+
+

Ejemplos

+
+

Estas son todas líneas con un formato válido:

+
+
+
+
Albatrossity,1,,Albatrossity.tap
+
+Alter Ego,4,Alter Ego,Alter Ego.tap
+
+Altered Beast,3,Altered Beast,Altered Beast.dsk,Altered Beast.bmp
+
+Astronut,16,../Next/,Astronut.snx
+
+
+
+

Pero estas otras, no:

+
+
+
+
Albatrossity,,,Albatrossity.tap
+
+
+
+

(falta el código del modo de carga)

+
+
+
+
,1,,Albatrossity.tap
+
+
+
+

(falta el nombre)

+
+
+
+
Albatrossity,1,,
+
+
+
+

(falta el archivo)

+
+
+
+

Ejemplo de archivo de datos:

+
+
+
+
/all/Games
+Albatrossity,1,,Albatrossity.tap
+Alter Ego,4,Alter Ego,Alter Ego.tap
+Altered Beast,3,Altered Beast,Altered Beast.dsk,Altered Beast.bmp
+Amaurote,2,Amaurote,Amaurote.tzx
+Aquanoids,5,Aquanoids,Aquanoids.tzx
+Auf Wiedersehen Monty,10,Auf Wiedersehen Monty,Auf Wiedersehen Monty - 128k.tzx
+Astronut,16,../Next/,Astronut.snx
+Barbarian: El Guerreo Definitivo,0,Barbarian/3DOS,BARB.BAS,../Barbarian.bmp
+Batty,9,Batty,Batty.tap,
+Bounder,8,Bounder,Bounder.dsk:BOUNDER.BAS
+Autoestopista Galactico,17,../Z-Machine,hitchhiker-r60-s861002.z3
+
+
+
+

Así, según este último ejemplo, al elegir Barbarian: El Guerrero en la interfaz de usuario, el programa intentará cargar /all/Games/Barbarian/3DOS/BARB.BAS, y tambén mostrará la imagen que se encuentra en /all/Games/Barbarian/Barbarian.bmp.

+
+
+
+
+
+

Script de creación de BDT

+
+
+

Este script intenta analizar el contenido de un directorio (incluidos subdirectorios), buscando archivos de ZX Spectrum Next y archivos de imagen, y luego crear un nuevo fichero BDT con los datos obtenidos. El script necesita Python (versión 3.6 o posterior) para poder ejecutarse.

+
+
+

Tiene un poco de inteligencia y, cuando se encuentre varios archivos con el mismo nombre pero distinta extensión (nex, snx, tap, etc.), elige sólo uno de ellos, según la siguiente prioridad:

+
+
+
+
nex >  snx > tap > bas > dsk > p > tzx > z8 > z5 > z3 > z80
+
+
+
+

El modo de carga por defecto para cada uno de estos tipos de archivo es el siguiente:

+
+ ++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

Extensión

Modo

nex

15

snx

16

tap

1

bas

0

dsk

3

p

16

tzx

2

z8

17

z5

17

z3

17

z80

16

+
+

Así mismo, si se encuentran varios archivos de imagen pero con distinta extensión, se elige solo uno según esta prioridad:

+
+
+
+
bmp > sl2 > scr > slr > shr > shc
+
+
+
+

Modo de uso: python3 bdt_builder.py -i RUTA [-o FICHERO] [-c RUTA_SD] [--tap NUMERO] [--tzx NUMERO] [--bas NUMERO]

+
+
+

Donde RUTA es la ruta al directorio a analizar, FICHERO, opcionalmente, es la ruta al fichero BDT a crear. Si no se indica ruta al fichero, este se crea automáticamente en el directorio actual. Finalmente, RUTA_SD, opcionalmente también, es la ruta de la SD donde se encuentran los programas (primera línea del archivo BDT). Si no se indica un ruta de la SD, se usa RUTA en su lugar.

+
+
+

Por defecto, el script considera cada nombre de archivo encontrado (sin extensión) como un programa distinto a catalorar. Sin embargo, se puede cambiar este comportamiento para usar el del directorio que lo contiene, y entonces considerar todos los ficheros adecuados de su interior como el mismo programa, sin importar qué nombre tengan. Para activar esta característica, hay que añadir -t d al comando, de esta manera: python3 bdt_builder.py -i RUTA -t d [-o FICHERO] [-c RUTA_SD]

+
+
+

Además, el script ordena en base al nombre (lexicográficamente) todos los resultados. Si se prefiera que se ordenen los resultados en base al nombre del archivo (orden ASCII), se puede utilizar -u (por ej: python3 bdt_builder.py -u -i RUTA …​).

+
+
+

Se puede cambiar el modo de carga por defecto para las extensions tap, tzx o bas, usando --tap NUMERO, --tzx NUMERO o --bas NUMERO, con el número de modo deseado. Por ejemplo, para cambiar el modo de carga de ficheros tap a USR 0: python3 bdt_builder.py -i RUTA --tap 4 …​

+
+
+

Una vez que se ha creado el fichero BDT, se puede revisar y retocar con un editor de texto, y luego copiarlo a la tarjeta SD, en la misma ubicación en la que se encuentre knloader.bas, o se pueden crear datos de cache (usando el Script de creación de Caché) y copiar estos en la tarjeta.

+
+
+
+
+

Script de creación de Caché

+
+
+

Estos programan utilizan uno o más archivos de caché en /tmp/knloader, lo que es necesario para que la ejecución del programa sea a una velocidad adecuada. Puede dejar que knloader.bas cree la caché de forma automática en su primera ejecución (o pulsando la tecla R), o puede crearlos de forma externa usando el script cache_builder.py incluido. Este necesita Python (versión 3.6 o posterior) para poder usarse.

+
+
+

Se usa un fichero de cache por cada banco de memoria RAM (16K) que el programa utiliza, y, en un banco, se puede llegar a guardar un máximo de datos de 74 programas. Esto quiere decir que, como mucho, se pueden gestionar 2590 programas con un ZX Spectrum Next básico (1MiB de memoria RAM) o 7326 programs en el caso de un ZX Spectrum Next con la memoria expandida (2 MiB de RAM).

+
+
+

Uso del script: python3 cache_builder.py -i FICHERO [-o RUTA]

+
+
+

Donde FICIHERO es la ruta al fichero BDT y RUTA, opcionalmente, es la ruta al directorio donde crear los datos de caché. Si no se indica ruta de destino, estos se crean automáticamente en el directorio actual.

+
+
+

Una vez que los ficheros de caché se han creado, ha de copiarlos a la tarjeta SD en el directorio /tmp/knloader.

+
+
+
+
+

Programa Autoexec en NextBASIC

+
+
+

También se incluye un pequeño programa autoexec.bas que se puede utilizar para que se inicie knloader de forma automática cada vez que se encienda el ZX Spectrum Next.

+
+
+

Para utilizarlo, renombre el fichero /nextzxos/autoexec.bas de la tarjeta SD a /nextzxos/autoexec.bas.bak, y luego copie el fichero autoexec.bas del direcotrio utils a /nextzxos en la tarjeta SD. Copie también todos los ficheros de knloader (knloader.bas, knlauncher, knzml and BDT file), desde una de las carpetas de idioma de la distribución (en en inglés, es para castellano, etc.), en un directorio llamado /knloader/ en la raíz de la SD.

+
+
+

Como extra, puede usar las siguientes teclas en el inicio para cambiar el comportamiento del arranque:

+
+
+
    +
  • +

    Pulse A o el botón principal del joystick (modo Kempston o MD) para lanzar el fichero autoexec.bas original que se renombró como autoexec.bas.bak

    +
  • +
  • +

    Pulse Espacio o el botón secundario del joystick para iniciar el programa Browser de ZX Spectrum Next en vez de knloader

    +
  • +
+
+
+
+
+

Notas

+
+
+

Estos programas crean un archivo de preferencias llamado opts.tmp en la misma carpeta donde se encuentre knloader.bas.

+
+
+
+
+ +
+
+

Copyright (c) 2020 kounch

+
+
+

Parte del código utilizado para lanzar programas ha sido adaptado desde la distribución oficial de NextZXOS (concretamente de browser.cfg, tapload.bas y tzxload.bas).

+
+
+

Spectrum Next y System/Next son © SpecNext Ltd.

+
+
+

Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted, provided that the above copyright notice and this permission notice appear in all copies.

+
+
+

THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE

+
+
+
+
+ + + \ No newline at end of file diff --git a/docs/es/manual.html b/docs/es/manual.html new file mode 100644 index 0000000..1000837 --- /dev/null +++ b/docs/es/manual.html @@ -0,0 +1,63 @@ + + + + + Elements - Introspect by TEMPLATED + + + + + + + + + + + +
+ + +
+ + + + + + + + + + + + + \ No newline at end of file