Lego Nxt Scorpion Programme

Posted : admin On 12.12.2019

Pdf

Programme

ScorpionThis is the code for a Lego Mindstorms NXT 2.0 scorpion. BehaviourThe code is very simple.

Lego Nxt Scorpion Programme

Lego Nxt Scorpion Programmer

Lego

I was only interested in the sting mechanismso this is the only behaviour this program implements (it has nolegs).The UltraSound sensor should be plugged into input 1 and the sting'smotor into output A. At the moment, it assumes that the sting startsin the closed position (I may add a setup step that pulls the sting infirst at some point). ConstructionMy scorpion is based on. I'veditched much of the design, in particular the legs. Unfortunately,these instructions require pieces that don't appear to come in thedefault NXT 2.0 kit.

My kit only contains two 15-length pieces, whichis less than the sting mechanism requires. I got around this byscaling down the size of the sting by replacing 15-length pieces with13, 13 with 11 and so on. UsageYou'll need to build a suitable machine out of the Mindstorms kit. Youcan then connect it to your computer using a USB cable.If you haven't done so already, get set up with the following steps:.Then, with the nbc command set up and on your path, run thefollowing from the scorpion directory. Nbc -d scorpion.nxcThis will compile the program and send it to the connected NXT device.