@mort@fosstodon.org avatar

mort

@mort@fosstodon.org

Programmer, mostly writing C++, C and Go.

This profile is from a federated server and may be incomplete. Browse more on the original instance.

mort, to linux
@mort@fosstodon.org avatar

One of the most frustrating thing about #Asahi #Linux: #GNOME is so incredibly close to working perfectly witch a notch. Literally all you need to do is to increase the size of the top bar size a bit and move the calendar/notifications menu to the right and it's perfect.

But GNOME doesn't have those options, you have to use extensions. And changing the top bar size from an extension is buggy and breaks in weird ways after suspend.

But with the top bar size tweak, maximized windows end up obscured by the top bar after a resume.

mort,
@mort@fosstodon.org avatar

I actually started planning a blog post about how well GNOME can work with a notch because its design happens to be an almost perfect match already. I stopped when I started having this issue.

I tried finding ways to work around it. IIRC, if I modified the bar height through changing the default theme's CSS, it would work fine. But the default theme's CSS file is bundled in a .gresource file, and it gets overwritten when GNOME updates, so it wasn't practical.

mort,
@mort@fosstodon.org avatar

@cassidy Honestly exposing a "top bar height" option and a "clock position left/right/center" option in settings would get us 99% of the way there, especially if the Asahi-focused distros set those options by default.

Automatically setting those options based on some sort of "safe area insets" hardware info API would be cool. But my experience fighting libinput tells me that options which have no way of being set other than through a hardware info database is a terrible idea and doesn't work.

mort,
@mort@fosstodon.org avatar

@agx @cassidy Some sort of wayland protocol would be needed for truly fullscreen apps which want to draw around the notch, yeah. But a pretty good alternative would be to lie about the screen dimensions to the wayland client and make it think only the part below the notch/top bar exists, right? I believe that's what macOS does most of the time.

eniko, to random
@eniko@peoplemaking.games avatar

i saw a post on here (cant find it now) where someone said that people trying to target obsolete platforms apparently often use riscv and then just compile an interpreter for riscv for the platform and wow that actually makes a ton of sense

you can write a dead simple riscv interpreter for rv32im in an afternoon and riscv has a lot of modern support. plus you can easily interact with the host via ecall/ebreak which are part of the core instruction set

๐Ÿคฏ

mort,
@mort@fosstodon.org avatar

@eniko You know exapunks? https://store.steampowered.com/app/716490/EXAPUNKS/ There's no reason one couldn't make a similar game but using risc-v assembly language...

SirTapTap, to random
@SirTapTap@mastodon.social avatar

Why are bluesky profile URLs so ugly? Example, mine:

https://bsky.app/profile/sirtaptap.bsky.social

I love Mastodon's solution, just including the @ in the URL solves Twitter's problem of "oops, we can't have a twitter.com/ music because we let a user be @music"

mort,
@mort@fosstodon.org avatar

@SirTapTap I always thought those "besky dot social" URLs sounded weird in my head.

A very related tip: drop the dashes. Nobody wants to say "some dash cool dash website dot com". Saying "some cool website dot com, one word" is so much nicer.

eniko, to random
@eniko@peoplemaking.games avatar

i dont know if im just uniquely bad at reading other peoples code or if everyone finds it incredibly difficult

mort,
@mort@fosstodon.org avatar

@eniko I feel like I'm good at drilling down into someone's code to figure out or change some specific thing ... but reading other people's code to try to get a complete picture? That's incredibly difficult and takes a lot of time and mental effort.

Honestly I think it's why rewrites are so popular. We say things like "the old system had a lot of tech debt" and while that's sometimes true... it was also just written by someone else. Everyone loves a greenfield project. This explains NIH too.

aleen, to random
@aleen@wandering.shop avatar

Watching The Witcher with Apple Products in the room now that you don't have to say "Hey Siri"? Highly annoying.

mort,
@mort@fosstodon.org avatar

@aleen Actually how do these tech giants think it's okay to just ... ruin actual human names which used to belong to real people?

It must actually really fucking suck to be called Siri or Alexa as everyone all of a sudden becomes afraid to use your name.

eniko, (edited ) to random
@eniko@peoplemaking.games avatar

considering doing Lisp Crimesโ„ข by making { } shorthand for progn or block or whatever

mort,
@mort@fosstodon.org avatar

@eniko In my lisp (https://github.com/mortie/osyris) I made {} mean the same as '(), i.e it's a quoted list. I also made the 'lambda' constructor function take a quoted list rather than making it a weird special form thing

I like lisp crimes.

eniko, to random
@eniko@peoplemaking.games avatar

i regret to inform you,

mort,
@mort@fosstodon.org avatar

@eniko ok but why are headers in Header Files/ not in include/

fasterthanlime, to random
@fasterthanlime@hachyderm.io avatar

Apple Music's "Spatial Audio" feature is so good, it's a "what if nobody bothered to mix the track" button and the surprise is always delightful (if hard to listen to).

It's like your head is stuck inside of a beer keg at the party next door to a live performance of your favorite studio album. Incredible really.

mort,
@mort@fosstodon.org avatar

@fasterthanlime It really does sound impressively terrible. I do not understand how any product manager or audio engineer can try to listen to music with spatial audio enabled and think, "this is a much better experience than listening to the official stereo mix".

But what I find even more baffling is, how in all hells did the feature ship without a global off switch??? You have to disable it from control center independently for each app/sound source, and that only works for some apps.

mort,
@mort@fosstodon.org avatar

@fasterthanlime That's per-app! If you disable spatial audio in e.g Apple Music that way, it will enable itself when you start playing YouTube until you disable it there too.

And it seems to affect the app associated with the current audio source, not the current foreground app. So it's literally impossible to disable for Snapchat, because Snapchat stops playing (and thus is no longer the current audio source) when you open control center.

I hate it

eniko, (edited ) to random
@eniko@peoplemaking.games avatar

well, i've got something going at least, my REPL can handle (hex only*) integers

*RV32I doesn't come with mul/div so hex only for now >_>

EDIT: for the non-followers finding this thread: i'm making a lisp to form the shell (and ultimately self-hosted compiler) for a RISC-V toy OS i wanna make

mort,
@mort@fosstodon.org avatar

@eniko Interesing! My GCs have always been basically: use malloc to allocate objects, then do mark+sweep to call free() as appropriate. But it makes total sense that you could use a much simpler allocator when you combine it with a GC rather than implementing the malloc+free interface. I need to try that some time.

mort,
@mort@fosstodon.org avatar

@eniko My solution has always been to make variable scopes be string->value maps with a parent pointer, and then make the lambda have a reference to its enclosing scope. GC takes care of the rest.

Bonus: if you make such a "string->value map with a parent pointer" a native language type, you have JS-style objects with prototypical inheritance! ... but maybe don't do that for a lisp, idk, your language

eniko, to random
@eniko@peoplemaking.games avatar

i still have not decided whether i wanna go with risc-v or if i wanna roll my own ISA

i guess RV would have the widest appeal but im not really doing a hobby OS side project to appeal to lots of people since it's not like it'll ever really be a practical thing anyway

mort,
@mort@fosstodon.org avatar

@eniko Making your own ISA is fun. However, my experience from OS class in university is that seeing your own OS boot on physical hardware is super rewarding. If you make your OS for RISC-V, you'll be able to buy a RISC-V dev board some time and boot your own OS on it. And that's bloody badass.

Plus, RV is so simple that you can make your own emulator for it no problem.

mort,
@mort@fosstodon.org avatar

@eniko I implemented RV32 in Logisim: https://github.com/mortie/rv32i-logisim-cpu/, and being able to compile C code with Clang and upload it to my Logisim project's ROM block and ACTUALLY EXECUTE IT was incredibly satisfying.

mort,
@mort@fosstodon.org avatar

@eniko You'd certainly have to write device drivers, yeah. Though don't you have to do that for whatever virtual hardware QEmu (or your own VM) exposes too? I frankly don't know how sound hardware looks like from a kernel software perspective, virtual or otherwise.

But hey you're not making a custom OS because it's easy are you

mort,
@mort@fosstodon.org avatar

@eniko That's true I guess, define a block of address space to be the "audio buffer" and make the emulator read that and boom, sound.

With physical hardware, I think the easiest way to achieve sound would be to figure out how to drive the UART and write a program on your computer which reads audio samples from serial and plays them... A sort of physical hardware version of a passthrough driver

mort,
@mort@fosstodon.org avatar

@eniko For random uart hacks, I can recommend the pyserial library, I have so many situations where I'm abusing uart in some weird way! Most recently I was working on a thing which needs to communicate with a screen over uart, but I need to see logs as a developer... so I made a uart proxy program which prints log messages to my terminal but forwards data messages to the screen.

Plus I made this serial console with it after being unsatisfied with screen/miniterm/etc: https://github.com/mortie/sercom

mort, to ubuntu
@mort@fosstodon.org avatar

ok I don't know if this is on #Ubuntu or #GNOME but when I open Ubuntu Software and search for Godot, the search results I see are: "Godot Engine" (missing icon), "Godot Engine", "godot-3-1" (missing icon but differently), "Godot Engine C#", "godot-4", "godot4-mono" and godot4.

How are users supposed to know which to pick?

It seems like most of these are snaps. Why are there so many snap versions?

Why is the deb version missing an icon?

Why is the deb still on 3.x?

eniko, to random
@eniko@peoplemaking.games avatar

there's a special place in hell for people who write documentation where the 1st bit is indexed as bit zero

mort,
@mort@fosstodon.org avatar

@eniko "The 8th array element" is array element 7, we're used to this. What's so weird about saying that "the 8th bit" is bit 7 by the same logic?

If they do use "the 8th bit" to mean bit 8 when counting from 0, I agree that's bad. But I have the same criticism of people who use "the 8th array element" to mean arr[8].

mort,
@mort@fosstodon.org avatar

@eniko The concept of a bit set isn't that uncommon, for example in C++ a std::bitset<32> is (essentially) a u32 which you can index with the [] operator. It's zero-indexed.

But the point was more that the idea is the same, the first bit is bit 0 like the first array element is element 0. And the way to get array element 'i' is '*(arr + i)', like the way to get bit 'i' is 'num & (1 << i)', as you point out.

mort, to apple
@mort@fosstodon.org avatar

did #Apple really have to give the iPhone 15 non-pro a USB-C port that's only capable of USB 2 speeds

I mean we're almost in 2024 and they're making USB-C ports which max out at 50MB/s

mort, to github
@mort@fosstodon.org avatar

Since this #github #2fa thing is happening, I'm gonna need a better solution for 2fa.

So far I've used Authy on my phone for work stuff. That's fine. But for personal stuff, I want more control.

What good open-source options exist to deal with TOTP? I'm thinking I'll use Bitwarden to sync TOTP seed secrets or whatever, which means I need apps which let me freely and easily copy those secrets around.

I need these apps for #Linux, #macOS and #iOS.

eniko, to random
@eniko@peoplemaking.games avatar

Capitalism be like "it's not okay to pay a sex worker with your credit card but it is okay for a car manufacturer to sell sex tapes of you having sex in your car made without your consent to unidentified third parties"

mort,
@mort@fosstodon.org avatar

@eniko If this was a black mirror plot I would've criticized the episode for painting car/tech companies as unrealistically evil

  • All
  • Subscribed
  • Moderated
  • Favorites
  • โ€ข
  • provamag3
  • mdbf
  • ngwrru68w68
  • modclub
  • magazineikmin
  • thenastyranch
  • rosin
  • khanakhh
  • InstantRegret
  • Youngstown
  • slotface
  • Durango
  • kavyap
  • DreamBathrooms
  • JUstTest
  • GTA5RPClips
  • ethstaker
  • normalnudes
  • tester
  • osvaldo12
  • everett
  • cubers
  • tacticalgear
  • anitta
  • megavids
  • Leos
  • cisconetworking
  • lostlight
  • All magazines