Show Posts
Pages: [1] 2
1  Using Arduino / Motors, Mechanics, and Power / Re: my first big project - BMS - is it possible? on: October 24, 2011, 11:58:17 am
ok, lets see if I got this right;

This chip turns 4 arduino outputs into 16 outputs on the chip, by combining different high/low inputs on the chip (4X4 combo's=16), right?

are these outputs strong enough to open/close small relays without an additional power source? I looked at the datasheet again, but there are just too many damn numbers smiley

2  Using Arduino / Motors, Mechanics, and Power / Re: my first big project - BMS - is it possible? on: October 24, 2011, 05:01:38 am
I looked at the datasheet of the 4514 decoder chip  http://media.digikey.com/pdf/Data%20Sheets/Fairchild%20PDFs/CD4514BC_4515BC.pdf
but it's too technical for me.
is this chip to replace the MAX chip, or what?
can you explain a little?
3  Using Arduino / Motors, Mechanics, and Power / Re: my first big project - BMS - is it possible? on: October 24, 2011, 03:56:53 am
Thanks for the advice.
I understand the concern, and it s certainly something Ill remember.
I could incorporate a check if voltage ==0 after opening the last and before closing the next relay.

For security reasons, i plan to test the system on a much smaller 20 cell nimh pack.

I have no idea what the 4514 decoder chip is/can do, but Ill look in to it.
4  Using Arduino / Motors, Mechanics, and Power / Re: my first big project - BMS - is it possible? on: October 24, 2011, 02:51:40 am
I have no idea how to instruct the MAX chip through the arduino, but I bet I'll find out.
haven't done much thinking about the programming yet, but it seems pretty straightforward to me;
open relay one
read voltage one
close relay one
(probably) delay (very short, to stabilize)
next relay and so on
compare voltages
report somehow


5  Using Arduino / Motors, Mechanics, and Power / Re: my first big project - BMS - is it possible? on: October 24, 2011, 02:27:01 am
This is the system I was discussing.
The MAX6921 might be used, or the other demux chips discussed above.
Note how each battery is connected to nothing until a relay is closed.
A change is needed in the the Gnd for the battery WOULD NOT the GND for the Arduino, demux, & relay coils.
The two would be isolated so that the measuring electronics only connect to the battery under measurement +/- terminals.


I've been learning/reading some more, and after rereading this, this is what I think I can make of it:
The MAX6921 could be used just to directly control up to 20 relays that each isolate 1 cell and feedback its voltage to the arduino.
both circuits are completely separated, so no common ground.
The way this circuit is drawn, it seems like there wouldn't even need to be transistors or resistances around the MAX chip to control the relays, is that right?
are the outputs of the MAX chips (I think 40ma) enough to close a relay?   

grtz
T
6  Using Arduino / Displays / Re: standard 16*2 standard LCD - flipping - messed up characters on: October 08, 2011, 12:51:00 am
yes flippin = misbehaving (it's mostly be total jibberish, and sometimes I can still read some intended data through it))

that cable is an old style 40 lead IDE cable.
It was added later to see if anything would change if I stretched it, but alas :-)

I've also tried an other LCD, that's not it either.
7  Using Arduino / Displays / Re: standard 16*2 standard LCD - flipping - messed up characters on: October 07, 2011, 12:08:39 pm
exactly!

that's why Im so desperate smiley

I am, as said before, a novice, but I do understand the basics of electricity, relays, arduino, resistors, transistors.
so I think it's wired up the right way.

I don't know a lot about capacitors yet though...
I tried adding capacitors here and there, but it's more guessing than knowledge I guess.

could it just be that the 220v is embedded close to the arduino (on the same "shield", at the business end of the relays)??? I don't know!

here's a quick picture of the pcb if that's any help.



as (I hope) you can see, I damaged the copper fill to Isolate extra, but it didn't work.

again, as long as 220v is off, no problem. When I activate it, most of the time the LCD flips, and if it doesn't, it certainly will when any relay switches off after a cycle.

I guess I'll have to rebuild the thing on a breadboard and see if it persists. If it does, it isn't a hidden fault on the pcb.

8  Using Arduino / Displays / Re: standard 16*2 standard LCD - flipping - messed up characters on: October 07, 2011, 12:19:15 am
Liudr, thats exactly the kind of interference I think is messing with my project.

floresta, 220v goes to solenoid valves. The kind you would probably commonly find in dish washers.
(edit) the problem even occurs when I just turn the 220V ON, not only when the valves activate.
Dirk
9  Using Arduino / Displays / Re: standard 16*2 standard LCD - flipping - messed up characters on: October 06, 2011, 03:45:51 pm
no, I didn't. the only connection between the 220 and the rest of the electronics, would be air, polyester (pcb) and the relays, wich are all intended to be isolating, of course.

I designed the PCB with fritzing, and used a copper fill on the board, so I tought maybe the "220v spark interference" travelled through it, and thus I even tried separating the two areas on the PCB by destroying that copper fill at strategic places.

I also tried to use a higher voltage power supply to the arduino (used 5,5v at first - changed it to 7,5v) , because I thought the relays drew too much power (they're on the same supply), but it didn't help either. It's really when 220v comes in to play that trouble begins.

I haven't tried separating the relays from the pcb to get the source of interference fysically further away from the arduino and display processors. Maybe I should?

I'm thinking I'll have to look for maybe 12 or 24vdc valves. but I bet they'll cost a lot more than the 3€/valve I pay now. since this device should be producable at relatively low cost when working fine, I'm trying to avoid that.
It could mean, though, that I could get rid of the relays all together..
 
I'm talking to myself at the moment, because I still hope someone has an "aha" moment smiley
10  Using Arduino / Displays / standard 16*2 standard LCD - flipping - messed up characters on: October 06, 2011, 10:39:02 am
hi all,

I turn to this forum, because I'm really desperate.
Natively, I speak dutch, so don't mind poor language please.

I am a novice, by the way, I'm learning as I go. After having played around with some basic Arduino stuff, I decided I'd have a go at something a little more advanced.

The image below is a pretty accurate reproduction of my first test-layout-on-a-breadboard . I worked fine then. It simply measures analog stuff and switches relays (to open some 220 v (low current) valves.) The LCD displays the analog values.


(sorry for the type of image, I think this is clearer than a schema I could make)

It was until I made a PCB of it, that problems began. More specificly, I discovered that it still worked fine UNTIL I connect 220v to the relay contacts. The display flips almost every time I do that, and if it doesn't, it'll flip almost certainly the first time one of the relays re-open (after having been closed).
I guess that the mini-spark that is generated when adding 220v generates interferance (noise?) with one of the graphics chips on the back of the display.

The arduino still performs it's task, but I can't read the display any more (messed up characters).

It is not a programming fault I think, because it works 100% fine before I connect 220vac.

I searched for similar problems on this forum and some other places, and there seem to be a few examples, but none of the solutions were satisfying to me.

- I tried turning off/on the display after every loop (but once the LCD flips, it doesn't listen to those commands any more)
- I tried adding some capacitors at different places, but the problem persists.

any ideas anyone?

thx Turok





11  Using Arduino / Sensors / Re: multiple analog inputs on: August 07, 2011, 02:51:36 pm
nevermind sorry,

I just spotted my program error
I was reading pin 0 only

thanks anyway

dirk
12  Using Arduino / Sensors / multiple analog inputs on: August 07, 2011, 02:46:57 pm
Hi,

I'm making a beginners mistake I guess smiley



Code:
int pot1 = 0; //sensor 1
int pot2 = 0; //sensor 2
int pot3 = 0; //sensor 3
// Value read from moist sensor
int val1 = 0;
int val2 = 0;
int val3 = 0;


void setup()
{
 
pinMode(9, OUTPUT);
  pinMode(10, OUTPUT);
  pinMode(11, OUTPUT);
  pinMode(12, OUTPUT);
  pinMode(13, OUTPUT);
 
Serial.begin(9600);}

void loop()
{
val1 = analogRead(pot1);
Serial.println(val1,DEC);
delay(10);

val2 = analogRead(pot2);
Serial.println(val2,DEC);
delay(10);

val3 = analogRead(pot3);
Serial.println(val3,DEC);
delay(10);

  if(val2 < 300);
{
 digitalWrite(9, HIGH);
 }
   
  delay(2000);
}

I can read 1 sensor no problem, but when I connect more than one, I always get the value of 1 sensor, but my serial monitor gives me 3 exact the same values (the value of the one sensor it read before)

I think it's the way I wired it... isn't it?

dirk
13  Using Arduino / Programming Questions / Re: servo comfortable position on: July 30, 2011, 01:02:45 pm
bingo!
found it,

the position of "Val = oldval" was wrong.

put it later in the code, so that the value also changed when the "if" was false!

Thanx a million Paul!
14  Using Arduino / Programming Questions / Re: servo comfortable position on: July 30, 2011, 10:41:17 am
@Paul

thanks for the patience with a novice like me smiley

but alas, it doesn't cut it.

I'm suspecting that the oldval voids at the start of every loop or something.
It must be something stupid like that.


@ erni, there is almost no pressure involved, the "step back to rest position" solution works, it's just my programming that sucks :-)

I've figured out "sort of" a lazymans-solution;
If I set the final delay at one minute, it's not so annoying any more smiley
but nevertheless I'd still be very happy not having to do it like that.
15  Using Arduino / Programming Questions / Re: servo comfortable position on: July 30, 2011, 10:02:13 am

ok, here's the whole thing:
Val is a quite stable moist reading

Code:
#include <Servo.h>
Servo myservo;
int ldrPin = 0;
// Value read from moist sensor
int Val = 0;
int oldval = 0;

void setup()
{
  myservo.attach(4);

Serial.begin(9600);}
void loop()
{
Val = analogRead(ldrPin);
Serial.println(Val,DEC);



  if(Val > 300)
{
   if(Val < oldval - 100 || Val > oldval + 100);
   {
 myservo.write (100);    // Move the servo
 
  delay(100);
 
   myservo.write (95);  // Rest the servo
     oldval = Val;
   }
}
 
   else myservo.write (5);
   
 delay(1000);

but the servo isn't resting; now it sings shortly every second now. (going from (100) to (95) again and again)
Pages: [1] 2