PET killer POKE detector?

Other Computers and Game Systems

Moderator: Moderators

Post Reply
User avatar
ral-clan
plays wooden flutes
Posts: 3702
Joined: Thu Jan 26, 2006 2:01 pm
Location: Canada

PET killer POKE detector?

Post by ral-clan »

Hi,

I have a PET 8032 (actually a SuperPET) and it's one with the video chip that can be affected by the killer POKE that speeded up the video of the older machines, but could damage later PETs.

The poke is:
POKE 59458,62

Now, I have hundreds of pieces of PET software downloaded from the internet and it's too many to go through one at a time to look for this POKE.
Is there any piece of software on a modern computer that can batch scan the contents of a .prg or .d64 file and search for this particular command in a program?

That would be such a help.
Image Music I've made with 1980s electronics, synths and other retro-instruments: http://theovoids.bandcamp.com
groepaz
Vic 20 Scientist
Posts: 1187
Joined: Wed Aug 25, 2010 5:30 pm

Re: PET killer POKE detector?

Post by groepaz »

automatically... that would be really hard. its easy to obscure such a poke, and when its "behind" some user interaction, then the automatic process would have to "use" the program

if its only about (pure) basic programs, then you could try converting them to textfiles, and then eg search for "59458" using eg grep. however, that will also only find the poke when it actually uses "59458"

(isnt it the monitor that gets demaged, not the video chip?)
I'm just a Software Guy who has no Idea how the Hardware works. Don't listen to me.
User avatar
cbmeeks
Vic 20 Enthusiast
Posts: 190
Joined: Tue May 18, 2004 12:36 pm
Website: http://meeks.co
Location: 8-bit Land
Occupation: Code Monkey

Re: PET killer POKE detector?

Post by cbmeeks »

Not to mention that it would be so easy to do things like INC $E842 until it came to the killer value. With indirect addressing it would be almost impossible to find code like that.

Having said all of that...has anyone actually known/seen a PET be destroyed by the killer poke? Or is it just urban legend?
Cat; the other white meat.
User avatar
ral-clan
plays wooden flutes
Posts: 3702
Joined: Thu Jan 26, 2006 2:01 pm
Location: Canada

Re: PET killer POKE detector?

Post by ral-clan »

cbmeeks wrote:Having said all of that...has anyone actually known/seen a PET be destroyed by the killer poke? Or is it just urban legend?
I have never heard of any direct story of a monitor dying, just indirect ones (i.e. "I know a person to whom that happened...").

As for my 8032 PET, when I encounter this poke in a program, the screen compresses and get a little brighter. After that I quickly turn off the machine...and I'm sure you can imagine I'm not willing to let it run for any length of time like this in order to see what happens.

So, while I'm sure it possibly could do some CRT damage, I think a few seconds like this doesn't harm the PET.

Mostly, the POKE is not hidden in software (in a malicious way). It was merely used in BASIC as a means to speed up the video output of older PETs, where it was helpful instead of harmful. When they changed the video chip in the later PETs, it caused the problem, because of some video sync issue, or scan rate issue. Yes, it is the CRT that will burn out, not the video chip, but the video chip causes the issue.
Image Music I've made with 1980s electronics, synths and other retro-instruments: http://theovoids.bandcamp.com
Kakemoms
Vic 20 Nerd
Posts: 740
Joined: Sun Feb 15, 2015 8:45 am

Re: PET killer POKE detector?

Post by Kakemoms »

cbmeeks wrote:Not to mention that it would be so easy to do things like INC $E842 until it came to the killer value. With indirect addressing it would be almost impossible to find code like that.

Having said all of that...has anyone actually known/seen a PET be destroyed by the killer poke? Or is it just urban legend?
Interesting. I made a 6502 bus decoder which would be able to catch such an instance. I don't know wether its a market for this (since it obviously would require a new pcb and a few components), but it's certainly possible. I only have a 8296.. which is currently in need for some repairs.
User avatar
cbmeeks
Vic 20 Enthusiast
Posts: 190
Joined: Tue May 18, 2004 12:36 pm
Website: http://meeks.co
Location: 8-bit Land
Occupation: Code Monkey

Re: PET killer POKE detector?

Post by cbmeeks »

Kakemoms wrote:Interesting. I made a 6502 bus decoder which would be able to catch such an instance. I don't know wether its a market for this (since it obviously would require a new pcb and a few components), but it's certainly possible. I only have a 8296.. which is currently in need for some repairs.
What I was mostly referring to was the fact it would be hard to detect the "Killer Poke" using software. For example, if I had every PET specific software ever written on my hard drive, it would difficult (though, maybe not impossible) to scan all of that software looking for the Killer Poke.
Cat; the other white meat.
groepaz
Vic 20 Scientist
Posts: 1187
Joined: Wed Aug 25, 2010 5:30 pm

Re: PET killer POKE detector?

Post by groepaz »

what about patching the basic interpreter? that should be fairly easy, and would probably defeat most instances of this problem
I'm just a Software Guy who has no Idea how the Hardware works. Don't listen to me.
User avatar
eslapion
ultimate expander
Posts: 5458
Joined: Fri Jun 23, 2006 7:50 pm
Location: Canada
Occupation: 8bit addict

Re: PET killer POKE detector?

Post by eslapion »

groepaz wrote:what about patching the basic interpreter? that should be fairly easy, and would probably defeat most instances of this problem
Would probably require enlarging the space occupied in the firmware by the POKE command to trap these specific values.

It would also make this specific command execute slower and affect all BASIC programs.

Intercepting a specific value poked at a specific address by a 8 bit CPU requires a logic circuit with 25 IOs (16 address lines, 8 data lines and one output). That's pretty much the same as the number of IOs on a PLA substitute.

Could easily reprogram a PLAnkton to do just that and force a CPU reset when it occurs.
Be normal.
groepaz
Vic 20 Scientist
Posts: 1187
Joined: Wed Aug 25, 2010 5:30 pm

Re: PET killer POKE detector?

Post by groepaz »

CPU reset? oh that sounds helpful >_<
I'm just a Software Guy who has no Idea how the Hardware works. Don't listen to me.
Kakemoms
Vic 20 Nerd
Posts: 740
Joined: Sun Feb 15, 2015 8:45 am

Re: PET killer POKE detector?

Post by Kakemoms »

groepaz wrote:CPU reset? oh that sounds helpful >_<
Well, it would save the PET... but he was probably thinking about a display chip reset.
groepaz
Vic 20 Scientist
Posts: 1187
Joined: Wed Aug 25, 2010 5:30 pm

Re: PET killer POKE detector?

Post by groepaz »

if you'd build hardware to do this, it'd make a whole lot more sense to simply gate r/w ... or even a single data line, so the problematic bit will simply not be written and the software will keep working (but what do i know).

anyway, a BASIC patch should be simple and straightforward. and since PET stuff typically doesnt contain POKE orgies like vic20 or c64 BASIC programs that shouldnt even have significant performance impact.
I'm just a Software Guy who has no Idea how the Hardware works. Don't listen to me.
Post Reply