Site Logo

 
It is currently Mon Jul 28, 2014 10:29 am

All times are UTC - 6 hours




Post new topic Reply to topic  [ 5 posts ] 
Author Message
 Post subject: Are you a tinkerer? Looking for beta testers/tinkerers
PostPosted: Tue Jan 18, 2011 10:42 pm 
Offline

Joined: Mon Dec 06, 2010 12:27 am
Posts: 9
Greetings TC Makers,

I visited the open house on wednesday a few months ago and had a chance to meet some of you. I have since been lurking around here on the forum. Love the hackerspace, idea. Cant have enough of this stuff!!! Only wish I had more time from my real day job.

Anyways, I am wondering if anyone would be interested in beta testing some new projects I have been working on at my new gig, TinkerAct ( http://www.tinkeract.com ). TinkerAct is a blog that I have started recently that will chronicle development of my projects, essentially a brain dump of useful and sometimes not so useful ideas of mine and my colleague, Marlyn Anderson's.

After many design cycles and revisions and endless board etchings, I think we are getting close to the final design of the first one. We are working on literally dozens of projects. All in different stages of design. Some are on paper, some are on breadboard, some have been etched...

I am mainly doing this for fun, but haven't excluded the business side of things either. These things cost money as we all know, so if I could pay for it by selling small lab made batches, I won't mind it.

With that said, I would like to debut the first creation/project (product??)

Drum roll please....

Image

Image

Image

Ok I know its not gonna turn any heads, but I think its nifty and useful, nevertheless. Its a USB thermometer. It takes ambient air temperature measurement and outputs the data on the serial port. There's a simple command line interface, which allows it to be called from inside of shell scripts (bash on Linux), and other programming languages (e.g. python on windows). The idea is to be able to query this little guy and get a temperature reading:

All 5 are hand etched and made in the lab over the last week or so, with different configurations, board sizes, PCB layout, and components. Its built using the Arduino platform. We have used different combination of the microcontroller on running at different speeds to refine the design. But they all do the essentially same thing

There could be many cool uses for this thing. You could use it to:

- Email or SMS your office temperature to yourself on a periodic basis or when a certain threshold is met.
- Log the data over a period of time and graph it using cacti or google graphs
- Send data to pachube ( http://www.pachube.com/ ) or a similar web aggregator.

etc etc...

(we could throw one in a running pc at hacker space, and graph the data to see how the climate inside varies over the course of a day in different seasons)

I am looking for a 3 people (I've got 3 working units) to tinker and play with these share your experience with all. The idea is that the first three people to get it will keep it for a week. After a week, you will need to give it to the next person on the list. If there isnt anyone else, you get to keep it!

You will get full schematics, and Arduino code so you can modify it to your heart's desire.

Here's what we ask:
- If you change the code, you must restore it back to its original firmware when you are done and are about pass it the next person.
- Post your suggestions/changes/fixes.
- After 1 week or later on request, please give to the next person to tinker with.
- We would like to limit the changes to software for now, but if you want to hack the hardware, please let me know and we will make one for you.

Send an email to [email protected] if you are interested. I will be at hack factory tomorrow with my colleague Marlyn Anderson. I will bring the goods with me!

Cheers,

Asim


Top
 Profile  
 
 Post subject: Re: Are you a tinkerer? Looking for beta testers/tinkerers
PostPosted: Wed Jan 19, 2011 9:31 am 
Offline
User avatar

Joined: Tue Jan 13, 2009 5:47 am
Posts: 295
Location: Minneapolis
Hi Asim,

You should swing by and demo your project for us. Our open house is 7pm tonight.

_________________
///////// John B


Top
 Profile  
 
 Post subject: Re: Are you a tinkerer? Looking for beta testers/tinkerers
PostPosted: Wed Jan 19, 2011 11:09 am 
Offline

Joined: Mon Dec 06, 2010 12:27 am
Posts: 9
romaali wrote:
Its a USB thermometer. It takes ambient air temperature measurement and outputs the data on the serial port.


I meant to say USB not serial :-)

@john: I will be there tonight.


Top
 Profile  
 
 Post subject: Re: Are you a tinkerer? Looking for beta testers/tinkerers
PostPosted: Thu Jan 20, 2011 10:27 am 
Offline

Joined: Mon Dec 06, 2010 12:27 am
Posts: 9
Here's the sketch to go with it. I will post python code and instructions on how to use it from console in the next post.

Code:
/*
 USB Temperature Measurement Thingy (aka Thermometer)
 Measures the ambient air temperature and outputs it in F and C scales
 
 Circuit: USBTemp Thingy from Tinkeract.com
 
 Jan 20, 2011
 (c) 2011 Tinkeract.com
 */

int analogPin = 0;
float reading=0;
float t=0;
char ch;
int pos;
char buffer[32];

void setup()
{
  Serial.begin(9600);
 
  // We are using a precise 2.048 voltage reference for AREF
  analogReference(INTERNAL);
  pos = 0;
  for (int i = 0; i < sizeof(buffer); i++)
    buffer[i] = 0;
}

void loop()
{
  if (Serial.available() > 0)
  {
    ch = Serial.read();

    if (ch == '\n' || ch == '\r')
    {
      buffer[pos] = 0;
     
      if (strcmp(buffer, "f") == 0)
          printTemperature('f');
      else if (strcmp(buffer, "c") == 0)
          printTemperature('c');
      else if (strcmp(buffer, "h") == 0 || strcmp(buffer, "?") == 0)
          help();
      pos = 0;
    }
    else
    {
      buffer[pos] = ch;
      pos++;

      if (pos >= sizeof(buffer))
        pos = 0;
    }
  }
 
  /*
  *
  * DEBUG
  printTemperature('c');
  printTemperature('f');
  delay(1000);
  */
}

void printTemperature(char scale)
{
    reading = 0;
    for (int n=0; n < 3; n++)
    {
        reading = reading + analogRead(analogPin);
    }
    reading = reading/3;
    t = reading * 2;
    t = t - 500;      //  compensate for ( (10bit=1024) / 2048mV Aref)
    t = t / 10;       // 10mv/deg C
   
    // Round off to nearest degree 
    //t = (t > (floor(t)+0.5f)) ? ceil(t) : floor(t);
       
    if (scale == 'c')
    {
        //t = (t > (floor(t)+0.5f)) ? ceil(t) : floor(t);
        Serial.println(t);
    }
    else if (scale == 'f')
    {
        t = t * (float)9/5;
        t = t + 32.0;  // C->F
        //t = (t > (floor(t)+0.5f)) ? ceil(t) : floor(t);
        Serial.println(t);
    }
}

void help()
{
    Serial.println("USB Temperature Measurement Thingy (aka Thermometer) (v 1.0)");
    Serial.println("Measures and outputs ambient air temperature in both Farenheit");
    Serial.println("and Celsius scales.");
    Serial.println("(c) 2011 Tinkeract.com");
    Serial.println("");
    Serial.println("Help:");
    Serial.println("f   - output in Farenheit");
    Serial.println("c   - output in Celsius");
    Serial.println("h/? - help");   
}





Top
 Profile  
 
 Post subject: Re: Are you a tinkerer? Looking for beta testers/tinkerers
PostPosted: Fri Jan 28, 2011 12:00 am 
Offline

Joined: Mon Dec 06, 2010 12:27 am
Posts: 9
Sample Python code to get current temperature:

You will need http://pyserial.sourceforge.net/

On linux:
$ ./readtemp.py /dev/ttyUSB0

On Mac:
$ ./readtemp.py /dev/tty.usbserial-A600eGxq

On Windows:
$%&*#%^@%^&*($#%^%#*

(Seriously?)


Code:
#!/usr/bin/env python

from serial import *
import string
import time

#PORT = '/dev/tty.usbserial-A600eGxq'

if (len(sys.argv) < 2):
    sys.stderr.write("%s <port>\n" % sys.argv[0])
    exit(1)

port = sys.argv[1]

try:
    try:
        ser = Serial(port, 9600, timeout=1)
        time.sleep(2) # this is needed
        ser.write("f\n")
    except SerialException, e:
        sys.stderr.write("%s\n" % e);
        exit(1)

    while True:
        data = ser.readline()
        if data == '':
            break
        sys.stdout.write(data)
except KeyboardInterrupt:
    sys.exit(0)



Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 5 posts ] 

All times are UTC - 6 hours


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
Template made by DEVPPL Flash Games