> For the complete documentation index, see [llms.txt](https://docs.songbookplus.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.songbookplus.com/spanish/readme/midi-features-verwenden/midi-befehle-beim-offnen-von-songs.md).

# Comandos MIDI al abrir canciones

Puede hacer que SongBook+ envíe comandos MIDI cuando se abre una canción.

Una aplicación típica para esto es configurar dispositivos externos como un teclado según la canción seleccionada.

Existen varias formas de enviar comandos MIDI:

## Enviar los comandos configurados de BankSelect/ProgramChange <a href="#toc165549806" id="toc165549806"></a>

SongBook+ envía los comandos *BankSelect* y *ProgramChange* como están configurados en la ventana "Editar detalles de la canción", cuando el interruptor "Enviar comando MIDI al abrir" está activado.

El canal MIDI en el que SongBook+ envía estos comandos es el mismo que el configurado para la recepción MIDI.

<figure><img src="/files/h6F6fWBfd9UYMfmt4Crv" alt=""><figcaption><p>Enviar BankSelect y ProgramChange</p></figcaption></figure>

<img src="/files/ipZUuxQgiYxMYtO6sot7" alt="" data-size="line">Con estas configuraciones, un comando BankSelect High 1, un BankSelect Low 5 y un ProgramChange 16 se envían en el canal 1 a la salida MIDI.

## Enviar otros comandos MIDI configurables <a href="#toc165549808" id="toc165549808"></a>

Con el botón "Acciones al abrir" en la ventana de edición de la canción, puede definir cualquier comando MIDI que se enviará al abrir la canción.

{% hint style="info" %}
Si desea enviar más combinaciones de BankSelect MSB + BankSelect LSB + ProgramChange para controlar varios dispositivos (como en la sección anterior con los "botones MIDI"), puede hacerlo aquí.

BankSelect MSB y BankSelect LSB no son más que ControlChange con un número específico.\
Un BankSelect MSB es un ControlChange 0 y un BankSelect LSB es un ControlChange 32.
{% endhint %}

<figure><img src="/files/vic2v603yvmwSnK5FYj0" alt=""><figcaption></figcaption></figure>

## Enviar los mismos comandos MIDI para todas las canciones <a href="#toc165549809" id="toc165549809"></a>

En la configuración MIDI bajo "MIDI" -> "Macros MIDI" -> "Macros cuando se reproducen las canciones", puede seleccionar un macro MIDI previamente definido que se enviará al abrir cada canción. Además, se puede determinar si se envía incluso si la canción ya contiene "Acciones al abrir".

<figure><img src="/files/foQXr6TCCaEZWspovkc3" alt=""><figcaption></figcaption></figure>

## Enviar el contenido de un archivo MIDI cuando se abre una canción <a href="#toc165549807" id="toc165549807"></a>

SongBook envía el contenido de un archivo MIDI tan pronto como se **abre** una canción, si existe un archivo .mid con exactamente el mismo nombre que el archivo .pdf, expandido con "\_open.mid".

(por ejemplo, MiCanción.pdf -> MiCanción\_open.mid)

Solo se permiten archivos MIDI tipo 0 (pista única). Todos los comandos se envían de una vez sin tener en cuenta el tiempo. Por lo tanto, no se puede enviar música, sino solo comandos para configurar el entorno.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.songbookplus.com/spanish/readme/midi-features-verwenden/midi-befehle-beim-offnen-von-songs.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
