knightridar:
The INA219 can only be used up to a maximum of 4 sensors because of the way it's setup and it uses the SDA and SCL ports on the arduino.
Not true.
You can use as many of these as you need on the same bus, if you solder a wire to one address field.
You can then use that wire as chip select.
A 30A sensor (30A bidirectional = 60Amp) has a resolution of ~13.5 steps per Amp, or one step per 75mA.
Just enough for one decimal place.
Leo..
I2C is a bus. Many devices can connect to the same two wires, as long as they have a unique address.
Selecting one chip, and ignoring others.
The INA219 has four user selectable addresses (the solder links).
So normally up to four of these modules can be connected to the same bus.
But... if you control one of those solder links with an Arduino pin, you can change the address with software.
Talk to one module two modules, and ignore the others (that have been set to a different address).
Leo..
If I am not mistaken, only 1 device at a time can talk to the I2C bus?
Want to know because I need to turn the relays on/off simultaneously.
Also even if i can change the address,
I need to measure the current going out to 8 solenoids simultaneously.
So are you saying I can connect 8 modules and give them all different addresses?
I was confused with the 2 modules comment.
If I use two and assign different addresses via the pin, then I can get 8 different addresses?
Will they be unique?
Only issue is if I change them via the pin on an Arduino I won't be able to detect current simultaneously for 8 relays. That connection is a fixed hardware interface on the INA219 is it not?
knightridar:
I need to measure the current going out to 8 solenoids simultaneously.
So are you saying I can connect 8 modules and give them all different addresses?
I was confused with the 2 modules comment.
Everything in a single core processor happens after each other.
Don't know what you are going to measure,
but the INA219 can only measure loads <26volt and grounded to the Arduino.
Be careful with PWM-ed loads. They will give false readings, since current will be 0% or 100% at different times.
Since you have four addresses available, you can connect modules in pairs.
e.g. address 0x40 and 0x41 active, and the other sets on 0x44 and 0x45.
Leo..
I don't need to make the cycle times that fast.
I was just trying to make them fast to speed up my testing process and times.
Goal is to do cyclic testing of solenoids.
I was thinking of using solid state relays. I did find one:
Problem was I wasn't sure about what I kind of DC loads it's capable of taking.
With the current relays it's written on top of them with respect to what amperage and dc/ac voltage they can take in.
Current relay part no. Songle SRD-05VDC-SL-C
knightridar:
Goal is to do cyclic testing of solenoids.
Problem was I wasn't sure about what I kind of DC loads it's capable of taking.
With the current relays it's written on top of them with respect to what amperage and dc/ac voltage they can take in.
My solenoids' voltage range is 12-24V, and a few at run at 115V AC..
If I end up using that sensor then I will pair the modules,
but I would have preferred to measure 8 separate currents.
The current of the actual coil?
Those relays are AC only. This is in the specs list:
"Load voltage range: 75 to 264VAC (50/60Hz)"
Just measure coil resistance. With ohms law you can calculate DC coil current.
Tricky with AC, because of coil inductance. Need to measure AC voltage too.
The INA219 can't do mains connected 115volt AC, and 24volt is borderline.
Seems you need to go back to the ACS712 (5A version).
measure 1, measure 2, switch to the next set, measure 3, measure 4, switch to the next set, etc..
Leo..
What does the picture below mean in terms of the DC voltage it can support?
These relays are pretty common in a lot of the modules being sold (i.e. single relay, 2,4,6,8)
I am supplying load to 24V solenoids right now.
Perhaps the documentation I provided is inaccurate?