To LUGNET HomepageTo LUGNET News HomepageTo LUGNET Guide Homepage
 Help on Searching
 
Post new message to lugnet.loc.itOpen lugnet.loc.it in your NNTP NewsreaderTo LUGNET News Traffic PageSign In (Members)
 Local / Italia / 1006
1005  |  1007
Subject: 
Re: Regolamento.
Newsgroups: 
lugnet.loc.it
Date: 
Tue, 18 Jan 2000 12:00:48 GMT
Viewed: 
397 times
  
"Mario Ferrari" <mario.ferrari@edis.it> wrote in message
news:FoIxCy.vE@lugnet.com...
// Dragster
// ========

task main()
{
  // configura sensore di luce su porta 1
  SetSensor(SENSOR_1,SENSOR_LIGHT);

  // dimensiona datalog
  CreateDatalog(5);

  // attende di essere posizionato sulla linea di partenza
  while (SENSOR_1<SOGLIA);


Credo sia necessario inserire qui il codice per impedire che il dragster
possa essere spinto *oltre* la linea.
Era questo che intendevo con "braccia lunghe".........


  // sulla linea, pronti al via tra 5 secondi
  Wait(100); PlayTone(440,5);
  Wait(100); PlayTone(440,5);
  Wait(100); PlayTone(440,5);
  Wait(100); PlayTone(440,5);
  Wait(100); PlayTone(880,5);


// via!! corre e vince (il mio) ;-)

  StartTimer();
  OnFwd(OUT_A+OUT_B+OUT_C);

--
Cheers
Carlo.
LUGNET member page:  http://www.lugnet.com/people/members/?m=24
Proud member of ItLUG: http://www.itlug.org/



Message has 1 Reply:
  Re: Regolamento.
 
(...) Probabilmente basta inserire un'ultimo test prima della partenza, che viene annullata se il dragster non è più sulla linea bianca: // test se posizione di partenza corretta if (SENSOR_1<SOGLIA) { // partenza annullata PlayTone(220,1); (...) (24 years ago, 18-Jan-00, to lugnet.loc.it)

Message is in Reply To:
  Re: Regolamento.
 
Carlo Ottolina <kruntz@tiscalinet.it> wrote in message: (...) A me non dispiace l'idea della partenza automatica, non credo che le braccia possano influire :-) Il codice potrebbe essere una cosa di questo genere (incluso il cronometro di Antonio): (...) (24 years ago, 18-Jan-00, to lugnet.loc.it)

19 Messages in This Thread:







Entire Thread on One Page:
Nested:  All | Brief | Compact | Dots
Linear:  All | Brief | Compact

This Message and its Replies on One Page:
Nested:  All | Brief | Compact | Dots
Linear:  All | Brief | Compact
    

Custom Search

©2005 LUGNET. All rights reserved. - hosted by steinbruch.info GbR