Author Topic: Console question  (Read 4251 times)

Offline AZPaul

  • Bot Builder
  • **
  • Posts: 76
    • View Profile
Console question
« on: March 28, 2005, 02:04:48 PM »
Howdy, y'all,

Question on what I'm look at on the console.

If my understanding is correct the memory block I can see in the console is the one built [you]after[/you] program execution [you]before[/you] the DNA acts on it. Yes?

Much obliged,

-P

Offline PurpleYouko

  • Bot God
  • *****
  • Posts: 2556
    • View Profile
Console question
« Reply #1 on: March 28, 2005, 03:06:57 PM »
Yup

Spot on!

The DNA is parsed at the start of the cycle. This places all of the values into the robot's memory cells.
The console displays them at this point so when the console tells you that eye5 sees 64, that is exactly what the robot sees right now.
The memory values haven't been processed and converted into actions yet.
There are 10 kinds of people in the world
Those who understand binary.
and those who don't

:D PY :D

Offline AZPaul

  • Bot Builder
  • **
  • Posts: 76
    • View Profile
Console question
« Reply #2 on: March 28, 2005, 05:28:16 PM »
Quote
The DNA is parsed at the start of the cycle. This places all of the values into the robot's memory cells.
The console displays them at this point so when the console tells you that eye5 sees 64, that is exactly what the robot sees right now.
The memory values haven't been processed and converted into actions yet.

Now, you see, I read this as just the opposite of what I asked. Headspace and timing on the newbie's part. Let me get verbose so I understand:

Robot DNA manipulates memory block  >>---------------------- cycle start

Robot memory block passed to program for execution            

Program executes then returns memory block to robot   <<---- cycle end
<<------------------------------------------------------------------console view
Robot DNA manipulates memory block

Robot memory block passed to program for execution

Program executes then returns memory block to robot
<<----------------------------------------------------------------- console view
Robot DNA manipulates memory block

Is this correct?

Don't you just love ASCII as a drawing tool?

-P
« Last Edit: March 28, 2005, 05:32:48 PM by AZPaul »

Offline PurpleYouko

  • Bot God
  • *****
  • Posts: 2556
    • View Profile
Console question
« Reply #3 on: March 29, 2005, 09:23:38 AM »
Oh I absolutely love it!

I am not quite with you on terminology here. What precisely do you mean by
Quote
Program executes then returns memory block to robot
?

There is no return to memory after execution. A lot of values (all commands at least) are wiped as soon as they are executed and no values are ever added to memory locations either during or after execution. (one or two exceptions but not as a rule)
This is how it all works.....
(try it this way instead of with ASCII)
  • ALL memory manipulation takes place right at the start when the DNA code is parsed in a sequential order through the genome.
  • eyecells and other senses are updated. (actually happens from the start of the main loop but it makes more sense to show it here)
  • memory values are stored into the console output (stored as a seperate block representing all memory locations at the start of the main cycle) as they are assigned. Nothing has been acted on yet.
  • Now that the memory block has been modified for all actions specifically defined in the DNA (stuff like loading -1 into .shoot), the entire memory block  for all robots is handed over to the main loop.
  • Main loop consists of several steps which are each carried out for all robots before moving on to the next step.
  • These steps consist of. (not necessarily in exactly this order
    • updating tie comunications
    • updating other tie stuff
    • updating shot positions
    • shot collisions
    • updating robot positions
    • collisions
    • console displayed here!
    • Drawing robots
    • drawing shots
    • several others
    [/b]

That is it in a nutshell.
Just remember that nothing happens to the memory block after initial DNA parsing except for updating eye positions, and this still happens before displaying the data in the console.

Basically, if you look at a robot in the console and check its eyes, you get a readback of everything it can see in its present screen position ie. it hasn't moved yet in response to the impulses from the DNA.
Let's say you have a gene that will turn your robot 150 points left (150 .aimsx store) if eye 7 is greater than 15.
You can actually see from the console that eye7 = 28
when you press the button to move it forward one cycle, the robot will be seen to rotate left by a value of 150.

Actually I may have been a little misleading here. It isn't so much that the memory block hasn't been processed yet as that nothing on the screen has actually been updated so it just looks like it hasn't been.
« Last Edit: March 29, 2005, 09:26:08 AM by PurpleYouko »
There are 10 kinds of people in the world
Those who understand binary.
and those who don't

:D PY :D

Offline PurpleYouko

  • Bot God
  • *****
  • Posts: 2556
    • View Profile
Console question
« Reply #4 on: March 29, 2005, 09:27:56 AM »
Well that was weird!  :blink:

That list works perfectly in the post preview yet it comes out weird in the post itself. I have edited it about a dozen times but it still won't accept the sub-list (highlighted in bold)
There are 10 kinds of people in the world
Those who understand binary.
and those who don't

:D PY :D

Offline AZPaul

  • Bot Builder
  • **
  • Posts: 76
    • View Profile
Console question
« Reply #5 on: March 29, 2005, 12:19:43 PM »
Well, let's see.
  • 12
  • 23
  • 34
  • 56
  • 78
Seems to work fine. Am I not the only one with headspace and timing problems?

Shouldn't the [list=a] at the start just be ["list"]?

(Had to put the quotes , or something, in the brackets to keep list from activating.)

Maybe we should try this (write the list then bookend it with the list commands):
    1. I like chocolate pudding.
    2. I like the outter edge of the universe.
    3. Therefore the outter edge of the universe is made of chocolate pudding.[/li]
Now this works right fine. I think maybe it's the list=a thing at the front, PY.
« Last Edit: March 29, 2005, 12:42:49 PM by AZPaul »

Offline PurpleYouko

  • Bot God
  • *****
  • Posts: 2556
    • View Profile
Console question
« Reply #6 on: March 29, 2005, 01:08:03 PM »
What I was doing was to nest two lists inside each other.

The outer list used the "list=1" format and the inner list used the "list=a" format.

On the preview pane it came out just like I wanted with all the highlighted bold stuff listed as a,b,c etc within, and indented from, the numbered list.

On submitting the message it just ignores the inner list and shows the commands like they are written wrong.

Here I will try again
  • item 1
  • item 2
  • item 3
    • item 3a
    • item 3b
    • item 3c
  • item 4

here is the exact code used to make the list
Code: [Select]
[list=1]
[*]item 1
[*]item 2
[*]item 3
[list=a]
[*]item 3a
[*]item 3b
[*]item 3c
[/list]
[*]item 4
[/list]

Works perfectly in the preview pane. let's see how it works on the board.

[edit] I see it screwed up again. That is just weird. I wonder if there is a setting somewhere which is disabling nested lists.
Just copy the code into a new message and click preview to see how it should look.
« Last Edit: March 29, 2005, 01:11:07 PM by PurpleYouko »
There are 10 kinds of people in the world
Those who understand binary.
and those who don't

:D PY :D