• Poking in a command then running it properly?

    From Geo@3:770/3 to All on Fri Jul 7 10:55:26 2017
    60 poke631,78:poke632,197:poke633,13:pok
    e198,3


    The problem is that this doesn't execute the NEXT command. What am I doing wrong. TIA

    --- SoupGate-Win32 v1.05
    * Origin: Agency HUB, Dunedin - New Zealand | Fido<>Usenet Gateway (3:770/3)
  • From Andreas Kohlbach@3:770/3 to Geo on Fri Jul 7 16:52:56 2017
    On Fri, 7 Jul 2017 10:55:27 -0700 (PDT), Geo wrote:

    60 poke631,78:poke632,197:poke633,13:pok
    e198,3


    The problem is that this doesn't execute the NEXT command. What am I doing
    wrong. TIA

    What is 631? Google says "Secondary addresses assigned to files", which
    isn't helpful for me.

    Is this time critical? Like for the interrupt vectors my POKEs often
    crashed the computer. Because after poking the first value (high byte),
    the C64 might already have checked the addresses of the interrupt vector
    again and branched, before the slow BASIC poked the low byte to this
    interrupt vector. Thus likely jumping to an area in memory filled with
    garbage.
    --
    Andreas
    You know you are a redneck if
    you roll you hair with soup cans and wash it once a week.

    --- SoupGate-Win32 v1.05
    * Origin: Agency HUB, Dunedin - New Zealand | Fido<>Usenet Gateway (3:770/3)
  • From Geo@3:770/3 to All on Fri Jul 7 14:37:50 2017
    Memory 631-640 is the keyboard buffer. I am setting characters in the buffer. The idea that it will run itself when it comes to tant line.

    --- SoupGate-Win32 v1.05
    * Origin: Agency HUB, Dunedin - New Zealand | Fido<>Usenet Gateway (3:770/3)
  • From Robert Wolfe@3:770/3 to All on Sat Jul 8 03:02:46 2017
    Subject: Poking in a command then running it properly?
    From: Geo <ghandle75.x@gmail.com>


    60 poke631,78:poke632,197:poke633,13:pok
    e198,3


    The problem is that this doesn't execute the NEXT command. What am I
    doing wron g. TIA

    Maybe you should try a SYS 631 command after line 60 to actually CALL
    the ML code you POKEd into locations 631-633.

    --- SoupGate-Win32 v1.05
    * Origin: Agency HUB, Dunedin - New Zealand | Fido<>Usenet Gateway (3:770/3)
  • From Somebody@3:770/3 to All on Sat Jul 8 08:50:42 2017
    Il 08/07/2017 05:02, Robert Wolfe ha scritto:


    Maybe you should try a SYS 631 command after line 60 to actually CALL
    the ML code you POKEd into locations 631-633.


    What Geo POKEd was not ML code, it was the PETSCII codes for nE<RETURN>
    (nE is the abbreviation of NEXT). So a SYS won't do anything useful.

    I typed the one-line BASIC program Geo posted and it did exactly what it
    was supposed to do.

    **** commodore 64 basic v2 ****

    64k ram system 38911 basic bytes free

    ready.
    60poke631,78:poke632,197:poke633,13:poke
    198,3
    run

    ready.
    nE

    ?next without for error
    ready.

    That is, the BASIC program was typed and run, and it entered nE<RETURN>
    in the keyboard buffer. After the BASIC program exited, the keyboard
    buffer was emptied, automatically typing nE<RETURN>. Therefore the BASIC command nE was executed, and it returned what was expected in that
    context (an error, no FOR command had been executed in that context).

    So, it works as it should, no matter what Geo expected. What did Geo
    expect, then?

    --- SoupGate-Win32 v1.05
    * Origin: Agency HUB, Dunedin - New Zealand | Fido<>Usenet Gateway (3:770/3)
  • From Janne Johansson@2:221/6 to Somebody on Sat Jul 8 12:50:10 2017
    On 2017-07-08 07:50, Somebody : All wrote:
    Il 08/07/2017 05:02, Robert Wolfe ha scritto:

    So, it works as it should, no matter what Geo expected. What did Geo
    expect, then?
    This can be used for selfmodiffying basic code, you print out the BASIC
    lines you want to add, use the above poke trick to do a few newlines to
    get them in, then "RUN" <carriage return> to restart the program.

    ---
    * Origin: *** nntp://fidonews.mine.nu *** Finland *** (2:221/6.0)