I want to connect EV3 IR and ultrasonic sensors to my Arduino. Unfortunately could not find any good documents describing how to use/control them.

Could you please help?

Thank you very much.

1 Answer 1


LEGO has released the source code for the EV3, so you can see how it works. Look for the "EV3 Firmware Source Code" at http://www.lego.com/en-gb/mindstorms/downloads.

You can also find the documentation generated from this source code at http://ev3.fantastic.computer/doxygen/index.html. In particular, these sensors are documented at http://ev3.fantastic.computer/doxygen/UartProtocol.html. But beware! The documentation on the UART sensors is not 100% correct. When in doubt, trust the actual code and not the comments.

And finally, don't forget to search for existing Arduino libraries for these sensors. Unless you want to implement your own library just for the sake of doing it yourself, you can save yourself some work. For example, you can find a library at https://github.com/lawrie/EV3_Dexter_Industries_Sensors/tree/master/EV3_arduino from one of the leJOS core contributors.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.