Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/janekjan/ugolibev3

Really micro (u) library for reading raw sensor values from ev3dev.
https://github.com/janekjan/ugolibev3

ev3dev go

Last synced: 3 months ago
JSON representation

Really micro (u) library for reading raw sensor values from ev3dev.

Awesome Lists containing this project

README

        

# ugolibev3
Really micro (u) library for reading raw sensor values from ev3dev.

###How to use
__Simple__:

go get github.com/janekjan/ugolibev3

go install github.com/janekjan/ugolibev3

Import with: import "github.com/janekjan/ugolibev3"

####Usage
value := ugolibev3.ReadSensorValue(0)

Put 0 as an argument when you have only one sensor attached and this will work. If you have two sensors the last attached sensor will return from ReadSensorValue(1) and the first attached - from 0. IT'S NOT THE PORT NUMBER.
It's like in http://www.ev3dev.org/docs/drivers/lego-sensor-class/ sensor file but not counting the disconnected sensors.