Is there a way to convert code from one or more 3rd party programming languages used for programming the NXT into a program that can be loaded up in NXT-G? If not, do any text-based languages provide support for making custom blocks that can be imported into NXT-G?
-
possible duplicate of Is there any other way to program the Lego Mindstorms NXT other than the provided software?– Nick2253Commented Sep 22, 2014 at 22:17
-
3I disagree. This question is about converting source files from other programming languages into a format readable by NXT-G, not asking what programs exist as an alternative to it.– HaydenStudiosCommented Sep 23, 2014 at 0:50
1 Answer
No, there is no automated way to convert source files from other programming languages into un-compiled NXT-G code. The .rbt format is very complex, so writing a program to interpret programs written in other languages and generate a proper .rbt file with properly placed and configured blocks would be an incredibly time-consuming and tedious task that wouldn't be worth the effort. You'd be better off manually translating each program manually.
As for your second question, it is possible to make custom blocks for NXT-G, although not in any text-based languages. Custom blocks are made in LabView, a graphical programming language that has a wide variety of uses, including programming NXT robots. See this tutorial on creating custom NXT-G blocks if you're interested:
ftp://ftp.ni.com/evaluation/mindstorms/NXT_Creating_MINDSTORMS_Blocks.pdf