LabVIEW for LEGO MINDSTORMS and LabVIEW for Education

Showing results for 
Search instead for 
Did you mean: 

reading an analog voltage using LabVIEW and an EV3

Oh, that is excellent news. I will test it out and then respond here to let you know if it works for me.



0 Kudos
Message 11 of 12

Hi danblu! Due to the pandemic, I'm just now returning to this project and working on communicating with the EV3 robots again.


Thanks SO much for what you've developed here -- it's really helpful. 


If you still have any memory of what you and Steve did so long ago, I have some follow-up questions:

1 - This ReadSensor is sort of working for me but not completely.  It is clearly reading the input that I put in (to pin 6) but it only ever gives me an output of either 0 or 1.  


2- Investigating the VI, I wasn't sure if the output should be integers or DBL.  I thought that perhaps in the conversion to integers, the VI was rounding somehow?  The documentation does seem to indicate that both the raw and scaled values should be integers, though there isn't much information about what the "scaled" value.


3 - Comparing your ReadGenericSensor to the original, I see that the settings seem to be different for the Scaled values but not for the RawValues. I don't know enough about these "Invoke Node" objects (labelled EV3InputPrimitive in this case?) that are inside the VI to communicate with the EV3 brick.


You mentioned that possibly the defaults weren't saving properly, so I'm attaching a screenshot of the EV3 case which shows what I think are the relevant settings.  On the InputReadRaw object on the left, the settings match the defaults from the original ReadGenericSensor; on the InputReadSi object on the right, the type is 119 (compared to 0 in the default), the mode is 0 (was 255), and the count is 1 (was 1 originally).  Otherwise as far as I can tell, things are the same? 


I can't find any information about these Invoke Node/EV3InputPrimitive objects, so I can't check these settings.  If anyone can point me in the direction of information on this, that would be amazing.



0 Kudos
Message 12 of 12