Live data from Hacker News

Android's new Bluetooth stack rewrite (Gabeldorsh) is written with Rust

android.googlesource.com

391–393 of 393 posts

Re: Android's new Bluetooth stack rewrite (Gabeldorsh) is written with Rust

#391

Earlier quoted context omitted.

> I do wonder if Rust is easier or harder than other comparable languages like C / C++ when the person has no prior knowledge of programming. I can answer this because I previously taught the course in C and C++. The students supposedly have some knowledge of Java but they seem to always have forgotten all of it when they reach me. Students learning C use all of the footguns you can imagine. The biggest problem for t…

NOT TRUE! You are doing it wrong If you are manually managing memory on Modern C++. C++ has RAII built in even before Rust came to the scene. I've never had a situation where I had to manage memory manually during my professional career in C++ If your students face seg faults, please show them Valgrind. Valgrind is better than GDB when it comes to seg faults. It can show you where exactly error occurred. Edit: Oh I g…

> I've never had a situation where I had to manage memory manually during my professional career in C++

I don't know what kind of career you had but it's nothing like any C++ career I've ever heard of. Do you never allocate integers or other basic types on the heap? Do you never deal with C-strings? Do you never interact with C libraries? Do you never call posix functions?

A C++ career is full of memory management. You got downvoted because it appears you're speaking from a lack of experience. Even if what you're saying is the truth, I would say you fell into a lucky niche that is unusual compared to the average C++ programmer.

Re: Android's new Bluetooth stack rewrite (Gabeldorsh) is written with Rust

#392

Earlier quoted context omitted.

Correct. It's a small table of: address1, 4 bytes overlay data address2, 4 bytes overlay data etc The data is overlayed over the specified addresses, in runtime. On some chips its 8 bytes instead of 4. On a typical Broadcom/Cypress chip you have 128 or 256 entries. By the time the chip is 2-3 years in the market and still getting firmware updates, ~98% of them are used by existing firmware, so there are only 5-10 fre…

The real brokenness here seems to be that the chips are not engineered with say ten times the patch capacity. And the root of the brokenness is that there isn't the end-to-end awareness and acceptance that ten times the capacity is obviously needed . Owww.

Easy to say, and I can’t know for sure exactly what factored impacted Broadcom’s decisions here, but I can tell you that chip manufacturers are under extreme pressure to keep costs down, which means that they may under-spec systems at times. Also, with the long design cycles involved in chip design the patch capabilities may have been decided years in advance, before realizing how much would be needed.

In general I agree with your comment, though it’s a lot easier to say this in hindsight.

Re: Android's new Bluetooth stack rewrite (Gabeldorsh) is written with Rust

#393

Earlier quoted context omitted.

It wasn't. Play services is just add on features that proxy app permissions and centralize push notifications -- no actual Android features moved into Play services that I know of. Ie: auto filling SMS OTP codes. It feels like Android is being sucked up that way, but that's because there are a lot of really nice features in there, like push notifications, geofencing, etc. You can still run Android without GMS core an…

one example i can think of without having to look things up is that the music player used to be part of AOSP and then got replaced with a google play variant e: here's an article from 2018 with some more examples: https://arstechnica.com/gadgets/2018/07/googles-iron-grip-on...

So the old music player isn't still included by default. It should still work just fine on modern android if you install it, and there's plenty of foss media players on fdroid (ie not Google-dependent), most of them thin wrappers around the android media apis with a few extras like playlists. Kodi and VLC should work fine without Google services, and LineageOS Eleven doesn't require Google, though I'm not sure if it still works on modern Android.

Lack of media playback options shouldn't be able to stop you from using AOSP.

Post reply on HN