> For the complete documentation index, see [llms.txt](https://bananapi.gitbook.io/bpi-r1/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://bananapi.gitbook.io/bpi-r1/en/bpi-r1audio.md).

# BPI-R1 Audio

Banana pi BPI-R1 support two audio device HDMI and headphone

* How to choose HDMI or headphone for audio output

  ```
  sudo nano /etc/asound.conf
  ```

  ```
  pcm.!default {
  type hw
  card 0    //If you want to set HDMI as output ,turn 0 to 1.
  device 0
  }
  ctl.!default {
  type hw
  card 0   //If you want to set HDMI as output ,turn 0 to 1.
  }
  ```
* Plug in the headphone and type

  ```
  speaker-test -twav -c2
  ```
* The sound "sound left，sound right，sound left" will output from headphone.

  ```
  sudo apt-get install espeak
  espeak "hello"　　          //say: hello
  espeak "hello_bananapi"　　  //say: hello banana pi
  ```
* Run the sound volume controler,you can see

  ```
  sudo alsamixer
  ```


---

# 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:

```
GET https://bananapi.gitbook.io/bpi-r1/en/bpi-r1audio.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
