|
Page 1 of 1
|
[ 3 posts ] |
|
setting up light sensor issues
| Author |
Message |
|
joetrotter
Rookie
Joined: Tue Aug 14, 2007 1:38 pm Posts: 16
|
 setting up light sensor issues
I am trying to set up the light sensor in Robotc 3.04 Instead of using the sensor setup I have my students set them up themselves. When we write:
SensorType[0]=sensorReflection; compiles but does not read sensor SensorType[in1]=sensorReflection; compiles but does not read sensor
When setting up sensor with the sensor setup screen it works.
We are doing the same way we did it with the Mindstorm NXT but no success. Any help on what's going on would be appreciated
|
| Wed Jan 11, 2012 3:24 pm |
|
 |
|
jbflot
Site Admin
Joined: Tue May 15, 2007 9:02 am Posts: 385
|
 Re: setting up light sensor issues
Hi Joe,
How are you trying to read the sensor in your program? I tested your code and am getting appropriate values from the sensor debug window:
|
| Thu Jan 12, 2012 11:18 am |
|
 |
|
joetrotter
Rookie
Joined: Tue Aug 14, 2007 1:38 pm Posts: 16
|
 Re: setting up light sensor issues
Thanks for the reply. I have the exact same code as you showed but with no response on the debug sensor window. My students are just going through making sure they can set the different sensors and motors up since they just came off programming the NXT. The strange thing is we have no problems with setting up and reading other senser types - touch,sonar,quadencoders,etc. We have the PIC .5, running RobotC 3.04. I couldn't think of any settings that might cause it. Weird! For now we can set it up in the sensor/motor setup. I was just trying to have them use and learn programming as well as the robotics application. If you think of anything let me know.
Thanks
|
| Thu Jan 12, 2012 1:39 pm |
|
|
|
Page 1 of 1
|
[ 3 posts ] |
|
Who is online |
Users browsing this forum: No registered users and 2 guests |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot post attachments in this forum
|
|