Not Quite C

Not Quite C

Not Quite C (NQC) is a programming language, application programming interface (API), and native bytecode compiler toolkit for the Lego Mindstorms, Cybermaster and LEGO Spybotics systems. It is based primarily on the C language but has specific limitations, such as the maximum number of subroutines and variables allowed, which differ depending on the version of firmware the RCX has. The language was invented by David Baum. He has released two books on the subject.

Contents

Simple program example

A simple test program written in NQC for an RCX with a motor connected to output port A could look like this:

task main ()    // main program
{
  SetPower(OUT_A, OUT_FULL);    // turn on motor A at 100% power
  OnFor(OUT_A, 200);            // let the motor run for 2 seconds, then turn it off
}

Thus, motor A will go at full speed for two seconds before being turned off.

Tournament legality

NQC is not legal in any tournaments sanctioned by FIRST. A number of teams have complained about this, so far without success.

Compilers and integrated development environments

NQC compilers and integrated development environments (IDEs) are available for many platforms including Microsoft Windows, Mac OS X, Linux, BeOS and DOS. One is the Bricx Command Center.

Compiler sources:

IDE sources:

External links


Wikimedia Foundation. 2010.

Игры ⚽ Поможем решить контрольную работу

Look at other dictionaries:

  • Not Quite Me — Studio album by Tess Wiley Released January 1 …   Wikipedia

  • Not Quite C — Influencé par C Système d exploitation Mindstorms RCX firmware …   Wikipédia en Français

  • Not Quite Hollywood: The Wild, Untold Story of Ozploitation! — Promotional poster Directed by Mark Hartley Produced by …   Wikipedia

  • Not Quite Human II — Written by Seth McEvoy (book series), Kevin Osborn (character), Eric Luke (written by) Directed by Eric Luke Starring Jay Underwood Alan Thicke Robyn Lively …   Wikipedia

  • Not Quite Dead Enough —   …   Wikipedia

  • Not Quite Human (film) — Written by Seth McEvoy (book series) Alan Ormsby Directed by Steven Hilliard Stern Starring Jay Underwood, Alan Thicke, Robyn Lively Country of origin …   Wikipedia

  • Not Quite Paradise — Directed by Lewis Gilbert Produced by Lewis Gilbert William P. Cartlidge Written by Paul Kember Starring …   Wikipedia

  • Not Quite Art — Title logo Genre Documentary Created by Marcus Westbury Presented by …   Wikipedia

  • Not Quite Dead — If this infobox is not supposed to have an image, please add |noimage=yes . Publication information Publisher Fl …   Wikipedia

  • Not Quite the Diplomat — Not Quite the Diplomat: Home Truths About World Affairs   …   Wikipedia

Share the article and excerpts

Direct link
Do a right-click on the link above
and select “Copy Link”