Subject:
|
LONG DELAY after pressing RUN button (to end the program)
|
Newsgroups:
|
lugnet.robotics.rcx.legos
|
Date:
|
Sun, 27 Apr 2003 02:07:55 GMT
|
Viewed:
|
3236 times
|
| |
| |
Hi there, I see that I'm the only one who has recently used this newsgroup.
Well thanks to the people who has taken the time to answer my questions,
such as nanobapt.
I have another question now. I've two different kernels, legOS 0.2.6 and
brickOS 0.2.6.10 well, when using brickOS I'm experiencing a big delay after
pressing the RUN button in order to stop the program (the LCD displays
"STOP" for quite a long time). On the other side, when using legOS that does
not happen. The program is quite simple, it's just for testing the lnp
addresing layer.
My question is why is this happening just with brickOS and not with legOS?
Best Regards,
CarlosLuis Rendon M.
#include <conio.h>
#include <unistd.h>
#include <string.h>
#include <lnp.h>
#include <dmotor.h>
#define true 1
#define MY_PORT 2
int go=0;
unsigned char rx[50];
void addressingHandler (const unsigned char *data, unsigned char length,
unsigned char src) {
go = 1;
}
int main()
{
int i;
memset(rx, 0, sizeof(rx));
i = 0;
cputs("rec");
sleep(1);
cls();
lnp_addressing_set_handler(MY_PORT,addressingHandler);
while (true) {
if (go == 1) {
cputs ("hello");
msleep(500);
cls();
go = 0;
}
}
}
|
|
Message has 1 Reply:
3 Messages in This Thread:
- Entire Thread on One Page:
- Nested:
All | Brief | Compact | Dots
Linear:
All | Brief | Compact
|
|
|
|