My Digital Tachometer - putting it all together

192 posts / 0 new

Pages

aeroHAWK wrote:
I will receive the PCBs on Monday. So right now, I'm stuck at calculating the current-set resistors for the PCA9922s. I've scoured the datasheet and cannot find ANYTHING! :shock: It's not a very good data sheet. :?
Quote:
Current controlled outputs (LED[7:0])
```////////////////////////////////////////////////////////////////////////////////
Symbol Parameter                  Conditions                  Min  Typ  Max Unit
Iol    LOW-level output current   VO = 0.7 V; Rext = 910 Î©   17.5 19.5 21.7 mA
VO = 0.7 V; Rext = 470 Î©   35.4 38.1 40.8 mA```

Voltage across Rext is likely to be constant, so Rext * Iol should be constant:
```910 * 0.0195 = 17.745
470 * 0.0381 = 17.907```

Seems to be close, within 2% of 18. So we can derive a formula:

```Rext * Iol = 18
Rext = 18/Iol```

So if you wanted a 60 mA output:

```Rext = 18/0.060
= 300 ohms```

JJ

 "Experience is what enables you to recognise a mistake the second time you make it." "Good judgement comes from experience.  Experience comes from bad judgement." "Wisdom is always wont to arrive late, and to be a little approximate on first possession." "When you hear hoofbeats, think horses, not unicorns." "Fast.  Cheap.  Good.  Pick two." "We see a lot of arses on handlebars around here." - [J Ekdahl]

joeymorin wrote:
So if you wanted a 60 mA output:
```Rext = 18/0.060
= 300 ohms```

THANKS JJ! That is the only thing I could think of doing to get a value, but I knew it involved making assumptions I wasn't sure about. :?

Cris

Perfection is achieved, not when there is nothing more to add, but when there is nothing left to take away. Antoine de Saint-Exupery (1900 - 1944)

Above, I wrote:
I will receive the PCBs on Monday.
I use ExpressPCB for my circuit boards. It takes them three business days to make 4 layer boards then UPS second day is another two. So I expected the boards on Monday, but they came yesterday instead! :D UPS used only one day to get them to me.

ExpressPCB has an inexpensive service that requires the boards to be 2.5 x 3.8 inches. I then cut them to the appropriate size and shape on my CNC.

This photo shows the boards as made by ExpressPCB and the boards after I cut them out. The two at the top are as received (front and back), and the bottom three are what I cut. You can see the bar graph laid out on the one on the left and the 7 segment display board on the right. The small board is for IR sensors for the opto-interrupter (if I decide to go that way).

I have also been working on the enclosure. In this photo you see the bezel, engraved face, LED diffuser, and tinted lens/window, along with the PC boards.

The next order of business is to populate the 7 segment display board and get the displays working... :wink:

Cris

Perfection is achieved, not when there is nothing more to add, but when there is nothing left to take away. Antoine de Saint-Exupery (1900 - 1944)

Looks fantastic!

 "Experience is what enables you to recognise a mistake the second time you make it." "Good judgement comes from experience.  Experience comes from bad judgement." "Wisdom is always wont to arrive late, and to be a little approximate on first possession." "When you hear hoofbeats, think horses, not unicorns." "Fast.  Cheap.  Good.  Pick two." "We see a lot of arses on handlebars around here." - [J Ekdahl]

joeymorin wrote:
Looks fantastic!
THANKS JJ! :wink: I'm quite happy with how everything is coming together.

I populated the 7 segment display board. Here is what it looks like - front and back:

And of course you can't hide from Murphy.... :? I have some minor interference between the crystal and the place where the ISP header goes (lower right). :cry: I'll need to extent the header to be a little taller. Hopefully it will not interfere with the housing.

I also started populating the bar graph PCB. I found that the yellow LEDs that I have claim to be amber, but they are somewhere between orange and red. :? I'll need to get some that are really yellow.

Cris

Perfection is achieved, not when there is nothing more to add, but when there is nothing left to take away. Antoine de Saint-Exupery (1900 - 1944)

aeroHAWK wrote:
And of course you can't hide from Murphy.... :? I have some minor interference between the crystal and the place where the ISP header goes (lower right). :cry: I'll need to extent the header to be a little taller. Hopefully it will not interfere with the housing.
Would simply shaving a bit off the header's plastic separator solve the problem?... or is it that the connector on the end of the programming cable interferes, too?

Perhaps if you used a female header like this one, then use a male-male 'gender bender' made out of a long-pin male header like this one, with the separator pushed in to the centre of the pins.

I've used a similar setup to program an Arduino Pro Mini with a 6x1 female header like this one contact-soldered (i.e not using the pins in the through-holes). A 6x1 long-pin male header was used to connect it to an FTDI breakout for programming.

In my case, the advantage was that I got reliable programming without having exposed pins on the Pro Mini when in use.

JJ

 "Experience is what enables you to recognise a mistake the second time you make it." "Good judgement comes from experience.  Experience comes from bad judgement." "Wisdom is always wont to arrive late, and to be a little approximate on first possession." "When you hear hoofbeats, think horses, not unicorns." "Fast.  Cheap.  Good.  Pick two." "We see a lot of arses on handlebars around here." - [J Ekdahl]

joeymorin wrote:
Perhaps if you used a female header like this one, then use a male-male 'gender bender' made out of a long-pin male header
Thanks JJ, that might be a good idea. :wink: I can see some advantages, and I think I already have the parts.

I put the pieces together for a preliminary test fitting. Here is what it looks like, front and back:

Perfection is achieved, not when there is nothing more to add, but when there is nothing left to take away. Antoine de Saint-Exupery (1900 - 1944)

Hi aeroHAWK,

Everything looks great! Very professional.

I use Express PCB too, its a great proto PCB service. Simple to use, great quality.

You might be able to just "lift" the crystal up a bit and bend it away from the header to get enough clearance. Or actually mount it at 90-degrees from your intended position, bending the leads into the holes. ( Be careful not to short its metal case to any of the exposed traces or pads - maybe a piece of mylar tape. )

If your airplane has any degree of vibration (like most I am familiar with), you will want to reinforce those "oil tank" capacitors and the crystal with some RTV "potting". These capacitors have a lot of "sprung mass" - i.e. their weight is relatively high in comparison to their soldered lead area. These leads, or their solder joints, will eventually fracture from longterm vibration stress in an aircraft environment. It is common practice these days to "goop" non-SMD components on PCBs that are to be used in "rugged service" applications. Aircraft use is a typcial example of"rugged service". Of course you wouldn't do this until the unit is completely debugged, tested and ready for final, long term installation in the aircraft.

The typical gooping technique is to load the RTV into a hypodermic syringe (without the needle) and squeeze it carefully where needed on the board to achieve the desired degree of sturdiness without completely obliterating the remaining components. Hobby stores carry various types of disposable non-medical syringes which are designed for this type of precise glue and sealing work.

Let the programming commence!

I really love how this thread has gone through earlier stages to something being a complete implementation.

And I am quite impressed by what you do with your CNC some metal and epoxy! In the latest photos of TRT (The Real Thing) it looks like it was just pulled out of a commercial packaging. I can imagine how nice your cocpit will look with a series of home-made instruments, all as meticulously crafted as the one above!

Congratulations, and I really hope it will fly! Open those hangar doors!

As of January 15, 2018, Site fix-up work has begun! Now do your part and report any bugs or deficiencies here

No guarantees, but if we don't report problems they won't get much of  a chance to be fixed! Details/discussions at link given just above.

"Some questions have no answers."[C Baird] "There comes a point where the spoon-feeding has to stop and the independent thinking has to start." [C Lawson] "There are always ways to disagree, without being disagreeable."[E Weddington] "Words represent concepts. Use the wrong words, communicate the wrong concept." [J Morin] "Persistence only goes so far if you set yourself up for failure." [Kartman]

The photo-op on top of the PCB CAD drawings is a nice touch ;)

 "Experience is what enables you to recognise a mistake the second time you make it." "Good judgement comes from experience.  Experience comes from bad judgement." "Wisdom is always wont to arrive late, and to be a little approximate on first possession." "When you hear hoofbeats, think horses, not unicorns." "Fast.  Cheap.  Good.  Pick two." "We see a lot of arses on handlebars around here." - [J Ekdahl]

Chuck-Rowst wrote:
Everything looks great! Very professional.
JohanEkdahl wrote:
it looks like it was just pulled out of a commercial packaging.
Thanks Chuck and Johan. It's always great to get nice feedback. :wink:
joeymorin wrote:
The photo-op on top of the PCB CAD drawings is a nice touch ;)
Thanks JJ, it seems you notice some of the subtle things... (did you see I had a 7 segment display upside down...). :wink:
Above, I wrote:
I have some minor interference between the crystal and the place where the ISP header goes
As it turns out, the interference is less than I originally thought. All I need to do is raise the header 1/64th inch (.4 mm) from the board when soldering. The crystal will then be below the connector.
Chuck-Rowst wrote:
If your airplane has any degree of vibration (like most I am familiar with), you will want to reinforce those "oil tank" capacitors and the crystal with some RTV "potting".
Thanks for reminding me Chuck. I hadn't thought about that yet. I am familiar with the practice. Although one of the touted advantages with using a Corvair engine in an airplane is its smoothness. :wink: It will be nice, since airplanes usually shake like crazy. :shock:
Chuck-Rowst wrote:
Let the programming commence!
YEP! That's what's next! :D A few loose ends on the mechanical stuff and then programming....

Perfection is achieved, not when there is nothing more to add, but when there is nothing left to take away. Antoine de Saint-Exupery (1900 - 1944)

Last Edited: Mon. Sep 30, 2013 - 04:59 PM

aeroHAWK wrote:
joeymorin wrote:
The photo-op on top of the PCB CAD drawings is a nice touch ;)
Thanks JJ, it seems you notice some of the subtle things...
Sometimes...
Quote:
(did you see I had a 7 segment display upside down...). :wink:
Not this time! I see it now. I was going to ask if that was a design feature, but I can see from the traces on the backside that it's not.

I hope you didn't have too much trouble fixing it!

JJ

 "Experience is what enables you to recognise a mistake the second time you make it." "Good judgement comes from experience.  Experience comes from bad judgement." "Wisdom is always wont to arrive late, and to be a little approximate on first possession." "When you hear hoofbeats, think horses, not unicorns." "Fast.  Cheap.  Good.  Pick two." "We see a lot of arses on handlebars around here." - [J Ekdahl]

joeymorin wrote:
I hope you didn't have too much trouble fixing it!
The displays were not soldered in place for the photo - I just dropped them into the holes to take the picture. I need to carefully stand them a specific distance above the PCB to have them protrude properly to the front. So no... no problem fixing it, since they still are not soldered yet. :wink:

Cris

Perfection is achieved, not when there is nothing more to add, but when there is nothing left to take away. Antoine de Saint-Exupery (1900 - 1944)

:shock: :evil: :twisted: AAHHRGG!!! :twisted: :evil: :shock:

Murphy strikes again! :? :shock: Well maybe it was really me.... :cry: :oops:

When I did the PCB layout, I forgot that I will be plugging in the ISP from the BACK of the board. So the layout is a mirror image of what I need. :cry:

I suppose I can use the front of the board for now (while I am only programming the 7 segment displays), but I'll probably have to make an adapter for when the two PCBs are stacked together.... :(

Cris

Perfection is achieved, not when there is nothing more to add, but when there is nothing left to take away. Antoine de Saint-Exupery (1900 - 1944)

aeroHAWK wrote:
I suppose I can use the front of the board for now (while I am only programming the 7 segment displays), but I'll probably have to make an adapter for when the two PCBs are stacked together.... :(
It looks like there's enough clearance for a right-angle header. This one is a 3x2, which is a bit taller than this 2x3.

JJ

 "Experience is what enables you to recognise a mistake the second time you make it." "Good judgement comes from experience.  Experience comes from bad judgement." "Wisdom is always wont to arrive late, and to be a little approximate on first possession." "When you hear hoofbeats, think horses, not unicorns." "Fast.  Cheap.  Good.  Pick two." "We see a lot of arses on handlebars around here." - [J Ekdahl]

joeymorin wrote:
It looks like there's enough clearance for a right-angle header.
The problem is that the header also takes signals to the other board, so a right angle header won't do the job there. :cry:

Perfection is achieved, not when there is nothing more to add, but when there is nothing left to take away. Antoine de Saint-Exupery (1900 - 1944)

aeroHAWK wrote:
The problem is that the header also takes signals to the other board, so a right angle header won't do the job there. :cry:
Oh, noooo....

Did you invert the header placement on the other board as well? I hope so... and judging from the location of the square pad on both boards, it looks like you did.

I suppose an adapter is in order... probably one that lives outside the unit...

JJ

 "Experience is what enables you to recognise a mistake the second time you make it." "Good judgement comes from experience.  Experience comes from bad judgement." "Wisdom is always wont to arrive late, and to be a little approximate on first possession." "When you hear hoofbeats, think horses, not unicorns." "Fast.  Cheap.  Good.  Pick two." "We see a lot of arses on handlebars around here." - [J Ekdahl]

joeymorin wrote:
I suppose an adapter is in order...
Agreed. :wink:

I do have some good news though.... :) I have successfully loaded a test program and the MAX7219 display appears to work properly! :shock: I'll spend some more time on it, but preliminary tests are working great. :D So the ISP connector is my only layout error so far. :oops:

I ordered some yellow LEDs that should be here in a few days (along with some 15 pf caps for the xtal). I need to solder in the PCA992 LED drivers and add the yellow LEDs. So it looks like I'll be working on the bar graph code real soon! :wink:

Cris

 After further testing, the 7 segment display portion of the circuit is working perfectly! :shock: :D :lol:

Perfection is achieved, not when there is nothing more to add, but when there is nothing left to take away. Antoine de Saint-Exupery (1900 - 1944)

aeroHAWK,

In my several decades experience in this business I have seen very few perfect 1st Pass PCBs. It seems like there is always something missed - either electrical or mechanical. We strive for perfection, but it rarely happens with 1st p ass PCBs. Consider yourself "blessed" that whatever shortcomings you encounter are fixable to some degree or another. And that the first cut PCB will serve a productive purpose in the overall project development. I have seen too many that were completely unusable and had to be scrapped at great expense of money & project time.

Knowing that to be a simple manifestation of human fallability, I never schedule a production-bound project with just one PCB cut. (Unless it's a simple mod of an existing design.)

My advice is to hold off on ordering sencond rev PCBs until you have "pushed" the first rev boards as far as you can with hardware debug, software development, mechanic mods, and all final tests you intend to perform (e.g. temperature testing). In other words, learn as much as you can from the hitched up rev 1 cards, before you spring for the 2nd revs PCBs. It seems a lot of people tend to go off premature on this and end up buying too many intermediate revision PCBs uneccessarily. Mistakes will be made, you don't need to compound them with misplaced impatience.

Chuck-Rowst wrote:
In my several decades experience in this business I have seen very few perfect 1st Pass PCBs.
Yes, I agree. :wink: I have made in the range of 100 PCBs with ExpressPCB over at least a decade or so, I seldom get it 'right' the first time. There seems to always be at least one minor error. :oops:

If I don't find any more errors (or even if I do), I will definitely consider these boards a great success! ExpressPCB's prices and turn around make it so much nicer than the other methods I have used in the past! :wink:

Chuck-Rowst wrote:
hold off on ordering second rev PCBs until you have "pushed" the first rev boards as far as you can
You may have missed it... (I think is was in a previous thread of mine...) but I doubt there will be any more PCBs for this tachometer. I probably won't make any more than this one. If I do, it won't be any more than two more (which is the number of PCBs I already have).

I am not making a product, this is just a one-off for me. There are a lot of 'short cuts' I'm taking that I can get away with since I don't need to be concerned with production. 8)

Cris

Perfection is achieved, not when there is nothing more to add, but when there is nothing left to take away. Antoine de Saint-Exupery (1900 - 1944)

Above I wrote:
A few loose ends on the mechanical stuff and then programming....
Those loose ends are almost done. :wink: The bezel is machined from a block of black Delrin plastic. I don't want to have a problem with stripping screw threads so I made some brass inserts. There are inserts for the four 6-32 mounting screws that hold the gauge in the panel, and there are four 2-56 screws to hold the PCB to the bezel. I also added a small radius on the ID of the bezel....

I like the Torx head design for screw drivers and incorporated a similar shape to capture the inserts. You can see the small screws to hold the PCB here:

This is what the inserts look like:

Perfection is achieved, not when there is nothing more to add, but when there is nothing left to take away. Antoine de Saint-Exupery (1900 - 1944)

Hang on... did you machine those brass inserts yourself? Very nice!

 "Experience is what enables you to recognise a mistake the second time you make it." "Good judgement comes from experience.  Experience comes from bad judgement." "Wisdom is always wont to arrive late, and to be a little approximate on first possession." "When you hear hoofbeats, think horses, not unicorns." "Fast.  Cheap.  Good.  Pick two." "We see a lot of arses on handlebars around here." - [J Ekdahl]

joeymorin wrote:
did you machine those brass inserts yourself?
Yes, but I cheated... :wink: I have a machine shop with some nice machines (it makes it a lot easier).

Perfection is achieved, not when there is nothing more to add, but when there is nothing left to take away. Antoine de Saint-Exupery (1900 - 1944)

Wow!

JC

Now you are just bragging. Why have two Bridgeports? Isn't one enough?

Imagecraft compiler user

bobgardner wrote:
Now you are just bragging. Why have two Bridgeports? Isn't one enough?
One for meat, one for dairy.

 "Experience is what enables you to recognise a mistake the second time you make it." "Good judgement comes from experience.  Experience comes from bad judgement." "Wisdom is always wont to arrive late, and to be a little approximate on first possession." "When you hear hoofbeats, think horses, not unicorns." "Fast.  Cheap.  Good.  Pick two." "We see a lot of arses on handlebars around here." - [J Ekdahl]

bobgardner wrote:
Now you are just bragging. Why have two Bridgeports? Isn't one enough?
If one is good... aren't two better? 8) Yeah... you're right... I'm just bragging. :wink: (I used to have another but I sold it)

The machine on the left (in the back corner) is a Bridgeport Series II and weighs 5000+ lbs. It is a very old N/C (before CNC) machine. It is so old (circa 1975), the controls used REAL TTL discrete logic chips. :shock: I haven't yet converted it to Mach3 and it's partially disassembled. And yes, as JJ says, that's the one for "meat".

The Bridgeport in the back center, is the CNC that I showed in a previous post (above). It is a Series I and is a few years newer. I HAVE converted it to Mach3.

The mill on the right (just past the lathe) is a Bridgeport Series I clone and is a manual machine. That means I actually have to turn cranks to use it.... :shock:

The lathe on the right is a 13" toolroom lathe, and the lathe on the left is an old Logan 10" (like some that were sold by 'monkey ward' back in the day (I inherited it from my grandfather).

Oh, and the green and black mill on the bench is a cheap Chinese benchtop mill (Seig X3) I'm going to convert to CNC for a friend.

Perfection is achieved, not when there is nothing more to add, but when there is nothing left to take away. Antoine de Saint-Exupery (1900 - 1944)

aeroHAWK,

So, which machine is the one you actually used to machine the bezel & inserts? Is it CNC?

When you make mods to the bezel, etc, do you rework an existing one, or simply have the machine run a completely new piece?

Chuck-Rowst wrote:
which machine is the one you actually used to machine the bezel & inserts? Is it CNC?
The bezel was done on the CNC (against the wall in the middle in the photo) and the lathe (far right). All the features of the back were done on CNC, the front 'ring' and flange face were done on the lathe. The lathe makes round things nicer than the CNC (the tool marks are circumferential).

The inserts were done on the CNC, manual mill and lathe. The 'lobes' and round boss were done with CNC, the manual mill was used to slice them off the brass block, and the lathe was used to drill and tap.

Chuck-Rowst wrote:
When you make mods to the bezel, etc, do you rework an existing one, or simply have the machine run a completely new piece?
That would depend on what needs to be done. If it is a matter of removing more material, then a rework is in order. If material needs to be added, well since machining is a removal process, a new one is made.

So far, I haven't needed to make any mods. 8) Computer modelling is a big help in that regard. :wink:

Cris

Perfection is achieved, not when there is nothing more to add, but when there is nothing left to take away. Antoine de Saint-Exupery (1900 - 1944)

Above I wrote:
the yellow LEDs that I have claim to be amber, but they are somewhere between orange and red. :? I'll need to get some that are really yellow.
I got new yellow LEDs yesterday and soldered them in place. This is the bar graph display board:

The yellow LEDs are a different package and are taller:

The taller LEDs need to fit into the diffuser:

So I had to modify the slots to fit the new LEDs.

You can see the second, third, and forth slots (from the left) are now deeper. :wink: Next is to hook up the bargraph PCB with some temporary leads to test all the functions with a test program before it is permanently assembled with the other PCB. Cris

Perfection is achieved, not when there is nothing more to add, but when there is nothing left to take away. Antoine de Saint-Exupery (1900 - 1944)

Last Edited: Thu. Dec 18, 2014 - 07:48 AM

I have been experimenting with the 7 segment display and the MAX7219. The chip is getting really HOT, so I re-read the data sheet to make sure I selected the proper Rset value.

The data sheet does not make sense.... On page 10, it says:

`The current per segment is approximately 100 times the current in ISET. To select RSET, see Table 11.`

QUESTION:
If the MAX7219 is a current source, why would it care about the LED forward voltage?

I would guess that Rset is part of a feedback loop, so it should also have no correlation to the LED.

On top of all that, if I want 10mA with a 1.5 V forward voltage, the table indicates 66.7 ohms. At least that is how I read it. :? I have an old project from the early '90s that has MAX7219s so I looked to see what it used.... It's 10K! :shock:

Does anybody know what is REALLY going on with MAX7219s? :?

Cris

Attachment(s):

Perfection is achieved, not when there is nothing more to add, but when there is nothing left to take away. Antoine de Saint-Exupery (1900 - 1944)

aeroHAWK wrote:

The data sheet does not make sense.... On page 10, it says:
`The current per segment is approximately 100 times the current in ISET. To select RSET, see Table 11.`

QUESTION:
If the MAX7219 is a current source, why would it care about the LED forward voltage?

I would guess that Rset is part of a feedback loop, so it should also have no correlation to the LED.

What I think happens is that some current flows from +5V through Rset into ISET, then to the base of an internal NPN that controls the segment current. The base of that NPN is about 0.7V above the LED voltage drop, so the current flowing through Rset depends on that voltage drop.

Quote:

On top of all that, if I want 10mA with a 1.5 V forward voltage, the table indicates 66.7 ohms. At least that is how I read it. :? I have an old project from the early '90s that has MAX7219s so I looked to see what it used.... It's 10K!

It should be 66.7 kohms for 10mA. No wonder your max7219 is getting hot!

- S

mnehpets wrote:
It should be 66.7 kohms for 10mA.
I did some experimenting. I installed a 5k resistor, a 10k and a 20k resistor and checked the voltage drop of each resistor. With the 5k, the voltage across the resistor was 3.25 V, with the 10K it was 3.55 V, with 20k it was 3.82 V.

According to Ohm, current with the 5k is .65 mA, 10k is .36 mA, and 20k is .19mA. So then the LED current is supposedly 100 times that, or 65 mA, 36 mA, and 19 mA, respectively.

This still seems to have little correlation with Table 11. :shock:

 I am shooting for 15 mA nominal, so I used a 33.2k and 100k in parallel (since I don't have many values in my stock - it comes to 24.9k) and that calculates to 15.9 mA to the LEDs. :wink:

Perfection is achieved, not when there is nothing more to add, but when there is nothing left to take away. Antoine de Saint-Exupery (1900 - 1944)

aeroHAWK wrote:
QUESTION: If the MAX7219 is a current source, why would it care about the LED forward voltage?
The datasheet makes no mention of a constant current source. Neverthess, the relationship between Rset and segment current is relatively flat across a wide range of LED Vf. Looking just at the first row of the table, Rset ranges between 9K69 and 12K2, a ratio of about 4:5 (80%), over a range of Vf spanning 1.5V to 3.5V, a ratio of 3:7 (43%).

aeroHAWK wrote:
On top of all that, if I want 10mA with a 1.5 V forward voltage, the table indicates 66.7 ohms.

aeroHAWK wrote:
With the 5k, the voltage across the resistor was 3.25 V
In the datasheet, Maxim wrote:
[the resistor's] minimum value should be 9.53kÎ©, which typically sets the segment current at 40mA.

aeroHAWK wrote:
According to Ohm, current with the 5k is .65 mA,
Which would imply a 65 mA segment drive, beyond the device's recommended maximum.
Quote:
10k is .36 mA,
That falls into the table's first row for 40 mA, and 100 x 0.36 mA is pretty close to 40 mA.
Quote:
20k is .19mA
Row 3, 20 mA, pretty close to 100 x 0.19 mA.

aeroHAWK wrote:
This still seems to have little correlation with Table 11.
In the datasheet, Maxim wrote:
nominally 100 times
... and remember that it's not a constant current device.

aeroHAWK wrote:
 I am shooting for 15 mA nominal, so I used a 33.2k and 100k in parallel (since I don't have many values in my stock - it comes to 24.9k) and that calculates to 15.9 mA to the LEDs. :wink:
Experimentation is probably your best bet, since the 7219 isn't a constant current device.

JJ

 "Experience is what enables you to recognise a mistake the second time you make it." "Good judgement comes from experience.  Experience comes from bad judgement." "Wisdom is always wont to arrive late, and to be a little approximate on first possession." "When you hear hoofbeats, think horses, not unicorns." "Fast.  Cheap.  Good.  Pick two." "We see a lot of arses on handlebars around here." - [J Ekdahl]

Thanks for the perspective JJ.

joeymorin wrote:
The table is a bit misleading.
Nowhere does it indicate kOhms.
joeymorin wrote:
In the datasheet, Maxim wrote:
[the resistor's] minimum value should be 9.53kÎ©, which typically sets the segment current at 40mA.
I somehow missed this. :oops: This is the only clue that might point to the table being kOhms.
joeymorin wrote:
Quote:
10k is .36 mA,
That falls into the table's first row for 40 mA, and 100 x 0.36 mA is pretty close to 40 mA.
Quote:
20k is .19mA
Row 3, 20 mA, pretty close to 100 x 0.19 mA.
Yes, but I still stick with what I wrote:
This still seems to have little correlation with Table 11.
Because the resistor values are quite a ways off. :roll:
joeymorin wrote:
Experimentation is probably your best bet
Yes, I agree! I would have hoped the datasheet would have been more definitive or specific.

Again thanks JJ. Your comments have given me more understanding about what the datasheet (however vague) is attempting to convey. 8)

Cris

Perfection is achieved, not when there is nothing more to add, but when there is nothing left to take away. Antoine de Saint-Exupery (1900 - 1944)

aeroHAWK wrote:
joeymorin wrote:
The table is a bit misleading.
Nowhere does it indicate kOhms.
Neither does it say 'Ohms'. That's what makes the table misleading ;)

However, every reference to a value for Rset elsewhere in the datasheet is for a value expressed in KOhms. Small comfort :)

Quote:
Yes, but I still stick with what I wrote:
This still seems to have little correlation with Table 11.
Because the resistor values are quite a ways off. :roll:
The conclusion that the values are 'way off' would be valid if Rset configured an internal constant current circuit. It doesn't, because there isn't one. The table is your only guide.
Quote:
joeymorin wrote:
Experimentation is probably your best bet
Yes, I agree! I would have hoped the datasheet would have been more definitive or specific.
Might be worth submitting an errata report to MAXIM.

JJ

 "Experience is what enables you to recognise a mistake the second time you make it." "Good judgement comes from experience.  Experience comes from bad judgement." "Wisdom is always wont to arrive late, and to be a little approximate on first possession." "When you hear hoofbeats, think horses, not unicorns." "Fast.  Cheap.  Good.  Pick two." "We see a lot of arses on handlebars around here." - [J Ekdahl]

aeroHAWK,

How are you determining that there is poor correllation between the segment current and the Rset value?

Did you see the graph at the upper right corner of page 4 in the data sheet? Does this match your observations beter than the values given in the table?

joeymorin wrote:
The conclusion that the values are 'way off' would be valid if Rset configured an internal constant current circuit.
I want 15 mA segment current. The table suggests 48 kOhms for Rset. Actual is 24 kOhms.... yes, I consider this WAY OFF. :shock: I don't see that it matters if it is a current source or voltage source or frustration source. :wink:
Chuck-Rowst wrote:
Did you see the graph at the upper right corner of page 4 in the data sheet? Does this match your observations beter than the values given in the table?
If I understand what the graph is telling me... it is 10-15% off. It seems to be closer than the table but I am not entirely clear what the graph is for. :?

Cris

Perfection is achieved, not when there is nothing more to add, but when there is nothing left to take away. Antoine de Saint-Exupery (1900 - 1944)

aeroHAWK wrote:
yes, I consider this WAY OFF. :shock:
Quote:
If I understand what the graph is telling me... it is 10-15% off.
Silly question, but are you measuring average current or peak current?

Also, you should consider the possibility that you've cooked the 7219 by experimenting with an Rset of 60 ohms.

 "Experience is what enables you to recognise a mistake the second time you make it." "Good judgement comes from experience.  Experience comes from bad judgement." "Wisdom is always wont to arrive late, and to be a little approximate on first possession." "When you hear hoofbeats, think horses, not unicorns." "Fast.  Cheap.  Good.  Pick two." "We see a lot of arses on handlebars around here." - [J Ekdahl]

All props to you Cris, you're a master craftsman ! With the CLEANEST machine shop I've ever seen ( You know you cleaned up before taking that pic :wink: )! Why do the inserts have a "star" shape...I'd guess there are other shapes ?

1) Studio 4.18 build 716 (SP3)
2) WinAvr 20100110
3) PN, all on Doze XP... For Now
A) Avr Dragon ver. 1
B) Avr MKII ISP, 2009 model
C) MKII JTAGICE ver. 1

joeymorin wrote:
are you measuring average current or peak current?
I assume it's average current since I'm using a DVM (even so, I measured at max intensity so average and peak should be pretty close - if there is even a difference in the first place).
joeymorin wrote:
you should consider the possibility that you've cooked the 7219 by experimenting with an Rset of 60 ohms.
Yes that's possible... however all 4 digits behave the same and they all respond to the onboard PWM just fine.
indianajones11 wrote:
All props to you Cris, you're a master craftsman ! With the CLEANEST machine shop I've ever seen ( You know you cleaned up before taking that pic :wink: )!
Well close... I have recently relocated my shop into a new building and the photo was taken right after painting the floor and walls and the machines were set in place (if you look at the shelves behind the wall on the left, you'll notice I haven't filled them yet :wink: ).
indianajones11 wrote:
Why do the inserts have a "star" shape...I'd guess there are other shapes ?
They need a flange so they don't pull out, and the star shape is so they don't rotate. I could have made them square or hex, but as I mentioned, I like the star shape of Torx drivers so I used something similar.

Cris

Perfection is achieved, not when there is nothing more to add, but when there is nothing left to take away. Antoine de Saint-Exupery (1900 - 1944)

aeroHAWK wrote:
joeymorin wrote:
are you measuring average current or peak current?
I assume it's average current since I'm using a DVM (even so, I measured at max intensity so average and peak should be pretty close - if there is even a difference in the first place).
Sorry, I was referring to the fact that this is a multiplexing device. Are you driving all digits of the segment you are measuring? Even if you are, remember that there is an inter-digit blanking period, so a DMM will read a lower current than is the actual peak current, and the datasheet specifies values of Rset for peak current.

The blanking time is set by the intensity register. Maximum intensity is 31/32 of a cycle, for a blanking period of 1/32 of a cycle. The default power-up state of the intensity register is for the minimum intensity of 1/32 of a cycle, and a blanking time of 31/32 of a cycle.

JJ

 "Experience is what enables you to recognise a mistake the second time you make it." "Good judgement comes from experience.  Experience comes from bad judgement." "Wisdom is always wont to arrive late, and to be a little approximate on first possession." "When you hear hoofbeats, think horses, not unicorns." "Fast.  Cheap.  Good.  Pick two." "We see a lot of arses on handlebars around here." - [J Ekdahl]

aeroHAWK,

So, where exactly are you connecting the DVM to measure or determine the segment current? Also, what values are you loading into the 7219's configuration registers?

joeymorin wrote:
I was referring to the fact that this is a multiplexing device.
Chuck-Rowst wrote:
where exactly are you connecting the DVM to measure or determine the segment current?
Thank you JJ and Chuck for your persistence to get through my arrogance and stubbornness! :shock: I get it now.

You have helped me see the error in my approach. :oops: My conclusion that the datasheet is wrong is based on erroneous assumptions. :oops: And I have been reminded of something I have said in a previous post... that I know "just enough about electronics to be dangerous". :shock:

Now I see it is very likely that the datasheet is accurate. :oops:

Soooooo... as it turns out, I don't really care what the LED segment current is. :? What I DO care about is how the display LOOKS (I was only guessing the 15 mA per segment would do it). So based on that, I can experiment with Rset to achieve what I am after. The actual number is not real important (as long as it doesn't damage the chip or LEDs :wink:).

You have helped me understand the datasheet so now I have a much better understanding of the MAX7219. :)

THANKS again!

Cris

Perfection is achieved, not when there is nothing more to add, but when there is nothing left to take away. Antoine de Saint-Exupery (1900 - 1944)

aeroHAWK,

In any of the 94 above posts did you describe the power supply you are using for this tachometer? What is the voltage available on your aircraft? How do you convert it to the voltages needed in your circuitry (3.3? 5.0? )?

Chuck-Rowst wrote:
In any of the 94 above posts did you describe the power supply you are using for this tachometer?
No I have not.
Chuck-Rowst wrote:
What is the voltage available on your aircraft? How do you convert it to the voltages needed in your circuitry (3.3? 5.0? )?
The airplane will have an electrical system similar to a car - 12 V nominal. I will have a 12-5 V DC-DC power supply and have a separate 5 V bus for the gauges I make. The only place I will need 3.3 V is for the MAX31855s for Temp gauges, and that will be done internally to the gauge (along with associated level shifting needed).

 corrected MAX31855 (was MAX3155)

Perfection is achieved, not when there is nothing more to add, but when there is nothing left to take away. Antoine de Saint-Exupery (1900 - 1944)

Last Edited: Wed. Oct 9, 2013 - 06:27 AM

aeroHAWK wrote:
Soooooo... as it turns out, I don't really care what the LED segment current is. :? What I DO care about is how the display LOOKS (I was only guessing the 15 mA per segment would do it). So based on that, I can experiment with Rset to achieve what I am after. The actual number is not real important (as long as it doesn't damage the chip or LEDs :wink:).
Yup!

It means, of course, that you're going to have to look at another datasheet ;) ... the one for the LED. It also means that you have to determine the true peak current delivered by the 7219. An oscilloscope will come in handy. You can measure average current with a DMM, and observe the waveform on the 'scope to estimate duty cycle. This will allow you to calculate peak current.

You really want to make sure that you stay below the peak current rating for the LEDs, as well as the max average current rating. Surpassing those limits will result in cumulative damage to the LEDs that will eventually lead to failure.

JJ

 "Experience is what enables you to recognise a mistake the second time you make it." "Good judgement comes from experience.  Experience comes from bad judgement." "Wisdom is always wont to arrive late, and to be a little approximate on first possession." "When you hear hoofbeats, think horses, not unicorns." "Fast.  Cheap.  Good.  Pick two." "We see a lot of arses on handlebars around here." - [J Ekdahl]

aeroHAWK,

So there's no voltage regulator in the tachometer itself, everything runs off the bussed 5 volts, correct?

How much current are you expecting the completed tachometer to draw from the 5 volt bus under worst case operating conditions (I'd image at full-brightness) ?

You stated:

"The actual number [ ma per segment ] is not real important as long as it doesn't damage the chip or LEDs"

Agreed. But how will you know how "hard" you are driving the chip and how close it is to self-destruction? My advice would be to monitor the temperature of this chip in the fully assembled unit operating under the worst case brightness scenario. Then use this temperature to calculate the chip's die temperature based on thermal parameters given in the 7219's data sheet. The die temperature is directly related to statistically expected lifetime of the chip. ( The hotter the die the less the expected lifetime. There's an exponential relationship between the two commonly expresses as: "A halving of expected life (i.e MTBF hours) for every 10 deg C increase in die temperature. )

Also, the maximum power dissipation of the 7219 (how much heat it must shed to drive the LEDs) may not occur at maximum LED brightness, it may occur at somewhere closer to 75% LED bightness.

My EE instinct tells me I'd be more concerned in this design with burning up the 7219 rather than burning up a segment of the display.

While you may not need to know the exact peak or average current of the segements so long as you get the aesthetically & ergometrically correct display brightness, IMHO you also want to make sure you are not running the 7219 on the ragged edge of self-destruction.

joeymorin wrote:
It means, of course, that you're going to have to look at another datasheet ;) ... the one for the LED.
joeymorin wrote:
You really want to make sure that you stay below the peak current rating for the LEDs, as well as the max average current rating.
The LEDs are HDSP-7303, max peak 150mA, average 25mA. Since I now understand more about the MAX7219 data sheet, I can make an educated guess at the peak current based on number of displays and Rset current. It seems difficult to get near the 150mA limit with my current setup. :wink: Also, since increased LED brightness rolls off at higher average current levels, there is a point of diminishing returns. My understanding is that if I stay below this area of 'diminishing returns' the LEDs will not be stressed. I can see this by watching the amount the brightness changes with different levels of intensity from the MAX7219 PWM.
Chuck-Rowst wrote:
how will you know how "hard" you are driving the chip and how close it is to self-destruction?
My gut sense is to check that the MAX7219 is not hot... It's not. :wink:
Chuck-Rowst wrote:
So there's no voltage regulator in the tachometer itself, everything runs off the bussed 5 volts, correct?
Correct.
Chuck-Rowst wrote:
How much current are you expecting the completed tachometer to draw from the 5 volt bus under worst case operating conditions (I'd image at full-brightness) ?
500mA to 600mA.

Perfection is achieved, not when there is nothing more to add, but when there is nothing left to take away. Antoine de Saint-Exupery (1900 - 1944)