Show Posts
Pages: 1 ... 719 720 [721] 722 723 ... 1169
10801  Using Arduino / Programming Questions / Re: Help setting I2C address on MCP23008 on: April 17, 2011, 04:41:40 pm
From the Arduino reference for the Wire Library:

Quote
There are both 7- and 8-bit versions of I2C addresses. 7 bits identify the device, and the eighth bit determines if it's being written to or read from. The Wire library uses 7 bit addresses throughout. If you have a datasheet or sample code that uses 8 bit address, you'll want to drop the low bit (i.e. shift the value one bit to the right), yielding an address between 0 and 127.

http://arduino.cc/en/Reference/Wire

Lefty
10802  Using Arduino / Sensors / Re: Calibrate Temp Sensor on: April 17, 2011, 04:26:12 pm
Quote
My question is: How do people "calibrate" the sensors?


Having just looked over the datasheet for this sensor, I don't think the sensor has any internal method of calibrating the device. That would mean you would have to do that independently in your sketch by either adding or subtracting a calibration factor to the reading, and that assumes any sensor error is linear over your required operating range.

 I guess a useful first step is to just run through a temperature range with the sensor using some other temperature sensor as a 'reference' and see what you have. Having worked in industry that dealt with calibrating process sensors I can say with pretty good confidence that words like calibration and accuracy need a lot of operational definitions applied before a successful plan can be applied. 

Lefty
10803  Using Arduino / Microcontrollers / Re: Schematics of Arduino using ATMEGA8 on: April 17, 2011, 02:28:17 pm
http://arduino.cc/en/uploads/Main/arduino_NG_schematic.png
10804  Development / Other Hardware Development / Re: Problems uploading sketches to stripboard arduino using FTDI cable on: April 17, 2011, 10:57:16 am
You have two choices. If your FTDI cable breaks out the DTR signal then you can wire it to the reset pin through a series .1ufd cap and the IDE will automatically reset your chip at the correct time. If your FTDI cable does not provide that function then you must use a manual reset button. The timing is tricky but most use a method of holding down the reset button, then press upload on the IDE and when you see the completed complied sketch size report then release the reset button. May take practice but it will work with a little practice.

Lefty

10805  Using Arduino / Project Guidance / Re: pin 2 pullup res on: April 17, 2011, 10:50:07 am
If the chip has a fairly recent arduino bootloader installed I believe it already sets the internal pull-up on to prevent the bootloader from responding to noise on pin 2 and hanging the chip up waiting for an upload that is not coming. If the chip does not use a bootloader then there is not concern about noise on pin 2.

Lefty

10806  Using Arduino / Motors, Mechanics, and Power / Re: Big DC Motor?? 180V dc rated at 12A. on: April 17, 2011, 10:44:55 am
Would I have to go the MOSFET route or could I simply get away with using an appropriately rated SSR, triggered by the PWM output of the Arduino to "chop up" a 180V DC source?

Most SSR are for AC voltage only as they use SCRs or Triacs that won't work with DC voltage switching.

Going with logic level mosfets (if you can find some rated for such high voltage) would be the simplist method and then the arduino could use a PWM output pin to vary the speed of the motor using analogWrite() statements.


The 180v DC would be coming from a simple transformed mains - rectified and smoothed.

Be sure your AC outlet, circuit branch wiring and panel circuit breaker is rated for this current.

Lefty
10807  Using Arduino / Sensors / Re: PH Sensor on: April 16, 2011, 06:23:29 pm
Here is an E-bay seller that has both interfacing modules and PH probes. Don't underestimate the exacting requirements of the input electronics needed to accurately read PH probes. It's a difficult measurement with a large dynamic range.

http://shop.ebay.com/atlasscientific/m.html?_trksid=p4340.l2562

Lefty
10808  Using Arduino / General Electronics / Re: Does an OUTPUT require a Pull Down resistor ? on: April 16, 2011, 06:07:59 pm
Thank you floresta. I'm sorry for my attitude. After some searching, I realized tri-stated means the same as High-Z but still it's the property of the gate. The pull-up resistor seems to me to be "not a part of the tri-state gate". P77 is the diagram of a pin. I'll study it more.

"Tri-state" defines a possible enabled state of a digital output pin, not an input pin. Some output types are open collector, open drain, TTL output and TTL Tri-state. Each is electrically different. The output pins on an arduino are not strictly defined as Tri-state output pins as there is no way to have the pin enabled as an output pin and still be in a tri-state mode. Once you use the mode statement to set a pin to output, it will immediately assume either a active high or active low state. Only by redefining the pin as an input pin with the mode statement will the pin assume a Hi-Z mode, assuming the internal pull-up is not enabled. An Arduino I/O pin can be made to mimic a tri-state output but only by changing it's mode from output to input and then back to output depending on what state you need it to be placed in. This is seem in the popular Charlieplexing scanning technique.

http://en.wikipedia.org/wiki/Three-state_logic

Lefty

10809  Using Arduino / Interfacing w/ Software on the Computer / Re: Use serial monitor while COM port is in use? on: April 16, 2011, 04:27:26 pm
For debugging purposes, how can I use the serial monitor for debugging while the COM port is in use by Simulink? I get an "in use" error from either Simulink or Arduino, depending on which application starts first.

This is a restriction from the PC operating system, only allowing one application at a time to connect to a specific comm port.

Also, How can I use serial.read () to interpret a 16 bit signed integer being sent by the PC?

The Arduino serial.read() function can only deal (read) with one byte per read statement. If sending multbyte variables from a PC then your sketch code must read them as a series of individual bytes and then reassemble them into a int or long or float or array variable, as the case my be.

Lefty
10810  Using Arduino / Sensors / Re: Calibrate Temp Sensor on: April 16, 2011, 02:10:36 pm
I am building a controller for a salt water reef aquarium that will turn on and off heaters, lights, fans, etc. based on the temperature of the water.  I'm using DS18B20 sensors and I have three of them.   In bench testing all three of them vary by up to 1 degree.  In addition they all show higher than my standard thermometer on the wall although I can't really vouch for it.

My question is: How do people "calibrate" the sensors?  I can vary the output in code to agree with the wall thermometer.  In practical use the temp should only vary by 3 or 4 degrees.  Is there a practical "known accurate" thermometer to be used for calibration?

One method is to use 'known' temperature sources to validate/calibrate temp sensors. Boiling water (100C or 212F) and crushed ice baths (0c and 32f) are pretty easy standards to calibrate with, if your sensor is rated to the two temp values.

 Other then that it's a "Man with one watch always knows the time, man with two watches never quite sure" situation.  smiley-grin

Lefty

10811  Community / Exhibition / Gallery / Re: RC helicopter UAS on: April 16, 2011, 01:43:38 pm
LOL, watch those fingers !!!!

Lefty
10812  Development / Other Software Development / Re: Arduino PID Library: Out of Beta on: April 16, 2011, 01:31:08 pm
It's almost as bad as things like 'proper time'... but I can live with DIRECT - makes sure people read your documentation smiley

I'll let you know if I find any actual issues with it rather than me nitpicking smiley-wink

Having worked in the process control industry I can state that the concept of direct/reverse acting controller can be hard for newcomers to grasp at first. An example might be a simple level controller for a vessel where there is a pump forcing liquid into a vessel and a PID controller reading the level and manipulating a control valve to keep the vessel level at a fixed level. Now depending on if the valve is on the inlet side to the vessel or on the outlet of the vessel will dictate with control action one requires, direct or reverse.

 Also control valves come in direct and reverse acting versions and that can also require a flipping of the controller action. In the 'old days' it could be quite confusing to see one valve that would move to full open with 100% output and another valve that would move to fully closed with 100% controller output. Most control valves in industrial service have a 'fail safe' requirement defined by the process engineers for each specific control valve in the plant that would determine which way a pnumatic valve would move with a loss of all control power via internal spring force. Modern computer process control systems have kind of eleminated the confusion for the control operators such that it's always clear on the computer screen what the position of a control valve is regardless of it's control action. But of course the complexity is still where, just transfeered to the control system engineers to configure each controller properly.

Lefty
10813  Using Arduino / General Electronics / Re: simple/reliable 48 channel relay? on: April 16, 2011, 01:10:21 pm
Depending on the voltage and current values of the wiring being switched it might be difficult to define a pure electronics method that might be quite complex.

At the refinery I use to work at we used a lot of multipole T-bar relays (we used the 48 SPDT versions) for complex switching requirements. These relays are pretty expensive as I recall (> $100 ?) but perhaps avalible on e-bay as new old stock at bargain prices maybe.

http://www.tbarrelay.com/env-sealed-relay.html

Lefty
10814  Using Arduino / General Electronics / Re: Does an OUTPUT require a Pull Down resistor ? on: April 16, 2011, 01:03:20 pm
Quote
And now for some trivia.  If I remember correctly the term 'tri-state' is specific to one manufacturer and the correct generic term is 'three-state' (I may have this backwards).  This is not unlike the current situation with 'I2C' and 'TWI'.

Like Scotch tape and adhesive tape.  smiley-grin

Lefty
10815  Using Arduino / General Electronics / Re: i have good sky relay! RW-SS-112D but don't know how to connect it!! on: April 16, 2011, 01:06:17 am
Not sure I understand all your asking for, but here is a datasheet for the relay number you gave. It shows the wiring pinout at the bottom of the document:

http://www.rapidonline.com/netalogue/specs/60-4660e.pdf

Lefty
Pages: 1 ... 719 720 [721] 722 723 ... 1169