Thread: Programming
View Single Post
Old Today, 20:05   #9
Anonymouse
RIP Tigger - 13 years?!
 
Join Date: Jul 2005
Location: Bolton
Age: 60
Services: BT Superfast Broadband
Posts: 1,688
Anonymouse has a bronzed appealAnonymouse has a bronzed appeal
Anonymouse has a bronzed appealAnonymouse has a bronzed appealAnonymouse has a bronzed appealAnonymouse has a bronzed appealAnonymouse has a bronzed appealAnonymouse has a bronzed appealAnonymouse has a bronzed appealAnonymouse has a bronzed appealAnonymouse has a bronzed appealAnonymouse has a bronzed appealAnonymouse has a bronzed appeal
Re: Windows 11 25H2 officially released

Oh, C. I did love that, at Kalamazoo in Manchester, as part of some City & Guilds course or other, running on UNIX, and again in 1998 on NT (3.5 or 4? Can't remember.)

I did like the '98 lecturer. I remember one time a student switched off his PC without shutting it down properly (he thought he was doing the guy, who'd stepped out for a bit, a favour); this tended to screw up NT PCs, especially on the multi-user system we had. The next day the student was, luckily for him, off sick. The lecturer (I think he was from Saudi Arabia) said, "I wait till he's better, then I kill him!" .

At Kalamazoo we used JSP, which forces you, at base level, to base all your program modules on functions - which is the C ideal anyway.
I pointed this out to our lecturer. "The only way you can reconcile program actions with C is to reduce everything to functions."
"That's the idea. A C program should be functions anyway." (He was a man after my own heart, describing the difference between hacking and cracking. The former is something I've done, i.e. getting into the guts of the system, finding out how things work and making them work better and/or differently*, whereas cracking is breaking in illegally - he rightly pointed out that 'hacking' was a sorely-abused term. This was in '94, but it's still true today. A hacker is not a cracker, and vice versa.)
"Hmm. Makes sense."

The thing is, C made sense. This is one reason why UNIX/Linux is written in it. Pointers were easy, and they too made sense. I actually wrote a hex monitor program in C, to decode a .EXE file into ASCII, so you could read any embedded text messages. A line would look like:

0AF0 41 20 70 72 6F 67 72 61 6D 20 74 6F 20 61 73 63 A program to asc

with nonprinting characters represented as dots. I later migrated it to Win 98 and 2000 (I dual-booted them), and it worked fine. Watney used a similar hex editor in the film version of The Martian to hack the Rover so it could talk to Pathfinder.

You just try that in BASIC!
(Can be done, but it's much more difficult.)

* A good example of this was on the SHARP MZ-700, which used a built-in cassette drive. Loading up a program from the Machine Code Monitor (the MZ-700 didn't have, e.g., BASIC on ROM, so it could run any version of BASIC, FORTH - ooh, I forgot about that! - or any other language) caused it to automatically run, which was no good if you wanted to create a backup. Wasn't as simple as copying the tape - I know, I tried. But you needed to know the start address, the execution address (not necessarily the same) and the file length in order to copy a file via the MCM. Simple enough; S (Save) <start address> <end address> <execution address> filename to save a block of memory, addresses in hexadecimal.
So after reading the monitor manual (so helpful!) to figure out how the loading process worked, I wrote a Z80 Assembler program (all praise to HiSoft, whose Devpac Assembler program was brilliant!) to intercept a program while it was loading and stop it auto-running, delivering said data. I successfully backed up BASIC and a favourite game, a low-res (characters only) Defender clone.
This had to be done - we (oldies, anyway) all know how vulnerable cassette tapes were, and I was doing a course in BASIC; losing that tape would've crippled me. This was backing up, not ripping off (though it later occurred to me, guiltily, that it could be used for that purpose, oops ).
I wrote to the user group, detailing my hack - and I was awarded a £25 voucher! Result!
I miss that computer. Superb keyboard (I consider myself a keyboard connoisseur - VIC-20 excellent, MZ-700 same, ATARI ST good, VT220 and VT320 on the VAX excellent despite the < > issue mentioned earlier, first PC...eew). Flexible design because it was a "clean" computer, no OS or BASIC in ROM. Built-in and very powerful & useful MCM, FULLY DOCUMENTED. They don't make 'em like that any more.
__________________
"People tend to confuse the words 'new' and 'improved'."
- Agent Phil Coulson, S.H.I.E.L.D.

WINDOWS 11, ANYONE?!

Last edited by Anonymouse; Today at 21:48.
Anonymouse is online now   Reply With Quote