Page 3 of 7

Re: NXT PROBLEM

Posted: 20 Jun 2013, 16:03
by naneczek
So far I've got sth like this:

Code: Select all

task main() {
ClearScreen();
int y;
int i;
int MyArray[100];
SetSensorLowspeed(IN_4);

for (i=0;i<=100;i++) {
y= SensorUS(IN_4);
MyArray[i]=y

NumOut(0, 56, y, DRAW_OPT_CLEAR);

}
for (i=0;i<=100;++i) {
y=MyArray[i];
if (i==99) ClearScreen();

PointOut(i, y/4, DRAW_OPT_NORMAL);

}

while (true);
}
How come you don't know what I mean:)? I just want an oscyloscope which will show measurements on the display (in whole lines through the display, not pixel by pixel as you did it in the very irst code):) So one measurement means one whole line on the display, second measurement means the previous line of measurements is deleted and the new whole one is displayed and so on. Help mi with the code. The thing is that I don't have LegoRobot to work on:( only twice a week I have a possiblity to work on it:/

Re: NXT PROBLEM

Posted: 20 Jun 2013, 16:28
by HaWe
it's a matter of how to learn programming.
If you don't try it by yourself you won't learn it ever.
So I'll gladly help you learning but it makes no sense to write the whole code for you. ;)

(But maybe anyone else is willing to...)^^

Re: NXT PROBLEM

Posted: 20 Jun 2013, 16:32
by naneczek
So please help me with writing it and explaining why is it so in this oscyloscope. That would be the best solution. I just ask you for help. In the first one you did really great job because you wrote the code, explain what is what and I understood almost everything...Now you aren't as willing to help as before...So what would you change in the code I wrote.

Re: NXT PROBLEM

Posted: 20 Jun 2013, 16:58
by HaWe
first try it and see what happens - and then report :)

Re: NXT PROBLEM

Posted: 20 Jun 2013, 19:06
by naneczek
I hope you read my posts and you didn't miss the part in which I wrote " I don't have LegoRobot" so that I cannot test it...

Re: NXT PROBLEM

Posted: 20 Jun 2013, 19:13
by HaWe
then you will have to wait until you'll have one ;)
BTW: what do you need this whole stuff for?

Re: NXT PROBLEM

Posted: 20 Jun 2013, 19:22
by naneczek
The question is, Will you help me with this stuff or you won't?

Re: NXT PROBLEM

Posted: 20 Jun 2013, 20:20
by HaWe
no, the question was: what do you need this whole stuff for?

Re: NXT PROBLEM

Posted: 20 Jun 2013, 20:26
by naneczek
Because we are doing projects at school. So will you help me or not?

Re: NXT PROBLEM

Posted: 20 Jun 2013, 21:12
by HaWe
well, I already suspected it was kind of schoolwork.
I am not allowed to do your schoolwork for you, you have to do your schoolwork by your own.
But I can help for detailed questions about narrowly defined issues.