Jump to content


Rookie Mindstorms question


  • Please log in to reply
10 replies to this topic

#1 CopMike

CopMike

  • Making L look good


    Posts: 5734
    Joined: 04-January 05
    Member: 148
    Country: Sweden

Posted 11 April 2012 - 10:01 AM

Hi all!

I´m really really new to this so I will show my ignorance here in public :cry_happy:! I need to have my NXT to perform these easy tasks:
* Have a Power Functions motor to turn a number of 360´s - stop for a while - and then turn back to starting position.
* Work as a switch for getting light-emitting diodes turned on/off - two different set of LED´s at different times.
How do I go about it?

Thanks in advance / Mindstorms Rookie Copmike

Posted Image

New Member? Read This | Questions? Need Help? Ask Here

Site Guidelines | Eurobricks FAQ | Visual User Guide


#2 JopieK

JopieK

  • Kneecap Buster


    Posts: 2702
    Joined: 04-January 07
    Member: 1180
    Country: Netherlands

Posted 11 April 2012 - 01:20 PM

Arduino might be easier and cheaper, but.

Using some convertor cables you could attach PF to NXT. A PF motor is not a servo, so you need to compute what 360 degrees is.

For the LEDs: http://www.tau.ac.il.../lego/i2c-8574/

New Member? Read This | Questions? Need Help?Ask Here
Site Guidelines | Eurobricks FAQ | Visual User Guide


Posted Image

-== Classic LEGO trains are the best ==-

Do you need replacement stickers for LEGO (reproductions and customs): ministickers.nl

What then about the LEGuanO?!


#3 DLuders

DLuders

  • Technic Technician


    Posts: 5817
    Joined: 17-October 09
    Member: 7868
    Country: USA (WA State)

Posted 11 April 2012 - 02:09 PM

@ CopMike:  Have you seen Artifex Creations' Brick Lights?

P.S.  Thanks for donating all of the wonderful Unimog parts for the TSATS contest winners!   :classic:

#4 Blakbird

Blakbird

  • Technic Angel of Retribution


    Posts: 3746
    Joined: 09-November 07
    Member: 2164
    Country: USA

Posted 11 April 2012 - 05:25 PM

View PostCopMike, on 11 April 2012 - 10:01 AM, said:

I´m really really new to this so I will show my ignorance here in public :cry_happy:! I need to have my NXT to perform these easy tasks:
* Have a Power Functions motor to turn a number of 360´s - stop for a while - and then turn back to starting position.
* Work as a switch for getting light-emitting diodes turned on/off - two different set of LED´s at different times.
How do I go about it?

Power functions motors don't have any position feedback, so there is no way to know for sure how many times they have turned. You'd have to program the NXT to just run for a certain number of seconds, but no matter how careful you are it would off after a few cycles and would not return to starting position. With a NXT motor you can command a specific number of degrees of rotation so what you are suggesting would be easy.

As long as you can convert the LEDs to plug into a NXT connector through a converter cable, turning them on and off at whatever time you like should be pretty easy. You could probably just program them as motors and tell them to go to 100%.
Blakbird
Technicopedia

#5 CopMike

CopMike

  • Making L look good


    Posts: 5734
    Joined: 04-January 05
    Member: 148
    Country: Sweden

Posted 11 April 2012 - 08:13 PM

Thanks for the input guys - I really appriciate it :thumbup:! Now I just need to understand it also :laugh:!

* Which NXT motor should I get instead of the PF one?
This one- Posted Image 53787
or this one Posted Image 9842

* I´ll need to read through your supplied link again (and again) JopieK to get it, but I also wonder what I need to program it. So far I only have a black NXT :cry_sad:!

Again I apoligize for the rookie questions!

Posted Image

New Member? Read This | Questions? Need Help? Ask Here

Site Guidelines | Eurobricks FAQ | Visual User Guide


#6 legolijntje

legolijntje

    Posts: 2584
    Joined: 06-June 10
    Member: 11214
    Country: The Netherlands

Posted 11 April 2012 - 08:19 PM

I would go for the 53787, because that are the most recent ones from the nxt 2.0 set.

Edited by legolijntje, 11 April 2012 - 08:19 PM.


#7 DLuders

DLuders

  • Technic Technician


    Posts: 5817
    Joined: 17-October 09
    Member: 7868
    Country: USA (WA State)

Posted 12 April 2012 - 12:10 AM

9842@ CopMike:  There is no difference between the two NXT motors you found, just as there is no difference between these Power Functions motors:

58121c01 and 8882 are both "Power Functions XL Motors".  Bricklink lists both numbers, although Shop.Lego.com only lists the 8882.

Posted Image

58120c01 and 8883 are both "Power Functions M-Motors".  Bricklink lists both numbers, although Shop.Lego.com only lists the 8883.

Posted Image

You can get the 53787 "Electric, Motor - NXT" or the  9842 "Interactive Servo Motor" -- they're the same!   :classic:   Shop.Lego.com sells the 9842.

Posted Image    Posted Image   :laugh:

Edited by DLuders, 12 April 2012 - 12:10 AM.


#8 Blakbird

Blakbird

  • Technic Angel of Retribution


    Posts: 3746
    Joined: 09-November 07
    Member: 2164
    Country: USA

Posted 12 April 2012 - 12:34 AM

View PostCopMike, on 11 April 2012 - 08:13 PM, said:

* Which NXT motor should I get instead of the PF one?
This one- Posted Image 53787
or this one Posted Image 9842
The motors are the same so just get whichever is easier for you to find. They will have a wire that plugs directly into the NXT and is capable of tracking number of revolutions.

Quote

* I´ll need to read through your supplied link again (and again) JopieK to get it, but I also wonder what I need to program it. So far I only have a black NXT :cry_sad:!
The color of the NXT doesn't matter either. They are both the same, just a different color. In fact, the black is much more rare and collectible!

To program it you need the NXT Software with comes with the NXT. If you don't have the software, you'll have to buy it on Bricklink or try to get a replacement from LEGO customer service..

To connect your lights you will need this adapter cable.

I am by no means a NXT expert. In fact, I only bought the NXT, built the first model, and then sold it. Even so, I'm pretty sure I know how to program what you are trying to do. My point here is that the language is really easy and all you need to do is follow the instructions for one or more of the sample models and you'll know what to do.
Blakbird
Technicopedia

#9 DLuders

DLuders

  • Technic Technician


    Posts: 5817
    Joined: 17-October 09
    Member: 7868
    Country: USA (WA State)

Posted 12 April 2012 - 01:20 AM

@ CopMike:  If you don't have the Lego Mindstorms NXT software, you can download the Lego CD-ROM images on this Brickfactory webpage.  The zip files will have the same files as the original CD-ROMs.   :classic:

Posted Image  Posted Image

Edited by DLuders, 12 April 2012 - 01:22 AM.


#10 Steamrunner

Steamrunner

    Posts: 8
    Joined: 09-January 11
    Member: 15300

Posted 12 April 2012 - 01:41 PM

Probably safest to download the software direct from Lego themeselves: http://service.lego....questionID=2655

This is also the best way if you're a Mac user; the disc that came with the NXT 2 doesn't install on Lion, but the version you can download from the Lego site does.

#11 CopMike

CopMike

  • Making L look good


    Posts: 5734
    Joined: 04-January 05
    Member: 148
    Country: Sweden

Posted 13 April 2012 - 09:01 PM

Thanks everyone for the useful information :wub:! Motors and stuff ordered, and program downloaded.
I´ll be back with updates (and maybe for sure more stupid questions) :laugh:!

Posted Image

New Member? Read This | Questions? Need Help? Ask Here

Site Guidelines | Eurobricks FAQ | Visual User Guide





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users