View Single Post
  #2   Spotlight this post!  
Unread 21-11-2016, 08:28
ArtemusMaximus's Avatar
ArtemusMaximus ArtemusMaximus is offline
Enginerd
FTC #11722
Team Role: Coach
 
Join Date: Apr 2014
Rookie Year: 2014
Location: Canada
Posts: 248
ArtemusMaximus is a name known to allArtemusMaximus is a name known to allArtemusMaximus is a name known to allArtemusMaximus is a name known to allArtemusMaximus is a name known to allArtemusMaximus is a name known to all
Re: [FTC]: Using multiple sensors of same type

Quote:
Originally Posted by godkane View Post
I got tired of not being able to read two color sensors or two sonic sensors, so I re-wrote the code to get them to work as expected.

In configuration, make sensor "I2C Device".

Initialization is hardware map, device name, and configured address.
color = new RedStormColorSensor(hwMap, "cb", 0x40);
range = new RedStormRangeSensor(hwMap, "rf", 0x2a);
Can this be used for Adafruit Color sensor?
__________________
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~
2017 FTC 11722 (Coach)
2016 FTC 10544 (Coach) Canadian Championship Finalist, Rockwell Collins Innovate Award.
2014 FRC 5064 (Mentor)
Reply With Quote