Hi, Matt,
Thanks!
I use the commands that you suggested. It works.
YH Chan.
Search found 17 matches
- 08 May 2011, 10:19
- Forum: Mindstorms Software
- Topic: Statements about LEGO lamp brick for NXC
- Replies: 8
- Views: 10579
- 08 May 2011, 09:00
- Forum: Mindstorms Software
- Topic: Statements about LEGO lamp brick for NXC
- Replies: 8
- Views: 10579
Re: Statements about LEGO lamp brick for NXC
From the the LEGO Mindstorms website, one can download a Lamp* block in the package of Legacy_Blocks. This block can control a lamp.
I want to control the lamp by NXC statements.
YH Chan.
I want to control the lamp by NXC statements.
YH Chan.
- 08 May 2011, 08:29
- Forum: Mindstorms Software
- Topic: Statements about LEGO lamp brick for NXC
- Replies: 8
- Views: 10579
Re: Statements about LEGO lamp brick for NXC
The lamp brick is the Electric, Light Brick 1 x 2 with Single Top Light.
The URL link is : http://www.bricklink.com/catalogItem.asp?P=4767
YH Chan
The URL link is : http://www.bricklink.com/catalogItem.asp?P=4767
YH Chan
- 08 May 2011, 07:58
- Forum: Mindstorms Software
- Topic: Statements about LEGO lamp brick for NXC
- Replies: 8
- Views: 10579
Re: Statements about LEGO Light Brick for NXC
Matt, Sorry! I mean the LEGO lamp brick, not the NXT Light Sensor or old RCX Light Sensor. I try to use the following program, but no affect. task main() { while(true) { SetSensorType(OUT_A, SENSOR_TYPE_LIGHT_ACTIVE); //Turn on the light Wait(1000); SetSensorType(OUT_A, SENSOR_TYPE_LIGHT_INACTIVE);/...
- 08 May 2011, 05:29
- Forum: Mindstorms Software
- Topic: Statements about LEGO lamp brick for NXC
- Replies: 8
- Views: 10579
Statements about LEGO lamp brick for NXC
Help!
What are the NXC statements for the LEGO lamp brick? How to control the functions such as on, off or blinking?
I cannot find these statements in the NXC Programmer's Guide.
YH Chan
What are the NXC statements for the LEGO lamp brick? How to control the functions such as on, off or blinking?
I cannot find these statements in the NXC Programmer's Guide.
YH Chan
- 11 Jan 2011, 16:30
- Forum: Mindstorms Software
- Topic: Sort Color Bricks Problem
- Replies: 1
- Views: 3270
Sort Color Bricks Problem
I want to write a NXC program to sort 4 color bricks (Blue, Green, Red and Yellow) by a Lego Color Sensor into relevant color baskets. There are 4 empty color baskets (Blue, Green, Red and Yellow) to be fixed in a moving train which is controlled by M1. The train moves, to and fro, to collect a colo...
- 28 Dec 2010, 03:22
- Forum: Mindstorms Software
- Topic: PSP-Nx v3 Button Problem
- Replies: 9
- Views: 10144
Re: PSP-Nx v3 Button Problem
Matt, muntoo,
Thanks!
YH Chan.
Thanks!
YH Chan.
- 27 Dec 2010, 10:07
- Forum: Mindstorms Software
- Topic: PSP-Nx v3 Button Problem
- Replies: 9
- Views: 10144
Re: PSP-Nx v3 Button Problem
Hi, Matt,
What are the meanings of the statements "B2=b2*(-1)+255;" and "B1=b1*(-1)+255;" and their purposes?
What are the values of the buttons in the PSP controller?
Can you help explain?
YH Chan
What are the meanings of the statements "B2=b2*(-1)+255;" and "B1=b1*(-1)+255;" and their purposes?
What are the values of the buttons in the PSP controller?
Can you help explain?
YH Chan
- 30 Nov 2010, 07:45
- Forum: Mindstorms Software
- Topic: Button
- Replies: 5
- Views: 6548
Re: Button
Hi, Mattallen, What is the difference between "(0 == ButtonCount(BTNCENTER,true)) " and "(ButtonCount(BTNCENTER,true)==0)"? In the following program, If the statement "while (0 == ButtonCount(BTNCENTER,true))" is replaced by "while (ButtonCount(BTNCENTER,true)==0) ...
- 30 Nov 2010, 06:24
- Forum: Mindstorms Software
- Topic: Button
- Replies: 5
- Views: 6548
Button
What is the meaning of the statement " (0 == ButtonCount(BTNCENTER,true)) "? What is its purpose in the following program? ................................................................... while (0 == ButtonCount(BTNCENTER,true)) { if (ButtonCount(BTNLEFT,true) && N > 0) { N--; }...