Using Arduino to control 74HC595 not CD40110BE in cascade using SPI.

I need and will build a circuit to control an Inductive device at 60 cycles per second which will have 46 taps that will mimic a brush rotating at 3600 RPM. 1 second= 1000 ms divided by 60 RPS = 16.66 ms per revolution which divided by 46 taps = .352 ms = 352 microseconds of on time per tap. what i can not come up with is how to code an Arduino to switch a CD40110BE to pulse up then down at the right time. i channel to pulse up and one channel to pulse down plus ground.

i attached the circuit but didn't figure out how to post it in the post.

marathonMAN1:
i attached the circuit but didn't figure out how to post it in the post.

That's OK. Easy enough. :grinning:
CD40110BE Cascade Circuit.jpg
Click to expand.

Thank you much.
what i was thinking is the Arduino even fast enough to trigger the duel inputs at microseconds of time... i think not, what else can i do?

Hi,

Please read the first post in any forum entitled how to use this forum.
http://forum.arduino.cc/index.php/topic,148850.0.html .

Can you post the code that you have now please?

Thanks.. Tom.. :slight_smile:

The clock interval of the Arduino is 62.5 nanoseconds.

What do you mean by "fast enough to trigger the duel inputs".

Are you just trying to walk one bit across all the outputs ?
If that’s the case, you may find it easier to use shift-registers (like the venerable 74xx595 family.

You create your bit pattern in an array, then pump it out each time you want change the register output bits.
For ‘up’ counts, that’s as easy as ticking one bit at a time, for ‘down’ counts, either a bidirectional SR, or simply shift the long contents, and push that out to the 595s.

Mr Tom i did and i am still short on what you mean.

as for the code i haven't attempted because of the confusion on my part. the circuit will drive an IGBT/Transistor driver that is 3.3 and 5 volt tolerant so that is one less problem.

"Are you just trying to walk one bit across all the outputs ?"
yes i am but the channels have to be a make before break scenario. meaning one is fully on before the other shuts off. reason is no current interruption so no back emf.
i never thought about that shift register implementation. another thing is the ends of the controller has to be on for three times as long then the ones in the middle to get an Inductive roll off in my controller.
sounds confusing but it is not just need the proper switching and coding and am good to go.
Thank you all for the time and effort.
I think i brain farted on the frequency timing.

With the make-before-break timing, you’re good with simple shift registers.

Form your bit pattern: all_off-1-12-2-23-3-34-4 etc in the shift register, pump it out, then at the moment, pulse the SR output latch. Rinse and repeat while the SR outputs are latched in the current state.

Hi,

Can you clarify exactly what we are working on here?

Title; Using Arduino to Control CD40110BE up down clock.

First line; "I need and will build a circuit to control an Inductive device at 60 cycles per second which will have 46 taps that will mimic a brush rotating at 3600 RPM."

How are they connected?
What is the application?

Tom..... :o

i will have taps coming off the inductor 46 of them that are connected to an IGBT and drivers that is connected to the above circuit or a shift register. it must be make before break scenario meaning the next in line is fully up before the last one cuts off. this is to ensure a steady current flow through the Inductor.

on each end of the Inductor i have electromagnets that are varied from high to low 180 degrees out from each other, one rising, one falling at the same time. the electronics is to mimic a brush rotating in a circle that make contact with two contacts at a time which are actual loops of wire around the Inductor that changes the magnetic flux to current ratio on a steady basis.

for the 40110be it will have two inputs to the arduino but for the shift register i need to calculate how many inputs i will have.

lastchancename; got any ideas on a cheap shift register.
i am at a loss when coming up with a program to control the two inputs to the up and down pins on the 49110be.

The CD40110B is NOT a shift register. It's a decade counter (0-9) with 7-segment display outputs.

Unless your "Inductive device" is a 7-segment display you are NOT going to have much luck driving it with a 7-segment driver. What made you think this counter/driver was suitable for your device?!?

I suspect the OP meant to use CD4017 decade counter but got seriously confused at some point.

it must be make before break scenario

Does CD4017/40110 guarantee that? I don't know...

I too would suggest 6 x 74hc595. Connect these to the SPI pins of the Arduino so they can be updated at high speed (8MHz clock). Then you can guarantee make-before-break by sending the required patterns of bits in your sketch. But will even that be fast enough?

Another option could be a Mega. 46 pins could be updated at high speed using direct port manipulation.

i am at a loss when coming up with a program to control the two inputs to the up and down pins on the 49110be.

While not complicated (yet), it sounds like you may be better off moving this thread to Gigs & Collaborations, where someone can work with you to develop a solution.

Depending on your expectations, and the helper, it could require payment.

The problem with using CD4017 counters is trying to cascade them. Like the CD40110, each chip represents one digit. You get one output per chip. To count off 46 outputs you have to AND the 10 "ones digit" outputs with each of the first five of the "tens digit" outputs. That's 47 2-input AND gates you need... and a LOT of wiring. You could then count from 00 to 46 and reset at 47.

If you want a moving bit, the shift registers (68 or 316) will eliminate the need for 47 AND gates.

marathonMAN1:
i will have taps coming off the inductor 46 of them that are connected to an IGBT and drivers that is connected to the above circuit or a shift register. it must be make before break scenario meaning the next in line is fully up before the last one cuts off. this is to ensure a steady current flow through the Inductor.

on each end of the Inductor i have electromagnets that are varied from high to low 180 degrees out from each other, one rising, one falling at the same time. the electronics is to mimic a brush rotating in a circle that make contact with two contacts at a time which are actual loops of wire around the Inductor that changes the magnetic flux to current ratio on a steady basis.

So 46 taps on EACH inductor.
Each tap has an IGBT on it?
So you will have your inductor connected to a powersupply at the start of its winding and with IGBTs connect each tap in turn with the other end of the powersupply?
What voltage/current and how is your inductor constructed?
How many inductors?
Can you post a basic diagram of how your project will be constructed?
Thanks.. Tom.. :slight_smile:

I thought the CD40110B will work because it has an count up/down, cascade features that allows it to count up which changes the tap position on the inductor which changes the inductance of both side of the inductor. then count down using the very same tapes to change the inductance the other way. all the taps are on the same inductor and since it is the positive side and two are on at a time there will be two north face magnetic fields at the two taps that are constantly moving. what this does is separate the one big inductor in two halves with one side increasing in current and the other side reducing in current in complete unison which is simple physics.

the pic below is the taps on the inductor which does not show all 46 taps for space reasons. the taps are positive side taps and at the bottom after the electromagnets is the negative side connection.

all this circuit does is vary the current through the two end feed connection of the inductor that mimic a brush rotating in a circle but change the inductor tap locations instead which causes Inductive reactance ie a current change of both feeds on either end of the inductor.
all i need to do is figure out how the timing of the two signal wires to the Arduino one being up and the other down plus ground, will be. for one revolution of a rotating brush will be 16.66 ms so that time has to be divided by 48 because one of the end channels are switched twice because of the up then down switching. this is good because that is what i need it to be.
each tap is on for .347 ms each which is divided by 48 channels of which will equal 16.666 ms of one revolution. does that mean a CD40110 b will not work and i am forced to use a cascade shift register. here i thought it will count up then down like it says in the Instructions.

i hope you can understand this with the help of the pic.

CD4017 does not do what you think it does, not what you want. You must have misinterpreted the "instructions" (data sheet?)

Shift registers (74hc595) will do what you want. 4 Arduino pins will be needed for clock, data, latch and output enable (to ensure break-before-make).

How much current will be flowing? If less than 150mA, maybe tpic6b595 could be used instead, removing the need for igbts.

johnwasser and PaulRB you are completely correct, i totally misunderstood the function of the CD40110. so i did some further research and both of you are correct in your assumptions that i need to use the 74HC595 in cascade fashion. fantastic chip and a perfect fit for this project, THANK YOU BOTH.

i can then cascade (6) 74HC595's to get my needed 46 channels timing them up then down.

PaulRB; that is make before break which is the leading channel on before the lagging one shuts off. also i will be using 1.4 amps peak of current @ 100 plus volts DC through the transistor. i might want to switch to a logic level NPN to switch a high power PNP to make it easy on me instead of having to use high side drivers.

i am working on the timing circuit right now using the 74HC595 in a sop 16 package that i will have connected to a Tensy 3.6. it is on a Tall Dog break out board but i can take that off and mount it to my timing board.

then comes the fun part of coding.

Arduino community is awesome, thanks guy for all the help.

that is make before break which is the leading channel on before the lagging one shuts off.

Ah, sorry. In that case, don't bother with an Arduino pin for Output Enable, just tie it to ground. You will need to send data to the shift registers at twice the anticipated rate, so be sure to use hardware SPI pins for speed.

i might want to switch to a logic level NPN to switch a high power PNP to make it easy on me instead of having to use high side drivers.

Sounds like you are confused about types of transistors. NPN & PNP are BJT transistors, switched by current not voltage, so there is no such thing as a "logic-level NPN", they are all logic level. I suspect you meant to say logic level n-channel mosfet. But if you are switching high-side, is a p-channel MOSFET you want. You could control the p-channel MOSFET's gate with an npn bjt. If you do that, consider the tpic chip again. That would save you 46 npn-transistors, because the tpic chips could drive the p-channel MOSFET gates directly.

Checking your diagram again, I don't think you do want high-side switching or p-channel MOSFETs or PNP BJTs. You want logic-level n-channel MOSFETs, which you can directly control with 74hc595 outputs.