Jump to content
THIS IS THE TEST SITE OF EUROBRICKS!
THIS IS THE TEST SITE OF EUROBRICKS!

Featured Replies

Posted

Hey all

I have a quick question about the mindstorm sensors.

I would like to incorporate the colour sensors into my elevator to use as a reference so the lift knows where to stop.. I will put one sensor in the lift and a light or colour at each floor, I would like to know if I can use the mindstorm sensors directly with the power function motors or if id have to build something separate to turn the PF motors on off etc.

I would also like to use this sensor in a similar way to open the powered door operator on the lift for 10 seconds or so, Its taken me a long time to get these power function motors to fit and work properly so I dont want to swap them out for the mindstorm motors.

Any advice/help would be really appreciated, I'm considering buying the ev3 set but dont want to unless im certain it can help.

a video if you want know what im talking about

thanks all

trav

You need more than just a cable to use the color sensor, it will not work on its own. The sensor is plugged into the input side of the Mindstorms Programmable Brick and the motor(s) are plugged into the output side. Power Functions motors can be used, but it's much easier to use the EV3 motors. The motors have encoders, so the elevator can be programmed to stop at certain floors or even detect the end of travel. The color sensor can be used to detect the "floor" as well.

My dad used to work for konecranes, he said your lift is far smoother than the real thing. :D

Great MOC!

You can use the PF motors with the EV3 (I've been using the 8528 cable adapter + PF extension cable solution suggested by KamalMYafi).

The EV3 can control 4 independent motors, so if you are using one PF motor to move the cabin and another PF motor to slide the door you need 2x8258 cable adapter and 2x PF extension cables.

If you also want to control PF lights you can do the same but for that configuration (3 floors) you will lack 1 EV3 output so it's better to use some kind of mechanical switch at each floor to control the lights instead of using the EV3.

For the sensors you may also use touch sensors instead of the color sensors (costs ~ half), just need a more complex program to understand in what floor the elevator cabin is (and maybe forcing the cabin to go to the first floor at start-up).

  • Author

Awesome!

Thanks for the info, I will look into the cables, im not changing the motors because they fit too well and it has literally taken me months to get it to where it is.. I want to build it so once I have a concept I can keep building upwards, I don't want to be limited by having too many sensors, and I want to keep the amount of cables going into the motor room to a minimum , I'm looking for a simple solution to get it semi automatic, there has to be one! lol

I was thinking a PF light on each floor which i could turn on and off via control panel, (not fussed if i need several receivers, for that part) which in turn tells the colour sensor inside the lift where to stop, open doors etc. Kind of like a real lift.

I'm also waiting on a few SBricks, not sure if anyone has experience with these? I was hoping to use these to program a few simple tasks.

But just on the mindstorms ev3 part, I do want to buy this set, and I'm hoping that i can use the programmable brick to control the PF motors, with one of these cables mentioned, will they cooperate properly just as the ev3 motors?

Thanks all for your time and responses! really do appreciate it:D

Trav

Your proposed solution makes very little financial sense. The programming brick is $190, plus $60 for 4 cables, plus $40 for color sensor, for a total of $290. Unless saving a few dollars is really crucial, I would suggest getting the full EV3 kit for $350. It comes with additional sensors, all the cables that you need, three servo motors and a whole bunch of Technic elements.

The Mindstorms kits is quite different from Power Functions. You program the motors to move a specific amount and they do it. There is no need for manual control. You can determine how many rotations it takes to move the elevator between floors and simply hard-code it into the program, instead of using a color sensor to check for floors. The program can begin by bringing the elevator to the end of its travel to find the start position. This can be accomplished with a touch, color or proximity sensors, but you can also skip the sensors all together if your system has a hard stop and find at which point your motor stops turning (measure rotation over a certain time, and if it's lower than X, that's the end of your travel).

As far as I know, SBrick doesn't have apps that are programmable (ex: move motor for 3 seconds then stop). You may also want to look at WeDo, it uses Power Function motors and is programmable through a computer. Mindstorms may be overkill for your application.

  • Author

ok, not sure I explained myself properly but I was intending on buying the ev3 set... not individual items.

I was hoping to use the programmable brick to tell my PF motors what to do, and it will need a sensor of some kind on the lift with some kind of colour brick in the lift shaft which will be a set stopping point, because if there is an interruption to the travel ie a minifig gets stuck or the doors get jammed etc the lift will get lost, we use magnets in a real elevator and a sensor on the lift so it cant get lost.

I dont want it to rely on hitting something to stop because that would limit how many floors I can build, and also I want to have some over travel like a real lift :tongue:

Everything has to use a sensor, I'm pretty sure I could use 2 sensors, one for the doors and one for the lift.

I will have a look into WeDo, thanks for the advice!

I believe there are 3 switches per floor in a lift, 2 of which are above and below the stop point, these are used to slow the motor and then the one in the middle to stop it.

If the ev3 motors are stepper motors then the control brick will know exactly where to stop for each floor and you also might be able to add a slowdown just before stopping for a nice smooth ride.

I believe there are 3 switches per floor in a lift, 2 of which are above and below the stop point, these are used to slow the motor and then the one in the middle to stop it.

If the ev3 motors are stepper motors then the control brick will know exactly where to stop for each floor and you also might be able to add a slowdown just before stopping for a nice smooth ride.

The EV3 motors are more like servo motors - normal motors with tachometer inside. But unlike servo motors, there isn't a closed control circuit, that's up to the EV3.

So you can use the motors as normal motors, running continuously, but also as servo motors AND as stepper motors.

But as legolifty said, you cannot trust only in the steps/rotations you ordered the motors, there is always something sliping/skewing so sensors are essential in the long run if you don't have/want some kind of periodic recalibration.

Of course Mindstorms EV3 isn't the only option. You can do the same with WeDO (first generation works with PF motors) and a computer. But EV3 is more powerful so if you were already considering buying one

and money isn't a problem [and for the size of that MOC I would say it isn't] go for it!

Edited by MajorAlvega

  • Author

The EV3 motors are more like servo motors - normal motors with tachometer inside. But unlike servo motors, there isn't a closed control circuit, that's up to the EV3.

So you can use the motors as normal motors, running continuously, but also as servo motors AND as stepper motors.

But as legolifty said, you cannot trust only in the steps/rotations you ordered the motors, there is always something sliping/skewing so sensors are essential in the long run if you don't have/want some kind of periodic recalibration.

Of course Mindstorms EV3 isn't the only option. You can do the same with WeDO (first generation works with PF motors) and a computer. But EV3 is more powerful so if you were already considering buying one

and money isn't a problem [and for the size of that MOC I would say it isn't] go for it!

Ok thanks, I think I am pretty set on the ev3 set and by the looks of it I can make or buy cables to use to control the PF motors.. The WeDo looks good but I secretly want to play with mindstorm robot for a while before I use the stuff for my lift lol

Thank you everyone for your advice and help it has given me a lot to think about!

A couple of things to point out for your benefit dude -

If you use an SBrick and bluetooth you can completely conceal the receiver and operate from a longer distance -

It would be difficult but not impossible to devolep a gearing system to stop at floors without the use of NXT

and the same goes for opening the doors It could be done Both of these would take some work to get working smoothly but I have a rough idea and It would save you a few bucks ,Oh and lastly the roof bit looks epic mate ! , tonnes of detail

Sincerely -

-Collin

  • Author

A couple of things to point out for your benefit dude -

If you use an SBrick and bluetooth you can completely conceal the receiver and operate from a longer distance -

It would be difficult but not impossible to devolep a gearing system to stop at floors without the use of NXT

and the same goes for opening the doors It could be done Both of these would take some work to get working smoothly but I have a rough idea and It would save you a few bucks ,Oh and lastly the roof bit looks epic mate ! , tonnes of detail

Sincerely -

-Collin

Thankyou!

Id love to hear what your ideas are I dont want to redesign the lift too much if possible, every time I change the design of the lift car I have to redesign the entire lift shaft.. pretty sick of that now lol, but if I can save myself a few bucks that would be great, I bought the Sbrick so I could get rid of the receiver on the lift because when theres an extra leaf of bricks around the lift shaft the remote controller doesn't work to well.. I was kind of hoping I could get some kind of app to help automate the sbrick but from what everyone says its pretty limited, but I'll see when I get it I spose!

Thanks collin, I'm loving the advice everyone has to offer!

«I was kind of hoping I could get some kind of app to help automate the sbrick but from what everyone says its pretty limited, but I'll see when I get it»

SBrick has only outputs for motors (it has also an internal temperature sensure and a voltage meter, useless for this purpose). Most people are using the Vengit native apps (Android, Windows Phone and iOS) but Vengit release information that allows everyone to make their own programm to control it.

Unfortunately they didn't release an API so you have to do it all by yourself.

I am using python scripts in Linux to control the SBrick. Since EV3 can run linux (ev3dev project) I've used a Raspberry Pi, a laptop and an EV3. I saw recently someone also using my code with a Raspberry Pi, at the Eurobricks trains forum.

And there is someone at the Technic/Mindstorms forum doing an Android App that allows using a bluetooth gamepad with the Android to control the SBrick.

So there's hope for using the SBrick.

Thankyou!

Id love to hear what your ideas are I dont want to redesign the lift too much if possible, every time I change the design of the lift car I have to redesign the entire lift shaft.. pretty sick of that now lol, but if I can save myself a few bucks that would be great, I bought the Sbrick so I could get rid of the receiver on the lift because when theres an extra leaf of bricks around the lift shaft the remote controller doesn't work to well.. I was kind of hoping I could get some kind of app to help automate the sbrick but from what everyone says its pretty limited, but I'll see when I get it I spose!

Thanks collin, I'm loving the advice everyone has to offer!

you seem to know what your doing but on sifting through my old electronics I found all the old electric touch and such sensors perhaps these could be off use I would need someone better processioned in that area to confirm though

  • Author

you seem to know what your doing but on sifting through my old electronics I found all the old electric touch and such sensors perhaps these could be off use I would need someone better processioned in that area to confirm though

I didnt know Lego had any other sensors besides the Mindstorm stuff, do you know the part number? Thanks

What about 2 way switching like you have on the top and bottom your stairs, either light can be switched on or off from the top or bottom.

So you have a standard lego switch one each floor once the lift knocks it off and stops dead on each floor, but the external switch set to the opposite pole starts it up again.

Hi Trav (legolifty),

the perhaps easiest and least complicated way to integrate "computer" control to your elevator is to get an NXT -Set (or EV3, but NXT is cheaper *) and IR Link from HiTechnic: https://www.hitechnic.com/products

[* Note: EV4 Color Sensor can identify 7 colors, NXT color Sensor "only" 6. If you want to build higher than 6/7 stories, you perhaps will have to use two sensors ... allowing than for 36 [NXT] or 49 [EV3] stories, which either is more than plenty I would assume. So EV3 would only dead fit if you have planned your build for 7 stories :-) ]

The IR Link will allow you to control you PF-motors via the IR-Receiver - and it really works (for me) like a charm! I believe that you have already build in the IR receiver for your manual control - so you would have to change absolutely nothing on the PF side for the NXT/EV3 integration. [One word of advice: Check with HiTechnic if they support the EV3 with IR Link if you consider buying an EV3. I only have experience with connection it to NXT.]

As you can set either of the four IR channels and then control A and B ports separately, you can control up to 8 motors with one HiTechnic IR Link Sensor. But I guess you only need to control a single channel with two PF motors for this MOC anyway ?

So for your Elevator MOC you would have to integrate the Color Sensor(s) with (e.g. "on top") of the cabin.

The sensor will be able to detect color of bricks (using its own light source) so you would just have to color code each story

I would actually use two colors for each level: on color that when detected reduces elevator speed, and the other color to "level" the cabin. So e.g. using blue and red: 5 plate thick "blue/"prepare"; 2 plate thick "red/stop" and then another 5 plate thick "blue/prepare" again [Allowing for up and down operation!] - still this "reduces" your build to 3 stories (or you use two color sensors, see above).

As it had been stated before, you need to connect the Color Sensor to the NXT / EV3 brickl but I believe you have already cables going to the cabin, so that should then not be a real challenge to implement. In case that the 50cm/18".5 one provided with NXT/EV3 is too short, HITechnic provides a set that does include a 70 and 90cm (27.6/35.4") cable for (in my view) a reasonable price.

All "timing" and control will then have to be implemented in the NXT/EV3 program. Especially how much to decrease up/down speed to really hit the stop marker in the correct position will be try and error.

A "better" positioning solution could be to use "touch sensor(s)" instead of "color sensor". If you use two touch sensors (on the cabin) and two sets of wall "markers" you could also use one for "prepare stop" (decrease elevator speed) and the other one for precise leveling of the hold. However you would not know, what level you elevator is - so you might require an initialize lift to an defined end position that is "marked" by both sensors "pressed".

You could also use the "color" Sensor to detect "prepare stop" (reduce speed) AND to identify the level that you are in and additionally the touch sensor to detect the correct holding position in each level. That is perhaps the most flexible and technically enhanced solution available. Especially as you would only require a single color per story, thus allowing for 6/7 stories with a single sensor.

Finally instead of adding anything to the cabin, you could also use touch sensors in the shaft to detect the position and control for a "perfect" stop. However this will limit you to 3 stories (or you would need to buy Touch Sensor Multiplexer), as you can only connect 4 sensors to one NXT/EV3 - and one sensor would already be the HiTechnic IR Link one.

The only "missing" item that I do not immediately have an idea for is: how to implement the "call" button in each level to get the elevator move there ...

But then you do not have any buttons in the cabin to select the destination anyway - so I guess we could stick to "HOG" control to where the elevator is moving to :-) - And that for, one could use the NXT/EV3 Motors - as input sensors for what Level to go to! Or just "up / down / stop (next level).

I am happy to support you with programming EV3 and/or NXT if you need any help here.

Kind regards,

Enno.

Edited by E2nO

I didnt know Lego had any other sensors besides the Mindstorm stuff, do you know the part number? Thanks

The perhaps most useful one to you would be part 879 electric sensor ( Touch sensor ) I think it is RCX or something I dunno much about these ones :)

  • Author

hi Enno, thanks for such a detailed reply! I wasn't aware of the IR link and it looks like such a good solution.

Also I really like the two colour brick idea, I'm sure 6/7 stories would be enough realistically but I was thinking I could use the sensor to detect a light source, which I could turn on and off somehow, then I could just have an up and down button on my phone via the Sbrick, I really like the idea of having two bricks, could I use a light in a similar way? I was under the impression that these sensors could read light, and yea the call button is in the too hard basket atm I've racked my brain trying to come up with a solution but without adding sensors or technical mechanical setups I have nothing :(

Thanks again for the advice, it will be a while before I buy the ev3 set I have a few things to try before I spend the $500 on a few bricks.. lol I might give the technic sensor a go first there may be a cheap simple solution, thats what I love about Lego there is endless solutions to a problem you just have to put in the time and effort to make it work :laugh:

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

Recently Browsing 0

  • No registered users viewing this page.
Sponsored Links