9

Using Threads in Java

One of the first software development contracts I had was to develop software for an invisible fence security system at thoroughbred horse farms in Kentucky, USA. The computer we used was an Apple II plus. There was no such thing as threads in the 6502 CPU or the OS, ProDOS. What we did was write all the code in assembly language in small units that were measured by the number of cycles each unit took. Once we finished our allotted cycles, we would save our state in a defined region of memory and turn over control to the next unit. It worked quite well, and if a horse wandered off, alarms would be sounded. The monitoring of the fence, just a buried cable that could detect a horse walking over it, continued even while ...

Get Transitioning to Java now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.