 | | Re: NXC: turning on the light
|
|
We successfully tried the following: task light() { OnFwd(OUT_A, 100); } It works like a motor =) OnRev works as well. We haven't yet tried the other idea. (17 years ago, 15-Apr-08, to lugnet.robotics)
|
|
 | | Re: NXC: turning on the light
|
|
(...) Hi, Have you tried to connect the adapter cable in the output port and put the lamp on it? Use this program to test: task main() { OnFwd(OUT_A, 100); Wait(5000); Off(OUT_A); } This program assumes that you connected the cable in output A. (...) (17 years ago, 15-Apr-08, to lugnet.robotics)
|
|
 | | Re: NXC: turning on the light
|
|
(...) Since the lamp is a rather power hungry device, it is best to drive it with an output port. Use OnFwd(port, pwr) to turn it on (with brightness controlled by pwr parameter), Off(port) to turn it off. Though I have not tested, it should also (...) (17 years ago, 15-Apr-08, to lugnet.robotics)
|
|
 | | Re: NXC: turning on the light
|
|
(...) The lamp is relatively power hungry, so you should connect it to a motor port for best result. OnFwd ("ports", "pwr"); will light it, with brightness controlled by the pwr parameter. Off ("ports"); will turn it off. I have not tested, but most (...) (17 years ago, 15-Apr-08, to lugnet.robotics)
|
|
 | | Re: NXC: turning on the light
|
|
Thanks a bunch for the reply! The education set has the lamp, so my students would like to use it now... I'll keep you 'posted' about the results... Regards, Torsten Otto (...) (17 years ago, 15-Apr-08, to lugnet.robotics)
|