From 035b386f6c493e2f9ecb3ce487fcce802b5e425d Mon Sep 17 00:00:00 2001 From: Paul Gardner-Stephen Date: Wed, 24 Apr 2019 15:53:32 +0930 Subject: [PATCH] and more... --- strings/0260A9 | 3 ++ strings/028D91024C | 4 +++ strings/AD0DDCAD | 5 +++ strings/B1AC91D1 | 5 +++ strings/B1AE91F3 | 3 ++ strings/C8B1D18891D1C8B1F38891F3C8C4D5D0EF | 41 ++++++++++++++++++++++ strings/D007A980 | 4 +++ strings/DE3F815F | 16 +++++++++ 8 files changed, 81 insertions(+) create mode 100644 strings/0260A9 create mode 100644 strings/028D91024C create mode 100644 strings/AD0DDCAD create mode 100644 strings/B1AC91D1 create mode 100644 strings/B1AE91F3 create mode 100644 strings/C8B1D18891D1C8B1F38891F3C8C4D5D0EF create mode 100644 strings/D007A980 create mode 100644 strings/DE3F815F diff --git a/strings/0260A9 b/strings/0260A9 new file mode 100644 index 00000000..23b47ac6 --- /dev/null +++ b/strings/0260A9 @@ -0,0 +1,3 @@ +Something, RTS, LDA #$xx + +Here is only one whole instruction, and RTS. Not copyrightable. diff --git a/strings/028D91024C b/strings/028D91024C new file mode 100644 index 00000000..70e9bc04 --- /dev/null +++ b/strings/028D91024C @@ -0,0 +1,4 @@ +Fragment / STA $028D / JMP $xxxx + +Only one whole instruction. Not copyrightable. + diff --git a/strings/AD0DDCAD b/strings/AD0DDCAD new file mode 100644 index 00000000..d4c707e3 --- /dev/null +++ b/strings/AD0DDCAD @@ -0,0 +1,5 @@ +LDA $DC0D / LDA $xxxx + +LDA $DC0D clears pending interrupts on CIA1. +Only one whole instruction. +Not copyrightable. diff --git a/strings/B1AC91D1 b/strings/B1AC91D1 new file mode 100644 index 00000000..b20a246d --- /dev/null +++ b/strings/B1AC91D1 @@ -0,0 +1,5 @@ +LDA ($AC),Y / STA ($D1),Y + +Copy a byte from one pointer to another. +Nothing creative here. +Not copyrightable. diff --git a/strings/B1AE91F3 b/strings/B1AE91F3 new file mode 100644 index 00000000..04534785 --- /dev/null +++ b/strings/B1AE91F3 @@ -0,0 +1,3 @@ +LDA ($AE),Y / STA ($F3),Y + +Copy byte from one pointer to another. Nothing copyrightable here. diff --git a/strings/C8B1D18891D1C8B1F38891F3C8C4D5D0EF b/strings/C8B1D18891D1C8B1F38891F3C8C4D5D0EF new file mode 100644 index 00000000..65a90085 --- /dev/null +++ b/strings/C8B1D18891D1C8B1F38891F3C8C4D5D0EF @@ -0,0 +1,41 @@ +Copy screen + colour RAM to the left one place + +This sequence of instructions: + +loop: + INY + LDA ($D1),Y + DEY + STA ($D1),Y + INY + LDA ($F3),Y + DEY + STA ($F3),Y + INY + CPY $D5 + BNE loop + +is the obvious any minimal way to copy the screen and colour RAM data. +The constants $D1 and $F3 are fixed by the publicly documented interface +of the KERNAL to point to the screen and colour RAM of the screen. + +The Y register is the only register that can be used to post-increment an +indirect address on the 6502. + +Thus the only efficient manner to copy a string to the left one byte +is to read, decrement Y by one to get the destination address, store, +then increment Y again so that it points to the source offset, now read +the colour RAM byte, add one to Y so that we point to the destination, +and then write it. + +Similarly the check against $D5 (current length of line) is also +necessary for working out when to terminate the loop. + +In fact, about the only variant possible would be to swap the $D1 and $F3 +constants so that the colour RAM is copied before the screen RAM in each +loop, instead of after it. + +It is telling that this routine was the result of independent implementation +of this routine, without looking at the KERNALs routine, in terms of supporting +the argument that the routine is the obvious manner in which to do this. + diff --git a/strings/D007A980 b/strings/D007A980 new file mode 100644 index 00000000..01f39c25 --- /dev/null +++ b/strings/D007A980 @@ -0,0 +1,4 @@ +Branch over LDA #$80 and some more + +Branching is extremely common, as is loading the accumulator +with any specific value. Nothing creative or copyrightable here. diff --git a/strings/DE3F815F b/strings/DE3F815F new file mode 100644 index 00000000..6b6aa28d --- /dev/null +++ b/strings/DE3F815F @@ -0,0 +1,16 @@ +List of key codes generated when certain key combinations are pressed + +This sequence is a list of which ASCII/PETSCII code should be generated +when certain key combinations are pressed, based on the keyboard matrix +position. That is, it is a sequence in keyboard matrix order, of the +codes that should be generated. Thus it is a list of facts, which cannot +be copyright, according to the long standing precedent under US copyright law: + +https://www.law.cornell.edu/copyright/cases/499_US_340.htm + +Similar decisions exist in other jurisidctions. + +Note also that the matrix order list of keys is a fact of the C64 hardware, +and which has been repeated in many publications, such as Compute's Mapping the 64, +without challenge from the C64 ROM copyright owners, which serves to reinforce the +claim that this sequence of bytes is not copyrightable.