HNHacker News
TopNewBestAskShowJobs

svendahlstrand

104 karma · joined October 19, 2012

submissionscomments
svendahlstrand··on Ask HN: What lesser-known accessories do you use with your computer?
I don't have it connected at the moment, but I built this rotary dial accessory for my Mac [0] so I could make FaceTime calls in an old-school fashion. The signification impact it had on my workflow? It forced me to take it slow, I guess. :)

Petmoj is Swedish slang for a rotary dial.

[0]: https://dahlstrand.net/2016/01/24/petmoj.html

svendahlstrand··on Extracting the GameBoy ROM from photographs of the die
Shameless self-promotion: if you enjoyed Travis' ROM dumping, you might find my piece about sniffing the Game Boy's LCD data bus to take screenshots interesting as well.

https://github.com/svendahlstrand/game-boy-lcd-sniffing

svendahlstrand··on iPhones and action discoverability
Undo and redo:

Undo the last edit: Swipe left with three fingers, then tap Undo at the top of the screen.

Redo the last edit: Swipe right with three fingers, then tap Redo at the top of the screen.

https://support.apple.com/guide/iphone/type-with-the-onscree...

svendahlstrand··on iPhones and action discoverability
You should turn it off then. :) Search for shake in the Settings app.
svendahlstrand··on iPhones and action discoverability
The Back Tap feature is my favorite "hidden" action on the iPhone. You can double (or triple) tap the back of the phone to trigger whatever action you want. For example, toggle the flashlight or lock rotation. Show Spotlight or run a Shortcut.

https://support.apple.com/guide/iphone/back-tap-iphaa57e7885...

I think Apple does a decent job telling people about iOS features across the User Guide, Tips.app, and the Apple Support YouTube channel.

The "undiscoverable" features in the article are all there.

Delete the last digit: If you make a mistake when you enter a number, swipe left or right on the display at the top.

https://support.apple.com/guide/iphone/calculator-iph1ac0b5c...

Turn the onscreen keyboard into a trackpad.

1. Touch and hold the Space bar with one finger until the keyboard turns light gray.

2. Move the insertion point by dragging around the keyboard.

https://support.apple.com/guide/iphone/type-with-the-onscree...

To access other open tabs, you can swipe left or right on the tab bar.

https://youtu.be/30tfnCxLWSg?t=21

svendahlstrand··on Remove Google Account After Factory Reset (2019)
> Global Drop In Smartphone Thefts Following Introduction Of Kill Switch[.] New Data Reveal Thefts Down 40% In London; 22 % In San Francisco; And 16% In New York City

https://ag.ny.gov/press-release/2015/ag-schneiderman-london-...

svendahlstrand··on Choosing tools for Game Boy development
Yes, I've dabbled around with the NES as well. But the Game Boy is close to my heart as I had one as a kid. So most of my projects [3] revolve around that old gray brick.

[3]: https://hackaday.io/project/167042-joy-boy

svendahlstrand··on Choosing tools for Game Boy development
I believe the LR35902 SoC is exclusive for the Game Boy, but the actual CPU core, SM83, is probably used elsewhere. Sharp's datasheets [2] mention home appliances as intended application.

[2]: https://duckduckgo.com/?q=sharp+sm83+datasheet

svendahlstrand··on Choosing tools for Game Boy development
The official Game Boy Programming Manual [0] leaked and is available at the Internet Archive. It's a great resource.

If you're just getting started with assembly and want to look at a short program, my maze generator [1] is available on GitHub with annotated source code.

[0]: https://archive.org/details/GameBoyProgManVer1.1

[1]: https://github.com/svendahlstrand/10-print-game-boy

svendahlstrand··on Ask HN: What is the most beautiful piece of code you've ever read?

  ,[.,]
When it comes to the weird and wonderful world of esoteric programming languages, the above Brainfuck program is pretty elegant. It's a basic implementation of the echo program: printing back what the user inputs.

The complete language consists of eight single-character commands. The four used in the echo program is:

, – accept one byte of input and store it at the current memory cell

. – output the byte at the current memory cell

[ – if the value of the current memory cell is zero, jump forward to the command after the matching ]

] – if the value of the current memory is nonzero, jump back to the command after the matching [

svendahlstrand··on 10 PRINT CHR$(205.5+RND(1)); : GOTO 10 (2012)
That's a great read! The book inspired me to port that BASIC one-liner to Game Boy flavored assembly. Still having a Game Boy lying around? Now you have portable mazes:

https://github.com/svendahlstrand/10-print-game-boy

svendahlstrand··on Apple says no Java for you, removes plugin from browsers on OS X 10.7 and up
How to enable Java browser plugin again: http://news.ycombinator.com/item?id=4672511.