HNHacker News
TopNewBestAskShowJobs

thought_alarm

5,145 karma · joined April 6, 2010

submissionscomments
thought_alarm··on Netscape ISP Homepage
"Designed for AOL Netscape 6"
thought_alarm··on Man who thought opening a TXT file is fine thought wrong
Java was supposed to be the primary programming language for OS X. That's why they renamed OpenStep to Cocoa (Java and Cocoa go great together).

But AppKit was still pure Objective-C, and bridging between AppKit's Obj-C APIs and the Java language presented problems. 3rd-party developers (eventually) preferred the write directly in Objective-C and Apple dropped the Java bridge some years later.

thought_alarm··on Man who thought opening a TXT file is fine thought wrong
Edit.app is the original NeXTSTEP text editor from the 1989. It supported plain text and rich text files. Famously, the first web browser was based on the rich text capabilities built into NeXSTEP.

TextEdit.app is the OpenStep rewrite of Edit.app and dates to the mid 1990s. It was likely one of the first OpenStep apps. It supported the same rich text files as the original Edit.app.

Apple bought NeXT, OpenStep became Cocoa, TextEdit was ported to Java, and then back to garbage collected Objective-C, then ARC Objective-C, (then Swift, probably).

Along the way it picked up features for reading/writing/editing HTML and Microsoft Word documents.

Apple used to publish the source code for TextEdit as part of their Xcode sample code, but they stopped a few years ago.

thought_alarm··on Apple users group meeting with Steve Wozniak (1978) [audio]
At this point in 1978 people who wanted to play around with a computer were picking up a TRS-80 from their local Radio Shack. Apple barely exists, and probably would have already gone bankrupt if not for the genius-level engineering of Woz's disk drive, which was far simpler and more reliable than anything else on the market and gave Apple its first real edge over the competition.

The Apple disk drive led to VisiCalc in 1979, and that's when Apple, and the personal computer industry in general, explodes into what we recognize it as today.

thought_alarm··on Sensible macOS Defaults
The sudo commands are system settings, the rest are user account settings.
thought_alarm··on Atari 800XL PCB Remake
Atari eventually provided excellent support for 3rd party developers, but for the first few years they didn't support any kind of 3rd party development and kept the technical documentation under lock and key. Atari also didn't want to cannibalize their game console business, so they restricted the types of 1st party games they would develop for the system.

As a result, they squandered their significant head start in the game-focused home computer market.

thought_alarm··on Internet Explorer is evil (1996)
Firefox (or the Mozilla browser that became Firefox) gave us our modern idea of tabbed browsing. If I remember correctly, it was initially an experimental feature buried in the settings, but it quickly became a popular mainstream feature that Safari and IE adopted.

Opera had an earlier version of tabbed browsing, but it was tacked on to their existing Windows MDI interface.

In the 90s, MS Visual Studio 6 had a 3rd-party plug-in that would add tabs to their existing MDI interface.

Borland's Delphi and C++ Builder may have been the first apps to provide a true tab-based document handling in the early-mid 90s.

thought_alarm··on Brad Cox has died
Objective-C was adopted by NeXT Computer in the late 1980s for their app development framework.

The modern version of Objective-C, the one that's still in use today, was developed by NeXT and Sun and was called OpenStep. The first OpenStep specification was published in 1994.

OpenStep API implementations were created for NeXTSTEP OS, Solaris, and Windows NT, running on Motorola 68040, Intel, PA-RISC, and SPARC (and later PPC) platforms.

Sun would switch gears to Java, Apple would buy NeXT, and OpenStep would become Cocoa.

thought_alarm··on Apple II Basic Bot
Yes, on the early models.

Flashing text is a feature of the video hardware, and on early Apple II models the cursor is just a space character with the Flash bit enabled.

You can turn on flashing text with the FLASH command. E.g.:

    FLASH:?"HELLO WORLD"
Later models will produce the flashing cursor in software rather than hardware, so you can't inadvertently end up with multiple flashing cursors on screen.
thought_alarm··on Apple II Basic Bot
To get around Twitter's character limit, someone invented a way of encoding machine code into a BASIC listing.

https://twitter.com/deater78/status/1348143447333597185

    10 FOR I = 0 TO 143 : POKE 872+I,4 * PEEK(2125+I) - 192 + (PEEK(2269 + I/3) - 35) / 4^(I-INT(I/3)*3) : NEXT
    
    20 &",=n9D`M1X/5Z.Ni+Mi*AS'1kD.b3kR4jjk/3bbnLX0k0j_E`>0SP.X1P2(02ImRB28=mY8J0N9:W3T/JhO;X/OoI73)mZ[/3/1BQ]g/Q<63nWoR,gb1`<QC8:JoLE0#.1+01,/omnngmo7G0S+O6::>GP'#5C`'#4RNMD%6*00),NWD4PI*+-C/Ia*Z?6*@S
thought_alarm··on Architecture of the Game Boy Advance
Nintendo's greatest technical achievement is the staggered backward compatibility between the original GameBoy, GameBoy Color, GameBoy Advance, DS, and DS 3D.

It's a game console compatibility lineage that stretches 30 years from the first GameBoy in 1989 to the end of the 3DS in 2020.

It's a remarkable achievement for a game console platform. It only happens with incredible foresight, planning, and strict software controls.

thought_alarm··on Netscape and Sun Announce JavaScript (1995)
8 months later, Microsoft would release VBScript.
thought_alarm··on Please disable JavaScript to view this site
If using Safari, use System Preferences to assign a shortcut to the "Disable Javascript" menu command (I use command+K).
thought_alarm··on Use macOS Recovery on a Mac with Apple silicon
This is pretty old news; it was all covered at WWDC in the summer.

It's still nice to see a thorough official writeup, and it will be interesting to see what the hobbyist hacker community comes up with.

thought_alarm··on Inside the stacked RAM modules used in the Apple III
The Apple III is actually a pretty interesting machine as far as older 8-bit systems go, and it includes some unique hardware features to work around the limitations of the 6502 CPU:

- The machine supports a maximum of 512 kB of RAM.

- The 6502 zero-page can be relocated on the fly to anywhere in the 512 kB address space.

- Certain 6502 addressing modes can access the entire 512 kB address space without bank switching, where it otherwise would only be able to access 64 kB.

- The area of RAM reserved for the operating system and device drivers can be protected from regular apps.

- It also includes built-in RGB video at 280x192x16 colors, and a 6-bit DAC for sound.

But even without the initial reliability problems the machine probably didn't stand a chance in the market.

It fell in the trap of being simultaneously too much computer (too expensive for what it does) and not enough computer (not powerful enough for its rather complicated operating system). And its 8-bit architecture would be quickly eclipsed by 8086 and 68000-based machines, so it was both state of the art and outdated at the same time.

Apple was right in that they needed a machine that was significantly more powerful than the Apple II, but their timing was off and the architecture was wrong. The IBM PC did a much better job of hitting the sweet spot of price vs. power vs. complexity.

thought_alarm··on Sega Master System Architecture: A Practical Analysis
The TMS9918 video chip is the common thread between those machines, and it's a fascinating bit of hardware.

The interface between the TMS9918 and its host system is dead simple: 8 data bits, 1 mode bit, 1 chip select bit, and nothing else. It manages its own 16 kB of VRAM and no other timing or clock signals are required between the 9918 and its host CPU.

As a result it was used in all sorts of machines of the era: TI 99/4A, Colecovision, Coleco Adam, MSX, Sega SG-1000, plus multiple different expansion cards for the TRS-80 and Apple II. It also supports genlock video input and was used in early-80s video production.

Most importantly, its programming interface is well defined and extensible. It allowed Yamaha and Sega to produce upgraded chips for the Sega Master System and MSX2 while maintaining backward compatibility, something that Commodore wasn't able to do with the VIC-II chip in the C64.

thought_alarm··on Windows XP leak confirmed after user compiles the leaked code into a working OS
I thought that by the time Windows XP was under development Microsoft had migrated to Perforce and individual dev teams were running their own full Windows builds.
thought_alarm··on Swift on Windows
When comparing Carbon and Cocoa, only a fool would choose to write an app in Carbon. But initially there were a few problems:

- On old 90s hardware, Carbon could be faster (due to the C API)

- Apple didn't invent AppKit or Objective-C. That technology was inherited from NeXT and from what I understand there was push-back both within Apple and from the Mac developer community about adopting a language with an unusual syntax that nobody used.

Apple tried to transition Objective-C to a modern C++ style syntax, and failed.

Apple tried to get developers to use Java with AppKit (hence, the name Cocoa) and failed.

Apple tried to get developers to adopt garbage collection, and failed.

In the end, they didn't need to do any of that. Mac developers eventually became quite enthusiastic about Objective-C and AppKit and it quickly because the one true way to write Mac apps.

However, it took many years for Cocoa and AppKit to become fully formed. Up until 2009 and OS X 10.6, there were still many things that couldn't be done in Cocoa and required the Carbon APIs, mostly related to the Mac-specific features of the file system, like persistent file references, icons, metadata, etc.

For example, if you want to implement a UI for copying a file, you're going to want to display a progress bar and have the ability to cancel the operation. Up until OS X 10.6, that simply couldn't be done with Cocoa (NSFileManager, NSURL, etc.). You had to use gnarly Carbon APIs.

(Actually, it still can't be done with NSFileManager, but Apple added that ability to the Darwin file system APIs.)

That's why the Finder was initially implemented in Carbon.

And little bits if Carbon still live on in the modern 64-bit Mac world. If you want to implement global Hot Keys in your app you have to use the Carbon API and convert the Carbon key-codes to their AppKit equivalents.

thought_alarm··on Swift on Windows
I suppose if Swift can only interoperate with C APIs, Win32 would be the only option.
thought_alarm··on Swift on Windows
I haven't done Windows development in over 10 years, but I really wasn't expecting to see what appears to be a stripped down implementation of AppKit wrapped around the old Win32 APIs, like it's 1999. (Nor Hungarian Notation).

I thought WPF or WinRT or UWP was supposed to have replaced Win32 by now.

thought_alarm··on Why the Apple II Didn’t Support Lowercase Letters
Right, but in text mode the 9918 draws 6 native pixels for every 8 NTSC color "pixels". So, measured in NTSC color pixels, it's 320 wide (40x8) compared to 280 (40x7) for the Apple II.

This image (white text on a blue background) shows how the 9918's native pixels line up with the NTSC color burst frequency: https://imgur.com/rGcRpw0

thought_alarm··on Why the Apple II Didn’t Support Lowercase Letters
Bitmap mode is made up of 8x8 tiles. The screen is 32x24 tiles, or 256x192 pixels. 2 colors per line per tile. So a single tile can contain up to 16 colors.

A single screen is divided into 3 separate tile maps, each 256 bytes long.

It also supports 32 spirtes but only 4 sprites per scanline, which is its biggest limitation.

The Sega Master System used an upgraded version of the 9918, adding 64 colors, smooth scrolling, and 8 sprites per scanline, all within the same 16 kB of VRAM.

thought_alarm··on Why the Apple II Didn’t Support Lowercase Letters
Speaking of add on cards, I own a TMS9918 video card for my Apple II. It's remarkably simple. The 9918 manages its own 16 kB of VRAM and it doesn't place any timing restriction on the host system.

You'd think that the 9918 would be a bottle neck between the CPU and the VRAM, but the Apple II can write to the 9918 VRAM as fast as its own internal RAM. Faster, actually, since the destination address auto-increments. That was a surprise.

thought_alarm··on Why the Apple II Didn’t Support Lowercase Letters
Right, but the Apple II video generator is already reading 40 bytes per scan line, and is using all 8 bits of each byte to generate the video signal. I would think that drawing 8 pixels per byte instead of 7 would have been the simpler thing to implement.
thought_alarm··on Why the Apple II Didn’t Support Lowercase Letters
Actually, the very first Apple IIs only supported 4 colors in hi-res mode. The 8th bit was ignored.

A later revision added support for 6 colors, using the 8th bit to shift the pixels and change the pallet.

thought_alarm··on Why the Apple II Didn’t Support Lowercase Letters
The Atari 400/800 and the TMS9918 (TI 99/4A, Colecovision, etc.) are 320 pixels wide and were designed to run on those same 1970s home television sets, and they didn't have an overscan problem (maybe some sets did, but most didn't). I don't think the Apple II had to cut the screen width down to 280 pixels.

That's the heart of the question. Did Woz think that 320 pixels would not fit, or did he cut the width down for another reason, like more color.

thought_alarm··on Why the Apple II Didn’t Support Lowercase Letters
That's another thing I've wondered about. Did the Apple I also output 7 pixels per character? Since it doesn't do color and doesn't care about the color burst frequency, it's free to use any size of pixel it wants. With a 5x7 font, I would have guessed that 6 pixels per char would be simpler.
thought_alarm··on Why the Apple II Didn’t Support Lowercase Letters
That seems like a big price to pay for slightly better text spacing. Virtually every other home computer used 6 or 8 pixels per char/byte.

I don't think overscan would be an issue. The TMS9918 is also (the equivalent of) 320 pixels wide, and it was used in many different home computers and game consoles intended to connect to the family TV. There's no overscan issue, unless it's connected to an Apple II monitor.

When the TMS9918 is connected to an Apple II monitor there is a huge overscan issue, since the monitor is tuned for the narrower Apple II screen. It looks like this: https://imgur.com/rGcRpw0

That's what got me thinking about this issue is the first place.

thought_alarm··on Why the Apple II Didn’t Support Lowercase Letters
I've always wanted to know why Apple II video screen is only 280 pixels wide.

The Apple II video screen is 40 bytes wide, but it only draw 7 pixels per byte, for a total of 280 pixels. The 8th bit was used for selecting the color pallet (eventually; initially the 8th bit was just ignored)

Drawing 7 pixels per byte makes everything a lot more complicated, so it would seem to go against Woz's obsession for simplicity. It's hard to believe that 7 pixels per byte would reduce the chip count, and it certainly makes the software a lot more complicated (lots of divide-by-sevens).

CGA graphics and the Atari 400/800 also provide a composite graphics mode similar to the Apple II, where each pixel lines up with the NTSC color burst frequency, but they draw 8 pixels per byte for a total of 320 pixels, and therefore use a wider portion of the screen.

Perhaps Woz thought (incorrectly) that the NTSC screen wasn't wide enough to accommodate 40x8 (320) pixels so he cut it down to 40x7, or he planned all along to use the 8th bit to provide extra color. It would be interesting to know the actual reason.

thought_alarm··on The 20th anniversary of the Power Mac G4 Cube
The Cube with matching LCD monitor and USB keyboard was way ahead of its time. A premium product at a premium price.

The problem was software. Apple did not have the operating system to justify such a premium product. MacOS 9 was laughably dated, slow, and unstable, especially compared to Win2000 and WinXP, and OS X was years away from being ready.

The hardware writes a check that the software can't cash. Anyone would have been better with a PowerMac or a Win2k machine.

I own a Cube, and with OS X 10.4 installed it is a completely different machine. It boots faster than a modern Mac, and is light years ahead of aged Mac OS 9 and the early versions of OS X. It feels utterly modern, and takes full advantage of the tight integration between the hardware, LCD monitor, and USB peripherals.

Unfortunately for Apple, OS X 10.4 was released 4 years after the Cube was cancelled. I think that if Apple had OS X 10.4 ready in 2000, we would look back at the Cube in a different way.

← PreviousPage 4 of 28Next →