Welcome to Tech Support Forum home to more then 136,000 problems solved. Issues have included: Spyware, Malware, Virus Issues, Windows, Microsoft, Linux, Networking, Security, Hardware, and Gaming Getting your problem solved is as easy as:
1. Registering for a free account
2. Asking your question
3. Receiving an answer

Registered members:
* Get free support
* Communicate privately with other members (PM).
* Removal of this message
* See fewer ads.
* And much more..

 





Want to know how to post a question? click here Having problems with spyware and pop-ups? First Steps
Go Back   Tech Support Forum > The Conversation Pit > Programming
User Name
Password
Site Map Register Donate Rules Blogs Mark Forums Read

Programming A discussion forum for programs and programming used in tech-related businesses.

Reply
 
Thread Tools
Old 03-15-2008, 10:47 AM   #1 (permalink)
Registered User
 
Join Date: Mar 2008
Posts: 2
OS: xp


vb code request for private data logger

Hi, i had a a lot of trouble trying to build a software to read my data logger which i built lately. I will explain all my specification i would want my simple program to run.

First, it uses parallel port pin ( d0,d1,d2,d3) to receive data only. I want to received the sensor data in this order of arrangement. Because the total data i will be receiving for each sensor is 12 binary data, i will be sending from my PIC16F877A for 3 times each time is 4 bit shifted out.

Example of data received, 0001 1010 1111.

The data will send in 0001 first and 1 sec delay till 1010 came in and lastly 1111. I want to have it arrange became 1111 1010 0001. Then from the reading of 12 bit the 2 first bit will be my control bit to be used in case for working out the formula for each sensor. Basically i have 3 sensor i have set in my PIC to send in 01 for humidity 10 for temperature and 11 for pressure.

The next sequence is to identify the control bit accordingly and have a variable for that type of sensor under a case. After having the sensor type selected in the case,

For humidity conversion is as below,

RH= (D/1023) x 2.45 , where D is the decimal for that particular sensor under control bit 01

after getting the value for RH compare it to the case value below,

< 0.74 = <10%RH
> 0.74 = >10%RH
> 0.95 = >20%RH
> 1.31 = >30%RH
> 1.68 = >40%RH
> 2.02 = >50%RH
> 2.37 = >60%RH
> 2.69 = >70%RH
> 2.99 = >80%RH
> 3.19 = >90%RH

Then, stored %RH into the database value array with timestamp and move to the next sensor data conversion, temperature

the decimal value obtained for control bit 10 is for temperature and the conversion is as below

T = ( D/ 209) x 26

and stored the temperature value in value array

lastly pressure sensor at control bit 11.

S = (D/1023) x 4
P = ( S - 0.4105 ) x 15.5767

Store p value under value array for pressure

After done all this the database text pad should have the following array

Time | Sensor type | Binary | Decimal | Value

And not least, the graph plotted out according to the value x time stamp.

It's hard for a newbie to do all this, so i really appreciate if anyone mind helping me out for this private application i am trying to build.

VB6 user
nicknicknick is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Bookmark on Thread SoupReddit!
Reply With Quote
Old 03-16-2008, 12:17 PM   #2 (permalink)
Registered User
 
Join Date: Mar 2008
Posts: 2
OS: xp


Re: vb code request for private data logger

how to delete this thread ? i cant find the delete button coz i already created the software and debugged it working perfectly.
nicknicknick is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Bookmark on Thread SoupReddit!
Reply With Quote
Reply


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off



All times are GMT -7. The time now is 04:12 PM.



Copyright 2001 - 2008, Tech Support Forum

Search Engine Friendly URLs by vBSEO

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82