Ticket #38 (closed feature request: fixed)

Opened 4 years ago

Last modified 3 years ago

Support new NXT 2.0 Color Sensor

Reported by: atorf Owned by: atorf
Priority: low Milestone: v4.04
Component: Toolbox Function Keywords: color, sensor, analog, nxt 2.0, 2.0
Cc:

Description

Add support for the new color sensor from the new MINDSTORMS NXT 2.0 set (8547).

This "LEGO color sensor" is a completely new analog sensor. It may or may not be complicated to retrieve values — it may be impossible to retrieve values via remote direct commands (due to low-level commands needed and precise timings), but no idea yet.

This LEGO color sensor is not to be confused with the HiTechnic Color Sensor (and the HiTechnic Color Sensor v2). Those are digital sensors, and should be supported by toolbox functions OpenColor and GetColor.


Official documentation on the NXT 2.0 Color sensor is not available yet, some more info:  http://lejos.sourceforge.net/forum/viewtopic.php?p=7411

Please note the apparently removed old complicated code (marked red) from this changeset (indicating the sensor might not be as complicated over all?):  http://lejos.svn.sourceforge.net/viewvc/lejos/trunk/classes/lejos/nxt/ColorLightSensor.java?view=diff&r1=3310&r2=3311

Attachments

Change History

Changed 4 years ago by atorf

Apparently we can access the NXT 2.0 Color sensor via IO Maps. It seems the Input Module Map has changed with Firmware ver 1.2x. Thanks to John Hansen for pointing this out. More details:

 http://forums.nxtasy.org/index.php?showtopic=4322&view=findpost&p=32882

Changed 3 years ago by atorf

Some more news on this: It seems we don't even need IO Maps, maybe some new sensor modes and the classic NXT_GetInputValues command is enough. Look at NXT-Python here:

 http://code.google.com/p/nxt-python/issues/attachmentText?id=6&aid=-8249402819910847061&name=colorsensor.patch&token=786a9c23b18a51b5b4eb7d2effeef05b

Changed 3 years ago by behrens

The sensors have been arrived.

Changed 3 years ago by anonymous

Changed 3 years ago by atorf

  • owner set to atorf
  • status changed from new to accepted

Confirmed: We don't need IO Maps for the NXT 2.0 Color Sensor, it's all handled via new sensor types and then a classic call to NXT_GetInputValues.

More info on this inside this nice direct command overview:  http://www.ni.com/pdf/manuals/372574c.pdf (pages 22 and 28).

Changed 3 years ago by atorf

  • status changed from accepted to closed
  • resolution set to fixed

Changed 3 years ago by atorf

Fixed with r904 and mainly r905. Basic support exists, but to access raw values (of R, G, B, and background channel) in COLORFULL mode, IO maps are probably needed. Since nxtasy.org is currently down, here are google cache links for the links from above:

 http://webcache.googleusercontent.com/search?q=cache:gbO3Ws2gU78J:forums.nxtasy.org/index.php%3Fshowtopic%3D4322+http://forums.nxtasy.org/index.php%3Fshowtopic%3D4322&cd=1&hl=en&ct=clnk&lr=lang_de|lang_en&client=firefox-a

 http://webcache.googleusercontent.com/search?q=cache:XCO4k0_ghikJ:forums.nxtasy.org/index.php%3Fshowtopic%3D5680+http://forums.nxtasy.org/index.php%3Fshowtopic%3D5680&cd=2&hl=en&ct=clnk&lr=lang_de|lang_en&client=firefox-a

If one starts looking inside the NBC / NXC header & definitions file, one ends up with a system call that cannot be further traced (at least not easily). Some other time this could be a new ticket. Please note that then again, ticket #27 probably needs to be fixed, too.

Changed 3 years ago by behrens

  • milestone set to v4.04

Add/Change #38 (Support new NXT 2.0 Color Sensor)

Author



Change Properties
<Author field>
Action
as closed
The resolution will be deleted. Next status will be 'reopened'
 
Note: See TracTickets for help on using tickets.