Inspiration and Preliminary Research 2-16-2024
The idea for this project came when I visited my friend Ren. I had never been to her apartment before, so obviously I got the grand tour. As she was showing me around one of the (many) things that caught my eye was a box with several knobs on it[1], she told me about how she uses it to individually regulate the volume of several programs on her computer. I later found a post on her website detailing the project. I like the idea, but I want to take a different approach to its implementation. For starters, Ren used analog potentiometers, which is fine, but personally I prefer the click of rotary encoders. Secondly, is that Ren used a github project called deej to make the controller actually work. I’ve looked at it, and I don’t really like how it works. Looking at the code for it, it looks like it just sends the analog voltage values to the computer every loop cycle, and it just communicates over serial. This solution works, but I feel like it is… (respectfully) sloppy. I want to use this project as an opportunity to learn more about the USB protocol. I may return to Deej if I cant figure out how to make my own device, but for now im going to look into making my own HID.
One thing I found when just searching for information about the USB protocol was this old crusty website called “beyond logic”[2], which has a web book called USB in a NutShell. I really like this because its so crusty it talks ab the far off future where USB2.0 is commonplace, and mini (not micro) USB is a newfangled technology. This site ended up not being what I needed, but it might be useful for the future.
The micro controllers im most familiar with are Teensys. So I decided to see if there is a way to use Teensys as HIDs. There actually /is/ documentation regarding teensys along with LUFA to create HIDs, but unfortunatly it looks like this only works with Teensy2.0s and older. Which are discontinued. So that option is right out. However this did get me looking at other Arduino platform micros. Eventually I found the Arduino Leonardo from this video with great audio[3]. Looking deeper into the leonardo, it looks like it is capable of being an HID because it uses the ATmega32u4 microcontroller. After doing one second of googling I found these knockoff Arfuino ProMicro boards with the same microcontroller AND USBC [4].
So here is the game plan, I have two ideas. Idea 1 is to use the HID arduino library, and actually write a driver to control the linux pulseaudio channels. Idea 2 is to use the keyboard arduino library (which is a wrapper for the HID library specifically for keyboard inputs), and have the key inputs be like F24 or something, then just have like run macros or scripts or something to change the pulse audio channels. Ill buy the components soon and update when I have done some testing.
One thing to think about is that with potentiometers, the absolute positioning allows for the exact volume to be known. With encoders however the value of each sensor is unknown. So some method of feedback (besides the computer getting louder lol) will need to be implemented. Right now im thinking of either a 2 char 7 segment display to display 0-99 for each knob. Or maybe an LED thats PWM duty cycle is equal to the volume setting (0% - 100%). Either method would require that the computer sends information back to the controller to update the value, so that means that this cannot be a unidirectional stream. Herm the simplicity of the potentiometers is suddenly so appealing.
Per application sound control in Ubuntu
Haha this is post 2!
I want to start with a story from the Onion. Because really, shouldn’t every talk start with a story from the Onion? This is from earlier this year.
The headline reads: “Nation Shudders At Large Block Of Uninterrupted Text.”
“Unable to rest their eyes on a colorful photograph or boldface heading that could be easily skimmed and forgotten, Americans collectively recoiled Monday when confronted with a solid block of uninterrupted text.
“Dumbfounded citizens from Maine to California gazed helplessly at the frightening chunk of print, unsure of what to do next.
“Without an illustration, chart, or embedded YouTube video to ease them in, millions were frozen in place, terrified by the sight of one long, unbroken string of English words.
” ‘It demands so much of my time and concentration,’ said Chicago resident Dale Huza, who was confronted by the confusing mound of words early Monday afternoon. ‘This large block of text, it expects me to figure everything out on my own, and I hate it.’ ”
This is a sign of how rough the outlook sometimes seems for our culture of reading and writing.
In fact, every generation fears the death of literacy at the hands of some new media technology. And yet I’m here to share some optimism. After long existence as a confirmed cynic who shared the general belief in our imminent cultural doom, I felt an unfamiliar sensation 15 years ago when the Internet came over the horizon: I found myself becoming excited and hopeful.
When I looked at the Internet I saw a medium that involves a huge amount of reading. Sure, a lot of it is presented in a highly decorated or distracting form. But a lot of it is in large blocks of uninterrupted text, too!
And there’s something even more significant: The Web isn’t just inspiring a lot of reading. it has also opened the opportunity for a stunning amount of new writing.
When I was growing up in the 1960s and 70s, the chief fear on behalf of literary culture was that television was going to destroy it. What if we were becoming a nation of passive, glassy-eyed couch potatoes — mindless consumers of numbing video entertainment?
To some extent, that happened. Yet we survived! And then something came along that challenged TV. The Web was a two-way medium. Each consumer was also a potential creator or contributor in a way that never happened, couldn’t happen, with television. That’s a huge transformation of our media landscape, And we’re still just getting our heads around it.
So this is the National Day on Writing. I confess I didn’t know there was such a thing till I got this invitation. I’m delighted there is. But it’s an odd construction: “Day *on* writing.” It sort of sounds like those old ads that went, “This is your brain on drugs.”
Think about it: What is “your brain on writing” — or even “our world on writing”? That’s what I’m going to talk about today.
So this Day on Writing is a great thing. I admit, when I first heard it, I thought it was “day *of* writing.” You know: What are we doing here? We should all be writing, right now! Of course, the only way to be a writer is to write frequently, regularly — ideally, daily.
You could always do this, long before there was any such thing as a blog. You could keep a diary or a notebook or a commonplace book. but you couldn’t do it in public, for an audience. Now pretty much anyone can do that. And that’s changed our world in some big ways — some welcome, some distressing.
When I titled my book “Say Everything” I don’t think I realized quite what I was getting into. It turns out to be a really interesting title.
First of all, I promise I will not even attempt to say everything myself today. I’ll talk for maybe 30, 35 minutes, and then open it up for more of a conversation — which is very much the spirit of this topic, anyway.
Pretty soon after I started working on this book I realized that the title was sort of a taunt to myself. Say everything? Saying everything is a writer’s dream. It’s what you think you’ll get to do when you write a book. Get it all between covers! Then you learn that a book ends up feeling really short. And you never get to say more than a fraction of what you want.
The title also turned out to be problematic, because everyone, from my first radio interviewer on, gets it wrong. They say “Say *Anything*.” So don’t worry about it if you do, too. I don’t mind — it’s OK. I’m used to it. But my advice is, don’t give your book a title that’s just a little different from a popular old movie’s name.
I chose the title because it seems to touch on so much of what’s exciting and what’s threatening, too, about blogging and all the other changes that we call, collectively, the digital revolution. “Say everything”: the phrase suggests the thrill of the universal project the Web sometimes seems to be, in which everyone gets to contribute to a vast collective conversation and pool of knowledge. “Say everything” also raises all kinds of questions about this new world. If we say everything, how will we have time to listen? And, “Aren’t some things better left unsaid?” So these are some of the things I’m going to look at today.
Now, a little about the book itself. SAY EVERYTHING tells the story of blogging. Where did this thing come from? Who got it going, and what were their stories? So it’s a kind of contemporary history. I get two reactions when I say that: One group of people, in the technology industry, thinks blogging is now old hat. It’s over. They’ll say, “Blogging? That’s SO 1999!” They’ve already moved on. The other group, which I think is bigger than the first group, says: History? Blogging? What history? It’s so new!
In fact, blogging by that name is now a decade old, and websites that were really blogs in all but name have been around since roughly the mid ’90s. There’s a lot of history — a lot of stories — tales of what happens when people get the chance to say everything they want to in public. I think these stories have a lot to teach us about how to navigate the opportunities and pitfalls of life online.
In about a decade, then, we’ve expanded the number of people who’ve experienced writing in public by something like a factor of 100. Today, for way more of us than ever before, writing for one another is a regular part of our existence. With all the problems and the questions that new technologies raise, I still find this an incredibly hopeful development. I’m amazed and delighted that it’s happened in my lifetime. And I can’t wait to see what comes next from this vast and still growing community of keyboards. Even — or especially — if it comes in the form of large blocks of uninterrupted text.