Project Home
Project Home
Trackers
Trackers
Documents
Documents
Wiki
Wiki
Discussion Forums
Discussions
Project Information
Project Info
Forum Topic - A question about digital sensor: (3 Items)
   
A question about digital sensor  
Hi, it is not a qnx question, but a qnx application consultation.

Now I have a qnx box and a digital temperature sensor. The box have 10 DI/DO ports, 2 serial ports. How can I get the 
sensor's sampling temperature data by qnx programming? Need I buy an additional board?

Any suggestion will greatly appreciated.
RE: A question about digital sensor  
That depends on the interface of the digital sensor, serial port, USB etc?  Then you need to know the protocol and write
 a piece of code that will handle the data.

> -----Message d'origine-----
> De : Allen Chen [mailto:community-noreply@qnx.com]
> Envoyé : 5 juin 2013 11:38
> À : general-community
> Objet : A question about digital sensor
> 
> Hi, it is not a qnx question, but a qnx application consultation.
> 
> Now I have a qnx box and a digital temperature sensor. The box have 10
> DI/DO ports, 2 serial ports. How can I get the sensor's sampling temperature
> data by qnx programming? Need I buy an additional board?
> 
> Any suggestion will greatly appreciated.
> 
> 
> 
> _______________________________________________
> 
> General
> http://community.qnx.com/sf/go/post102028
> To cancel your subscription to this discussion, please e-mail general-
> community-unsubscribe@community.qnx.com

Re: RE: A question about digital sensor  
Hi Mario, it is a Arduino compatible SHT1x humidity and temperature sensor. There are six pins, i.e. DATA, CLOCK, 2 VCCs
 and 2 GNDs. I read the source code of Arduino encapsulated SHT1x class.Mainly it uses two PINs, DATA and CLOCK. It set 
pin DATA as input and pin CLOCK as ouput, and then use digitalWrite and digitalRead APIs to read humidity and 
temperature data.

I don't know whether it can be read via PC serial port. If yes, it really convenient for us to use this sensor on QNX 
box.

The attachment is Arduino SHT1x library class. Please have a look. Thank you.
Attachment: Compressed file SHT1x_Arduino Compatible with Arduino IDE 1.0 or later.zip 5.35 KB