Show Posts
Pages: [1] 2
1  Forum 2005-2010 (read only) / Syntax & Programs / Re: display only data that has changed on: July 03, 2010, 11:48:13 am
This appears to work great!  Thank you for the quick reply paul
2  Forum 2005-2010 (read only) / Syntax & Programs / display only data that has changed on: July 03, 2010, 10:18:47 am
Ok, I am trying to do something that has me a bit confused.  I only want to display data on the lcd or serial monitor if the data has changed.  Example.  If the temperature stays constant at 90 deg F, I don't want the serial monitor to constantly send 90 one billion times.  I have tried the not equal (!=)but I am at a loss at the moment.  As for the LCD, to wont matter to me if it keeps sending the data.  The serial part is going to an excel sheet, and only need it up dated when it changes to something else.
3  Forum 2005-2010 (read only) / Syntax & Programs / Re: trying to adjust a setpoint on: February 14, 2010, 02:49:24 pm
Ok gave up on the buttons, (external componets)  I have the lcd display from RobotShop, and it has 5 buttons going into the Analog pin 0 on a voltage divider network, and I have it working (adjusting the set point up and down.  I had a problem with the value floating above and below the == value that I had for a value.  I just mapped it to a lower value (it was 0 to 1023 and is now 0 to 50).  But it is working like a champ and I celebrated with a beer.  Next comes controlling a fan in referance to the temp and setpoint.  Fun fun!
4  Forum 2005-2010 (read only) / Syntax & Programs / Re: trying to adjust a setpoint on: February 14, 2010, 01:57:17 pm
Thank you again!  I am still learing this stuff, but I think that I am getting the hang of it.
5  Forum 2005-2010 (read only) / Syntax & Programs / Re: trying to adjust a setpoint on: February 14, 2010, 01:26:15 pm
Thanks AWOL, that was the problem.  Working better, just have to get a pull down resistor on it to keep it from counting now.  Thanks
6  Forum 2005-2010 (read only) / Syntax & Programs / trying to adjust a setpoint on: February 14, 2010, 12:43:34 pm
Ok, I have had my arduino for a week now, and have been having lots of fun with it.  Now I am trying to write a program that will control the temp of a item.  The problem that I am having is adjusting the set point up and down.  just wont do it.  Here is my code so far.  I tried to do it from the Java console and I received nothing but errors but here it is.

#include <LiquidCrystal.h>

LiquidCrystal lcd( 8, 9, 4, 5, 6, 7);

int setPup = 3;        // setpoint up
int setDown = 10;      // setpoint down
int analogPin = 0;     // voltage divider network on pin analog 0
                       // it will become pin 1 for the Thermister.
int val = 0;           // where it will store the input
int setpoint = 250;    // trying to get a setpoint for temp control

void setup()
{
  lcd.begin(20, 2);            // this gave me a head ache for a few days, I thought my display was bad lol
  Serial.begin(9600);          // setup serial, and testing for me.
  pinMode (setPup, INPUT);     // raise setpoint
  pinMode (setDown, INPUT);    // lower setpoint
}

void loop()
{
 
  val = analogRead(analogPin);     // read the input pin
  val = map(val, 0, 1023, 0, 350); // remapped the value for the smokers temp probe
  Serial.println(val);             // bug checking
  lcd.setCursor(0,0);              // sets the position of the cursor
  lcd.print("dans smoker");        // it belonges to him
  lcd.setCursor(13,0);             // this is where the temp goes
  lcd.print(val);                  // mapped version of the temp on screen
  lcd.setCursor(13,1);             // set the cursor for setpoint display
  lcd.print(setpoint);             // setpoint display
  delay(500);                      // needs to be removed after it is running
  if (setPup > 1) ++ setpoint;
  if (setDown > 1) -- setpoint;
}
7  Forum 2005-2010 (read only) / Interfacing / Re: plx-daq on: July 04, 2010, 11:36:45 am
ok, was doing things the hard way.  Took a step back and now I see how easy it was to do.  I need a board so I can smack my self in the head!  But hey, I did learn something and that is the big thing.
8  Forum 2005-2010 (read only) / Interfacing / plx-daq on: July 04, 2010, 10:30:27 am
is there a library for PLX-DAQ?  I got it working but it was not very pretty!  Its control and directives needed to be in all caps with the values comma separated.   This was the only way I could get the data to show up in the excel program.
Code:
int val = 0;
int val1 = 0;

void setup() {
      Serial.begin(9600);      // opens serial port, sets data rate to 9600 bps
        //int val = 0;
}

void loop() {
delay(500);
val++;
if (val > 29) Serial.println("CLEARDATA");
Serial.print(byte(68));
Serial.print(byte(65));
Serial.print(byte(84));
Serial.print(byte(65));
Serial.print(byte(44));
Serial.print("TIME");
Serial.print(byte(44));
Serial.println(val1);
//if (val > 29) Serial.println("CLEARDATA");
if (val > 29) val = 0;
val1 = random(50, 75);
9  Forum 2005-2010 (read only) / Troubleshooting / Re: New Arduino Uno, can't upload Blink on: October 16, 2010, 08:10:55 pm
how about running it as an administrator, and in compatibility mode?  Some times it will work for most programs. smiley-wink
10  Forum 2005-2010 (read only) / Troubleshooting / Re: protocol error, expect=0x14, resp=0x51 on: February 15, 2010, 06:21:09 am
I thought that mine was cooked too.  I made a partion on my laptop and installed ubunto linux on it and did a dual boot.  And it worked!  I have Windows 7 pro 64 bit and I could not for the life of me get it to work.  I have tested it under windows 2000, xp and vista.  It worked on all of them.  Try the linux on your system first before you buy a new board, or try it out on a vista or xp system.
11  Forum 2005-2010 (read only) / Interfacing / Re: Problems with PWM on: April 05, 2010, 08:57:55 pm
that is what I was thinking, have to find a regular fan and give it a try.
12  Forum 2005-2010 (read only) / Interfacing / Problems with PWM on: April 05, 2010, 03:28:18 pm
Ok, I am having a slight problems controlling a fan with PWM.  I am using the schematic and program from here http://itp.nyu.edu/physcomp/Tutorials/HighCurrentLoads, but at any signal from 0 to 254 it will not run, only at 255 will it run.  One thing that I am wondering is, the fan is a brush-less fan, would that make a difference?
13  Forum 2005-2010 (read only) / Interfacing / Re: interfacing with keypad/lcd of unknown origin on: March 28, 2010, 10:01:59 am
pull off the large pin connector on the lcd, and see what the make of the lcd controller is and do a search for it.  The keyboard is probably just a matrix setup and no big deal.  look in the playground under keypads or keyboards and there are some good ones to use.  I use it for a 5X4 matrix and it work great.
http://www.arduino.cc/playground/Code/Keypad
14  Forum 2005-2010 (read only) / Interfacing / Re: Replacing Relays with Arduino Controlled MOSFETs on: March 28, 2010, 09:56:00 am
if you are going to be in the engine compartment, then some sheided wire is going to be needed.  ignition noises and such.
15  Forum 2005-2010 (read only) / Interfacing / Re: Emulating a temp sensor on: February 21, 2010, 04:53:32 pm
not with just one resistor, you will need a 3 wire pot to do that.  The outer ones go to 5V and ground, and the center goes to you analog input.  Or you could make a voltage divider with several resistors in series and take the different voltage drops between the resistors to use as a simulation.
Pages: [1] 2