Legacy Forum: Preserving Nearly 20 Years of Community History - A Time Capsule of Discussions, Memories, and Shared Experiences.

can't clear RN memory?

Hitec robotics including ROBONOVA humanoid, HSR-8498HB servos, MR C-3024 Controllers and RoboBasic
2 postsPage 1 of 1
2 postsPage 1 of 1

can't clear RN memory?

Post by robokoi » Fri Nov 24, 2006 11:24 pm

Post by robokoi
Fri Nov 24, 2006 11:24 pm

I found and ran the code from the 3rd post in this thread:
http://robosavvy.com/modules.php?name=F ... odify+walk

Now I can't seem to get anything else loaded or if I do, it will always revert back to the code from above after returning to 'main'!!! HELP!

I've tried clearing the RN memory thru robobasic. I'm testing code, the main stub looks like the following and I'm only adding a sub 'new_function':
ZERO G6A,101, 103, 100, 103, 101
ZERO G6B, 99, 101, 101
ZERO G6C, 99, 99, 99
ZERO G6D, 97, 102, 104, 103, 101

DIM a AS BYTE

PTP SETON
PTP ALLON

'== motor diretion setting ======================
DIR G6A,1,0,0,1,0,0
DIR G6B,1,1,1,1,1,1
DIR G6C,0,0,0,0,0,0
DIR G6D,0,1,1,0,1,0

'== motor start position read ===================
GETMOTORSET G6A,1,1,1,1,1,0
GETMOTORSET G6B,1,1,1,0,0,0
GETMOTORSET G6C,1,1,1,0,0,0
GETMOTORSET G6D,1,1,1,1,1,0

SPEED 5

'== motor power on =============================
MOTOR G24
GOSUB standard_pose

'================================================
MAIN:

A = REMOCON(1)
IF A <> 1 THEN GOTO main

SPEED 8
GOSUB new_function
DELAY 1000
SPEED 6
GOSUB standard_pose
A = REMOCON(1)

' GOTO MAIN
'================================================



I do not understand the first two lines of the above posted code:
goto auto
fill 255,10000


What can I do?
I found and ran the code from the 3rd post in this thread:
http://robosavvy.com/modules.php?name=F ... odify+walk

Now I can't seem to get anything else loaded or if I do, it will always revert back to the code from above after returning to 'main'!!! HELP!

I've tried clearing the RN memory thru robobasic. I'm testing code, the main stub looks like the following and I'm only adding a sub 'new_function':
ZERO G6A,101, 103, 100, 103, 101
ZERO G6B, 99, 101, 101
ZERO G6C, 99, 99, 99
ZERO G6D, 97, 102, 104, 103, 101

DIM a AS BYTE

PTP SETON
PTP ALLON

'== motor diretion setting ======================
DIR G6A,1,0,0,1,0,0
DIR G6B,1,1,1,1,1,1
DIR G6C,0,0,0,0,0,0
DIR G6D,0,1,1,0,1,0

'== motor start position read ===================
GETMOTORSET G6A,1,1,1,1,1,0
GETMOTORSET G6B,1,1,1,0,0,0
GETMOTORSET G6C,1,1,1,0,0,0
GETMOTORSET G6D,1,1,1,1,1,0

SPEED 5

'== motor power on =============================
MOTOR G24
GOSUB standard_pose

'================================================
MAIN:

A = REMOCON(1)
IF A <> 1 THEN GOTO main

SPEED 8
GOSUB new_function
DELAY 1000
SPEED 6
GOSUB standard_pose
A = REMOCON(1)

' GOTO MAIN
'================================================



I do not understand the first two lines of the above posted code:
goto auto
fill 255,10000


What can I do?
robokoi
Robot Builder
Robot Builder
Posts: 13
Joined: Fri Nov 17, 2006 1:00 am
Location: Boston, MA

Re: can't clear RN memory?

Post by robokoi » Fri Nov 24, 2006 11:33 pm

Post by robokoi
Fri Nov 24, 2006 11:33 pm

What can I do?



RTF... code!

wow, feeling foolish responding to my own post, but I found the error.
There's a line:
' GOTO MAIN

Notice that it's commented out. Apparently, since there was no RETURN or GOTO statement ending this command, the command pointer walked off the stack (or the Basic equivalent). I have no idea where it went!

I wonder why the 'Clear memory' button from RoboBasic doesn't actually zero out the memory?
Is this the first buffer overrun in a RN? :)
What can I do?



RTF... code!

wow, feeling foolish responding to my own post, but I found the error.
There's a line:
' GOTO MAIN

Notice that it's commented out. Apparently, since there was no RETURN or GOTO statement ending this command, the command pointer walked off the stack (or the Basic equivalent). I have no idea where it went!

I wonder why the 'Clear memory' button from RoboBasic doesn't actually zero out the memory?
Is this the first buffer overrun in a RN? :)
robokoi
Robot Builder
Robot Builder
Posts: 13
Joined: Fri Nov 17, 2006 1:00 am
Location: Boston, MA


2 postsPage 1 of 1
2 postsPage 1 of 1