Recent Questions - LEGO® Answersmost recent 30 from bricks.stackexchange.com2015-03-31T22:07:27Zhttp://bricks.stackexchange.com/feedshttp://www.creativecommons.org/licenses/by-sa/3.0/rdfhttp://bricks.stackexchange.com/q/61810Raw RGB data to Color?Timbelionhttp://bricks.stackexchange.com/users/56302015-03-31T20:21:03Z2015-03-31T20:21:03Z
<p>Why my code doesn't work?</p>
<p>It should convert raw RGB to HSL.</p>
<pre><code>R = rgbn[INPUT_RED];
G = rgbn[INPUT_GREEN];
B = rgbn[INPUT_BLUE];
var_R = ( R/255 );
var_G = ( G/255 );
var_B = ( B/255 );
float H = 0;
float S = 0;
float V = 0;
float var_Max = var_R; if (var_G &gt; var_Max) var_Max = var_G; if (var_B &gt; var_Max) var_Max = var_B;
float var_Min = var_R; if (var_G &gt; var_Min) var_Min = var_G; if (var_B &gt; var_Min) var_Min = var_B;
del_Max = var_Max - var_Min;
//***************************************************
//*****************Calculating*H*********************
//***************************************************
if (del_Max == 0) {H=0;}
else if (var_Max = var_R) {H=(60*((var_G-var_B)/del_Max))%6;}
else if (var_Max = var_G) {H=(60*((var_B-var_R)/del_Max))+2;}
else if (var_Max = var_B) {H=(60*((var_R-var_G)/del_Max))+4;}
//***************************************************
//*********************END*H*************************
//***************************************************
//*****************Calculating*S**********************
//***************************************************
if (var_Max == 0) {S=0;}
else if (var_Max != 0) {S=del_Max/var_Max;}
//***************************************************
//*********************END*S*************************
//***************************************************
//*****************Calculating*V**********************
//***************************************************
V=var_Max;
//***************************************************
//*********************END*S*************************
//***************************************************
NumOut(0,LCD_LINE6, H);
NumOut(0,LCD_LINE7, S);
NumOut(0,LCD_LINE8, V);
</code></pre>
<p>And when i convert it to HSL how can I recognize color??</p>
<p>Can someone answer me or fix my code?</p>
<p>Thanks!</p>
<p>:)</p>
http://bricks.stackexchange.com/q/61791Identifying Lego set from 1980'sDelora Severancehttp://bricks.stackexchange.com/users/56322015-03-31T14:59:28Z2015-03-31T15:25:07Z
<p>Can someone please help me identify this Lego set from the 1980's? I remember building a house, work shed/garage and some type of vehicle. The base plate is light gray. It came with 2 mini figures, male and female, a Broom and shovel, and slanted windows that were used for a skylight. Thanks! </p>
http://bricks.stackexchange.com/q/61760Programming NXT color sensor with NXC?Timbelionhttp://bricks.stackexchange.com/users/56302015-03-31T09:41:05Z2015-03-31T13:47:50Z
<p>I am programing Lego Mindstorms NXT 2.0 color sensor in BricxCC.</p>
<p>I already have RGB data with the command <code>ReadSensorColorRaw</code>. I heard that it is easier to get the colour from HSL format. I've tried a lot of algorithms, but none succeeded. How I can fix it to work?'</p>
<p>Also I heard that I need to calibrate white balance. How can I do this?? </p>
http://bricks.stackexchange.com/q/61733Can I share/download a wishlist on Bricklink?Ander Bigurihttp://bricks.stackexchange.com/users/55282015-03-30T09:45:56Z2015-03-30T15:44:06Z
<p>I have a whole set in a wishlist in Bricklink and I would like to share it with some friends.</p>
<p>Can I either: </p>
<ul>
<li>Share the list via Bricklink so they can use it directly.</li>
<li>Download it in XML so they can upload it to their wishlist.</li>
</ul>
<p>If I can do them, how? If I cant, any alternatives? </p>
http://bricks.stackexchange.com/q/61712What's the circle piece in this MOC?Recca Chaohttp://bricks.stackexchange.com/users/39142015-03-30T07:43:54Z2015-03-30T10:30:29Z
<p>I saw a moc from here
<a href="https://www.flickr.com/photos/legocy/16359474006/" rel="nofollow">https://www.flickr.com/photos/legocy/16359474006/</a></p>
<p><img src="http://i.stack.imgur.com/hDKmV.jpg" alt="enter image description here"></p>
<p>But have no idea what the piece it use on the arms of the robot, and on the guns.
Any ideas? Thanks.</p>
<p>edit: Sorry I didn't make it clear first. Edit Picture to make it more clear.</p>
http://bricks.stackexchange.com/q/61630How to switch an NXT sensor port by a motor port?Joana Santoshttp://bricks.stackexchange.com/users/56202015-03-26T15:11:35Z2015-03-26T15:41:16Z
<p>Me and my partner are finishing up our robot for the RobotCup and we desperately need one more motor port. We will only use 3 sensor ports, so my question was if there was even the slight chance that we could switch one for the other.</p>
http://bricks.stackexchange.com/q/61621EV3 motor TACHO signal connection. Hardware schematic questionsTigranhttp://bricks.stackexchange.com/users/56152015-03-26T10:39:30Z2015-03-26T17:30:10Z
<p>I'm trying to understand EV3 motor TACHO signals circuit on the EV3 hardware schematic. </p>
<p>Please look at the image below.
Two things I cant understand.</p>
<ol>
<li><p>On the left side the TACHOA0 input is connected to the ADC and Schmitt trigger inputs via RC circuit. I can understand that the 4.7K resistors and 100pF, 47pF capacitors are used to filter the signal. But I can not understand why the those two 100K resistors are used.</p></li>
<li><p>On the right side TACHOA1 input is connected to the ADC and Schmitt trigger inputs via RC filter. Here I don't understand the role of MA1 signal.</p></li>
</ol>
<p>Thank you very much.</p>
<p><img src="http://i.stack.imgur.com/5KNa0.png" alt="enter image description here"></p>
http://bricks.stackexchange.com/q/61592Remove decals from LEGO Friends mini-dollsrioforcehttp://bricks.stackexchange.com/users/36932015-03-25T21:05:16Z2015-03-25T23:02:59Z
<p>I am trying to remove the decals from my LEGO Friends mini-dolls. Does anyone have any suggestions for doing this? I tried rubbing alchaol on a minifigure once, and it made it all gross looking, so I know that probably won't work.</p>
<p>A rubber eraser is working, but it takes an awful lot of work, and is very difficult to get the sides of the torso done. (And I am dreading the feet and skirt...)</p>
<p>Thanks!</p>
http://bricks.stackexchange.com/q/61563What electrical contact material is used for PF Connectors?Tigranhttp://bricks.stackexchange.com/users/56152015-03-24T12:57:02Z2015-03-25T20:30:16Z
<p><img src="http://i.stack.imgur.com/mX3ey.png" alt="enter image description here"></p>
<p>I'm designing my own PF electrical connector and I want to have the same functional characteristics as the original Lego brick.</p>
<p>Could you please let me know which electrical contact material is used in the original brick?</p>
http://bricks.stackexchange.com/q/61522The most amount of pieces [ever] per set3kstchttp://bricks.stackexchange.com/users/56102015-03-23T21:01:50Z2015-03-24T15:47:50Z
<p>Which set number had the most </p>
<ul>
<li>Standard LEGO elements to date?</li>
<li>Technic LEGO elements to date?</li>
</ul>
http://bricks.stackexchange.com/q/61481Bluetooth Conection PC-NXT1-NXT2FDuartehttp://bricks.stackexchange.com/users/54382015-03-22T12:52:13Z2015-03-24T22:43:09Z
<p>I want to connect, via Bluetooth, one PC with a NXT brick and then have that NXT communicate with another NXT.</p>
<p>So I send a message from the PC to NXT1 and have NXT1 send a message to NXT2.
Is this possible?</p>
http://bricks.stackexchange.com/q/61461Bluetooth communication between computer and nxt using RobotCFDuartehttp://bricks.stackexchange.com/users/54382015-03-21T23:15:47Z2015-03-23T22:31:16Z
<p>I'm thinking starting a project involving controlling the movement of a NXT robot from the PC using RobotC.</p>
<p>Is it possible? Does anyone have a simple code solution?</p>
http://bricks.stackexchange.com/q/61271Issues with set 10234 book 3 pg 43Granthttp://bricks.stackexchange.com/users/55822015-03-12T22:05:12Z2015-03-25T20:45:54Z
<p>The white wing-like piece continues to pop off when placed. Has anyone figured out a fix for this or am I doing something wrong </p>
<p>Instructions 3 &amp; 4: </p>
<p><img src="http://i.stack.imgur.com/IYjO0.jpg" alt="Instruction page from BrickInstructions"><br />
src: <a href="http://lego.brickinstructions.com/10000/10234/163.jpg" rel="nofollow">http://lego.brickinstructions.com/10000/10234/163.jpg</a></p>
http://bricks.stackexchange.com/q/60944Is it possible to use Bluetooth to connect two EV3 bricks using RobotC?FDuartehttp://bricks.stackexchange.com/users/54382015-02-25T00:49:29Z2015-03-23T22:31:04Z
<p>For example to send a numeric value from one to the other?</p>
http://bricks.stackexchange.com/q/60441Can I use EV3 with a TETRIX motor?chrishttp://bricks.stackexchange.com/users/54952015-02-14T08:03:33Z2015-03-25T20:44:41Z
<p>What program can I use to control a TETRIX motor through the LEGO EV3? I've heard that RobotC currently cannot be used for this.</p>
<p>Has NI released a Labview version which I can use to control TETRIX through EV3?</p>
http://bricks.stackexchange.com/q/60091How to turn the NXT at an angle with NXCFDuartehttp://bricks.stackexchange.com/users/54382015-02-03T09:49:16Z2015-03-29T13:32:12Z
<p>How can I program, with NXC, a Lego NXT to turn a specific angle? </p>
<p>I've tried using <code>wait()</code> but the problem isn't solved.</p>
<p>Can I use <code>RotateMotor()</code>? What parameters should I use? For example if I want it to move in a square, what kind of parameters.</p>
http://bricks.stackexchange.com/q/60001I need a block that can combine a movement program with NXTbee radiodayrmoorehttp://bricks.stackexchange.com/users/54572015-01-31T05:19:37Z2015-03-25T20:49:24Z
<p>I am a student. I am working on a science project using Lego Mindstorms robots enhanced with NXTbees creating a mesh network. </p>
<p>My engineering mentor has me using Labview. I am trying to find a block that can combine a movement program (senses a block in the robot path, stops, then change direction) with NXTbee radio. </p>
<p>I want the NXTbee to override the Bluetooth in the Lego Mindstorms program. I have tried a number of avenues seeking help, but they haven't worked out. Can anyone help? </p>
http://bricks.stackexchange.com/q/59890Daisy chaining EV3 with RobotCFDuartehttp://bricks.stackexchange.com/users/54382015-01-26T10:55:59Z2015-03-23T22:30:37Z
<p>I'm trying to run EV3 programs with RobotC and trying run on EV3 Daisy Chaining. I have three independent EV3 bricks labelled A,B,C. </p>
<p>I want, according to the color reading by the color sensor on port 1 on brick A, the motors connected to bricks B and C have distinct behaviours.</p>
http://bricks.stackexchange.com/q/59821Is there a free EV3 simulator (virtual machine) for the Mac OS?J_Whttp://bricks.stackexchange.com/users/38532015-01-24T07:44:46Z2015-03-25T20:51:20Z
<p>I recently saw <a href="http://bricks.stackexchange.com/questions/3130/virtual-lego-technics-mindstorms-simulation-environments">this</a> question on a virtual EV3 machine. From the video, I felt that this software will be great. However, I don't have the budget needed to buy a licence. Is there any alternative to this system?</p>
http://bricks.stackexchange.com/q/59632Lego RCX 1.0 problem with communicationgregoryhttp://bricks.stackexchange.com/users/54262015-01-21T07:27:52Z2015-03-23T22:36:13Z
<p>I have a problem with communication between the tower (it's installed and it's working - green light when communicating by IR ) and a RCX 1.0. It's not downloading .lgo file. I've tried with few versions of this file and it's the same. </p>
<p>Now I'm trying on my PC in ROBOTC. Green light is lighting but RCX doesn't respond. I think it is failed. But manually with built in programs it's working</p>
http://bricks.stackexchange.com/q/48840How to fit lego power function LED lights onto cargo train (set: 60052)J. Hillhttp://bricks.stackexchange.com/users/43412014-12-28T18:46:35Z2015-03-28T19:48:36Z
<p>can anyone out there explain / illustrate how to fit lego power function white LED lights on the blue cargo train (set number 60052)? We have assembled the engine but I cannot see where or how these lights fit on the engine. I have watched a couple of YouTube videos showing how to fit these on other trains, but not the cargo train. There are not any holes or compatable pieces on the engine that can take the lights - as far as I can see anyway. My son is 7 and I am no lego expert by the way.
Thanks</p>
http://bricks.stackexchange.com/q/47774How can I attach a Technic Linear Actuator to a EV3 Medium Motor?jaiahttp://bricks.stackexchange.com/users/42092014-11-27T03:06:37Z2015-03-30T00:21:00Z
<p>I'm pretty new to serious LEGO building (never got past very blocky houses as a kid but got into Technic a couple of months ago) and need to connect a Technic large linear actuator (61927) to a Mindstorms EV3 medium motor for a piece of lab equipment I'm making. </p>
<p>Does anyone have any hints on how to do this? The mounting thing on the linear actuator keeps getting in the way and I'm having trouble getting things to line up.</p>
http://bricks.stackexchange.com/q/44293Why are Lego products so expensive in Europe?Gruberhttp://bricks.stackexchange.com/users/37562014-08-14T07:12:20Z2015-03-25T02:28:40Z
<p>Comparing a few Lego products at the official online store, I found U.S. prices seem to be consistently around 70% of those in Europe given current currency exchange rates. That's a surprising difference. Given that U.S. import tariffs apply to products manufactured in Europe (such as Lego), one would expect the price difference to be the other way around.</p>
<p><em>What is the primary reason for this price differentiation?</em> Better competition in the U.S.? Lower taxes? More wealthy Lego fans in Europe? </p>
http://bricks.stackexchange.com/q/29760Can Mindstorms EV3 communicate using protocol 802.15.4?jean-sebastien valderramahttp://bricks.stackexchange.com/users/35102014-03-06T09:39:47Z2015-03-25T00:12:58Z
<p>My aim is to make the robot communicate using <strong>protocol 802.15.4</strong> through a USB dongle 802.15.4 over 6LoWPAN.</p>
<p>The robot has to be able to get information from TelosB.</p>
<p>I wonder whether this possibility has already been tested and if it is possible to make it work and of course how?</p>
http://bricks.stackexchange.com/q/29201Creating a native EV3B blockuser3474http://bricks.stackexchange.com/users/34742014-02-25T22:17:23Z2015-03-29T01:49:07Z
<p>I'm trying to create a native block for a hardware sensor. I've got it working pretty well, but can't get it to show up in the "port view" as anything but a sound sensor. I really need the live view of the data the sensor is seeing. Is there an example of how this is done that I could follow?</p>
http://bricks.stackexchange.com/q/16385RobotC for RCX cannot find USB IR Towerabqorianhttp://bricks.stackexchange.com/users/11282012-11-02T02:28:07Z2015-03-23T22:31:09Z
<p>I have looked for similar question but found null. So here I am asking.</p>
<p>I have Win7, a RobotC fo RCX and Mindstorms for RCX (both are old version, but available free). I borrowed an old LEGO kit (9794 Team Challenge) which lacked some parts. It has RCX 1.0 as controller. I borrowed a USB IR Tower from my friend.</p>
<p>After a well installation, I tried RobotC and was asked to download firmware to RCX brick.
But RobotC cannot communicate with it because it cannot find the port which I plugged the IR tower to. Inside the preference, there are two available USB port recognized.</p>
<p>I swithced between them but RobotC still cannot find the tower. I have been googling this around for almost a month now.</p>
<p>Thanks for any enlightement.</p>
http://bricks.stackexchange.com/q/16191Getting the IR Tower working with RCX and RobotC [duplicate]Eric Banderhidehttp://bricks.stackexchange.com/users/11102012-10-22T12:25:57Z2015-03-23T22:31:23Z
<blockquote>
<p><strong>Possible Duplicate:</strong><br>
<a href="http://bricks.stackexchange.com/questions/1526/lego-mindstorms-rcx-ris-2-0-ir-tower-windows-7-windows-xp-driver">Lego Mindstorms RCX RIS 2.0 IR tower Windows 7 / Windows XP driver</a> </p>
</blockquote>
<p>Trying to get RobotC to work with my old RCX 2.0. I'm running windows 7 64 bit. I've connected the IR tower via a Serial to USB cable. I get the error from RobotC when I go to send the firmware "RCX Controler Failed to Respond"</p>
<p>I'm assuming this is because the drivers are for 64 bit only. Has anyone had success running a WindowsXP virtual machine and trying the drivers? Or any luck getting RobotC and the IR tower running on a Win7 64 bit machine.</p>
http://bricks.stackexchange.com/q/147910Removing glue from Lego bricksmj_http://bricks.stackexchange.com/users/9512012-07-20T18:47:06Z2015-03-31T22:05:41Z
<p>When I was five my Dad used some kind of a good glue to put together a set together so I didn't loose any pieces. Putting the ethics of that action aside, I want to split the bricks from another and remove the glue. I tried heating up the set in boiling water but the glue didn't budge. Any ideas out there?</p>
http://bricks.stackexchange.com/q/89914What was the first set produced by The LEGO Group?daviesgeekhttp://bricks.stackexchange.com/users/1422011-12-28T06:44:15Z2015-03-29T12:36:18Z
<p>What was the first Lego set produced, and when was it first released?</p>
http://bricks.stackexchange.com/q/35716What pieces are prone to breaking?Pubbyhttp://bricks.stackexchange.com/users/742011-10-29T14:04:37Z2015-03-26T15:15:35Z
<p>I've had a few pieces break over the years, which was a real bummer as I was not expecting them to.</p>
<p><strong>What are some commonly used pieces that are prone to breaking?</strong> Pieces that should be handled carefully and stored separately.</p>