pine64 / OpenPineBuds

Community maintained firmware for PineBuds Pro
139 stars 18 forks source link

Other open-source firmware for audio devices? #20

Open elamn1 opened 1 year ago

elamn1 commented 1 year ago

Does anyone here know other open-source firmwares for audio devices (speakers, headphones, microphones, etc.)? I don't know any and I think that there are no other audio devices with published design documents at all, but maybe someone has "hacked" own open-source firmware for some audio device.

Note, I don't mean the ones made for PineBuds Pro.

elamn1 commented 1 year ago

So, are PineBuds Pro and firmwares made for it the first of its kind in the world?

frap129 commented 1 year ago

There are a lot of frameworks, libraries and such for creating your own, but in my research I haven't found any standalone, open source, bluetooth audio firmware project yet.

lizz-34 commented 1 year ago

There are a lot of frameworks, libraries and such for creating your own

I am also interested in this. What libraries and frameworks are there? Could you link?

but in my research I haven't found any standalone, open source, bluetooth audio firmware project yet.

What about firmwares for non-bluetooth audio devices?

frap129 commented 1 year ago

I am also interested in this. What libraries and frameworks are there? Could you link?

The main one I've been doing some work on is the Zephyr RTOS. It's a bluetooth-first RTOS that, once it works with the BES2300 should make setting up bluetooth audio. Though I've never done this sort of low-level work before, I'm mostly just copying the relevant code bits out of the open firmware.

There's no libraries or frameworks like mentioned earlier. It's basically just software to control the functions of the chip. Nothing really reusable. When for example playing a soundfile you just order the chip to play a file.

I'm not talking about this repo. I'm talking about other projects, like elamn1 asked about.

frap129 commented 1 year ago

@frap129 This project is already based on RTOS :) https://github.com/pine64/OpenPineBuds/tree/main/include/rtos The processor used in the pinebuds is basically an ARM Cortex processor with a lot of interfaces and BES proprietary ANC. https://www.cnx-software.com/2022/04/16/pinesound-development-board-for-earbuds-and-digital-audio-players/

Its based on an RTOS yes, but RTX isn't really a great platform. Most open source bluetooth development I see is done on Zephyr these days (including what I do at work) which is why Im working on porting it.

lizz-34 commented 1 year ago

There's no libraries or frameworks like mentioned earlier. It's basically just software to control the functions of the chip.

I wasn't talking about this (OpenPineBuds) software.

Nothing really reusable.

I know, but who asked?

When for example playing a soundfile you just order the chip to play a file.

What do you mean?

lizz-34 commented 1 year ago

The main one I've been doing some work on is the Zephyr RTOS. It's a bluetooth-first RTOS that, once it works with the BES2300 should make setting up bluetooth audio. Though I've never done this sort of low-level work before, I'm mostly just copying the relevant code bits out of the open firmware.

Thanks! Are there any others?

lizz-34 commented 1 year ago

Firstly @WebWire-NL this is really interesting, thanks for your advice! May I ask, what do you do for living?

You'll see it uses a lot of resources and will without any hardware acceleration cause a huge delay, if you want an embedded device with an endurable battery life there's no other option to integrate it in a dedicated chip.

Are you saying that the PineBuds Pro's SoC, the BES 2300YP, not include a typical CPU? What do you mean by integrate?

This is a.f.a.i.k the first earbud to be known as really open (hardware schematics released and open source firmware provided). Because the chip still has proprietary code.

What because? Typo? Something missing?

lizz-34 commented 1 year ago

I wonder if the effort with the current hardware will be worth it. I think on next gen devices it will give an advantage as it becomes mainstream and more source will be shareable.

Next gen devices? PineBuds Pro (1) was just released in December. And we're hardly starting from scratch when new hardware comes out. We're just bringing support for it.

gamelaster commented 1 year ago

Hm @WebWire-NL?

frap129 commented 1 year ago

@WebWire-NL this isn't a new chip. The Google pixel buds have been using it for a while

frap129 commented 1 year ago

CSR8675 is a Qualcomm BT audio chip. Completely unrelated to BES2300, other than the fact that they do the same thing

frap129 commented 1 year ago

We're not discussing it. You just mentioned it out of nowhere. I've unsubscribed from this issue because none of this is actually a constructive discussion, please stop tagging me

lizz-34 commented 1 year ago

@WebWire-NL

@lizz-34 Chinese are copying fast :) https://www.alibaba.com/product-detail/electronic-component-BES2300_1600119908103.html

What is that related to? We discussed about other open-source software projects for audio devices and this is off-topic. Anyway, I don't know is that a copy? AFAIK BES (Bestechnic) 2300YP is Chinese SoC and that Alibaba seller is probably just a reseller.

@gamelaster ? I saw some products on chinese websites already using the same chip.

What? The your Alibaba link doesn't go to nothing end-user product. It goes to the page that selling the BES2300 SoC. And there have been headphones with BES SoC before the PineBuds Pro.

@frap129 @gamelaster Can you explain me how CSR8675 is related to the BES2300-YP? Can't find anything in the datasheets or on the wiki.

What? It mentioned in the completely different discussion in the PineBuds Pro Matrix room, not here.

@frap129 @gamelaster So why are we discussing about the CSR8675? :)

You asked...

I know someone brought it up, don't know why as this project is related to a whole different SoC. Only thing i was answering to was @lizz-34 who stated that this product just went on the market.

I didn't. Please, read the whole discussion in the Matrix room where CSR8675 was mentioned.

My guess is that as all the specs are available a lot of chinese copies will come

Schematics can be copied, but all design documents aren't publicly available, so making a 1:1 copy requires work.

full firmware will be leaked at some point

What firmware do you mean? This OpenPineBuds, the SDK in the wiki page or proprietary firmware that pre-installed in PineBuds Pro? If proprietary one, it isn't our or PineStore problem. AFAIK it's a "turnkey" firmware made by Bestechnic that they provide to buyers of the SoC.

where all proprietary binaries and tools will eventually be included in the source.

To which source? We can't include it to here, because it would be illegal.


@frap129

CSR8675 is a Qualcomm BT audio chip. Completely unrelated to BES2300, other than the fact that they do the same thing

No, they also have many differences. For example, the CSR8675 isn't programmable.

The main one I've been doing some work on is the Zephyr RTOS. It's a bluetooth-first RTOS that, once it works with the BES2300 should make setting up bluetooth audio. Though I've never done this sort of low-level work before, I'm mostly just copying the relevant code bits out of the open firmware.

Thanks! Are there any others?

Also, could you answer this? :) You talked about frameworks, libraries in plural.

shymega commented 1 year ago

I've been working on custom firmware, that allows for remote control of the earbuds (waiting for a devkit of PineBuds). See open-morphs, which was primarily for the Morph InfiniConnect earbuds, a project I backed on Kickstarter, but I'm exploring with the manufacturer (they're very open, surprisingly, shame they used QCC for the buds) of open-sourcing their BLE protocol for remote control, and replacing the firmware with a multi-supported Rust firmware. WIll keep this thread updated. I write this in a rush, so apologies if its a little incoherent!