Badcaps.net Forum
Go Back   Badcaps Forums > Troubleshooting Hardware & Devices and Electronics Theory > Equipment Usage, Soldering, Techniques, and Reviews
Register FAQ Calendar Search Today's Posts Mark Forums Read

 
Thread Tools
Old 07-28-2017, 01:45 PM   #761
Per Hansson
Super Moderator
 
Per Hansson's Avatar
 
Join Date: Jul 2005
City & State: ----
My Country: Sweden
Line Voltage: 230v 50Hz
I'm a: Knowledge Seeker
Posts: 5,523
Default Re: ESR meter upgrades

If you want to try Markus (Madires) firmware on the GM328R it is attached here in 8, 16 & 20Mhz versions.
(I have only tested 16Mhz).
But please note the caveats I encountered:
http://www.eevblog.com/forum/testgea...53/#msg1266553
Attached Files
File Type: zip GM328R ESR tester (ComponentTester-1.29m).zip (102.3 KB, 29 views)
__________________
"The one who says it cannot be done should never interrupt the one who is doing it."
Per Hansson is offline   Reply With Quote
Old 07-28-2017, 02:08 PM   #762
jondoe
Badcaps Veteran
 
Join Date: Nov 2016
City & State: A
My Country: UK
I'm a: Hobbyist Tech
Posts: 538
Default Re: ESR meter upgrades

Don't you need to use the older tool chain? The most recent one creates over sized files, which was the problem I had.
jondoe is offline   Reply With Quote
Old 07-28-2017, 02:10 PM   #763
Per Hansson
Super Moderator
 
Per Hansson's Avatar
 
Join Date: Jul 2005
City & State: ----
My Country: Sweden
Line Voltage: 230v 50Hz
I'm a: Knowledge Seeker
Posts: 5,523
Default Re: ESR meter upgrades

I am using the older toolchain, avr-gcc v4.8.2 is the same that stj uses. (I think he is on Windows though).
My files are identical in size to stj's.
The issue is that the newer code simply take up a bit more space.
Per Hansson is offline   Reply With Quote
Old 07-28-2017, 02:25 PM   #764
vinceroger69
Badcaps Veteran
 
Join Date: Mar 2012
City & State: Nuneaton Warwickshire
My Country: uk
I'm a: Hobbyist Tech
Posts: 6,493
Default Re: ESR meter upgrades

Quote:
Originally Posted by Per Hansson View Post
If you want to try Markus (Madires) firmware on the GM328R it is attached here in 8, 16 & 20Mhz versions.
(I have only tested 16Mhz).
But please note the caveats I encountered:
http://www.eevblog.com/forum/testgea...53/#msg1266553
Thanks i was reading that thread too and did see your posts im suprised no one on there cant sort the issue your having out with the markus firmware hopefully stj will be able too sort his firmware out so its smaller etc
vinceroger69 is offline   Reply With Quote
Old 07-28-2017, 02:26 PM   #765
stj
Great Sage 齊天大聖
 
stj's Avatar
 
Join Date: Dec 2009
City & State: Europe
My Country: some shithole run by Israeli agents
I'm a: Professional Tech
Posts: 29,097
Default Re: ESR meter upgrades

i'm not on windows.
i was using the windows toolchain on wine though.
stj is offline   Reply With Quote
Old 07-28-2017, 03:18 PM   #766
redwire
Badcaps Veteran
 
Join Date: Dec 2010
City & State: Alberta
My Country: Canada
Posts: 3,241
Default Re: ESR meter upgrades

The compiler might have an optimization flag turned off.
That can reduce the output file size.
Does anyone have the compiler command line to look at.
redwire is offline   Reply With Quote
Old 07-28-2017, 03:30 PM   #767
Per Hansson
Super Moderator
 
Per Hansson's Avatar
 
Join Date: Jul 2005
City & State: ----
My Country: Sweden
Line Voltage: 230v 50Hz
I'm a: Knowledge Seeker
Posts: 5,523
Default Re: ESR meter upgrades

I have compiled the latest SVN version of Karl-Heinz firmware now.
As base I have used stj's Makefile from here.
I have only changed the type of font used in the Makefile.
Instead of "DFONT_7X12" I am using "DFONT_8X8"
This allows the firmware to compile:
Code:
16 MHz operation configured.
AVR Memory Usage
----------------
Device: atmega328p

Program:   32352 bytes (98.7% Full)
(.text + .data + .bootloader)

Data:        206 bytes (10.1% Full)
(.data + .bss + .noinit)

EEPROM:      914 bytes (89.3% Full)
(.eeprom)
Here is a screenshot of how it looks:

IMO it is much better with this font because the previous ones that stj used
Which were both bold and not bold resulted in much less info on the screen as seen here:
http://www.badcaps.net/forum/showpos...&postcount=446

EDIT: redwire, I have attached the compiler output as a zipfile.
Attached Images
File Type: jpg IMAG0433.jpg (61.0 KB, 178 views)
Attached Files
File Type: zip Compiler Output.zip (2.3 KB, 13 views)
File Type: zip GM328R ESR tester (SVN740).zip (84.5 KB, 15 views)

Last edited by Per Hansson; 07-29-2017 at 07:57 AM.. Reason: Added 8Mhz build
Per Hansson is offline   Reply With Quote
Old 07-28-2017, 03:35 PM   #768
jondoe
Badcaps Veteran
 
Join Date: Nov 2016
City & State: A
My Country: UK
I'm a: Hobbyist Tech
Posts: 538
Default Re: ESR meter upgrades

That font certainly looks nice and readable.
jondoe is offline   Reply With Quote
Old 07-28-2017, 03:36 PM   #769
stj
Great Sage 齊天大聖
 
stj's Avatar
 
Join Date: Dec 2009
City & State: Europe
My Country: some shithole run by Israeli agents
I'm a: Professional Tech
Posts: 29,097
Default Re: ESR meter upgrades

i had a discusion with vince about that, nice fonts vs more info on screen.

btw, you shouldnt use old makefiles.
you should copy the settings in them to the new makefile.
because the new makefile can contain extra options or critical changes.

Last edited by stj; 07-28-2017 at 03:38 PM..
stj is offline   Reply With Quote
Old 07-28-2017, 03:42 PM   #770
Per Hansson
Super Moderator
 
Per Hansson's Avatar
 
Join Date: Jul 2005
City & State: ----
My Country: Sweden
Line Voltage: 230v 50Hz
I'm a: Knowledge Seeker
Posts: 5,523
Default Re: ESR meter upgrades

Quote:
Originally Posted by stj View Post
i had a discusion with vince about that, nice fonts vs more info on screen.
Well you had with me too.
That's why I put in the links I did in my post above.
But actually both "DFONT_7X12" that you have used in the latest makefiles.
And "DFONT_8x15" that I wrote that I liked.
They resulted in 3 scrolling lines of text when testing that Mosfet:
Quote:
Originally Posted by Per Hansson View Post
I understand what you say, but for example in this post I showed the bold font testing an, as you put it:
"fet or a transistor with reverse-diode in it and see how much text it has to display!"
Well the small font is the same, it also has to scroll through three pages to show all the info so it does not seem better to me?
Quote:
Originally Posted by stj View Post
btw, you shouldnt use old makefiles.
you should copy the settings in them to the new makefile.
because the new makefile can contain extra options or critical changes.
I know, but I compared the Makefiles.
The only addition in the new Makefile is the description of a new option for the UART
And then the complete removal of this section:
Code:
# Enable contrast menu option
CFLAGS += -DWITH_CONTRAST
But the option was still there after compiling the firmware so probably it was just made mandatory.

Last edited by Per Hansson; 07-28-2017 at 03:59 PM..
Per Hansson is offline   Reply With Quote
Old 07-28-2017, 05:51 PM   #771
stj
Great Sage 齊天大聖
 
stj's Avatar
 
Join Date: Dec 2009
City & State: Europe
My Country: some shithole run by Israeli agents
I'm a: Professional Tech
Posts: 29,097
Default Re: ESR meter upgrades

oops,

i removed that and hard coded the contrast-value to save memory.
be a bastard if the menu option is hard coded in the driver now.
stj is offline   Reply With Quote
Old 07-29-2017, 08:50 AM   #772
Per Hansson
Super Moderator
 
Per Hansson's Avatar
 
Join Date: Jul 2005
City & State: ----
My Country: Sweden
Line Voltage: 230v 50Hz
I'm a: Knowledge Seeker
Posts: 5,523
Default Re: ESR meter upgrades

I updated the ZIP above in post #767 with the 8Mhz build now as well.
I also updated the makefile, I did a before and after check and the 16Mhz output file was identical to that I built yesterday.

A question for stj, the value BAT_OUT is 150 by default.
On my tester after the 9v battery sits a A673
You have changed it to 3, what does that signify?

Code:
# The BAT_OUT option enables Battery Voltage Output on LCD (if BAT_CHECK is selected).
# If your 9V supply has a diode installed, use the BAT_OUT=600 form to specify the
# threshold voltage of your diode to adjust the output value.
# This threshold level is added to LCD-output and does not affect the voltage checking levels.
CFLAGS += -DBAT_OUT=3
And here is from the PDF:
Quote:
BAT OUT enables Battery Voltage Output on LCD (if BAT CHECK is selected). If your 9V
supply has a diode installed, use the BAT OUT=600 form to specify the threshold voltage (mV)
of your diode to adjust the output value. Also the voltage loss of transistor T3 can be respected
with this option. threshold level does not affect the voltage checking levels (BAT POOR).
Example 1: CFLAGS += -DBAT OUT=300
Example 2: CFLAGS += -DBAT OUT
P.S: I have changed my TL431 with a LM4040 and the VCC displayed at poweron is: 5.03v
Per Hansson is offline   Reply With Quote
Old 07-29-2017, 09:55 AM   #773
Per Hansson
Super Moderator
 
Per Hansson's Avatar
 
Join Date: Jul 2005
City & State: ----
My Country: Sweden
Line Voltage: 230v 50Hz
I'm a: Knowledge Seeker
Posts: 5,523
Default Re: ESR meter upgrades

Posted this on eevblog, reposting here.
Here is how to setup a build environment on CentOS7 or RHEL7 (Red Hat Enterprise Linux)
In the optional repository EPEL we have already avr for our purposes.
The version provided is avr-gcc 4.9.2 which unfortunately produces files that are a little bigger than the previous release.
So if you are not on the limit size wise this version will work fine, but if not read on.

So since an older version is not available for CentOS7 on EPEL we have to try to find one.
Looking around we can see that for Fedora 19 avr-gcc 4.8.2 was released.
This is perfect because Fedora 19 is the same baseline system as RHEL7.
So login as a standard user on your Centos7 or RHEL7 machine and lets rebuild this source RPM:

Code:
wget http://archive.fedoraproject.org/pub/archive/fedora/linux/updates/19/SRPMS/avr-gcc-4.8.2-2.fc19.src.rpm
wget http://archive.fedoraproject.org/pub/archive/fedora/linux/releases/19/Everything/source/SRPMS/a/avr-libc-1.8.0-4.fc19.src.rpm

rpmbuild --rebuild avr-gcc-4.8.2-2.fc19.src.rpm
rpmbuild --rebuild avr-libc-1.8.0-4.fc19.src.rpm

su root -c "rpm -ivh /home/per/rpmbuild/RPMS/x86_64/avr-gcc-4.8.2-2.el7.centos.x86_64.rpm /home/per/rpmbuild/RPMS/noarch/avr-libc-1.8.0-4.el7.centos.noarch.rpm"
Replace /home/per with your user used for building.
Happy building
Per Hansson is offline   Reply With Quote
Old 07-29-2017, 10:43 AM   #774
stj
Great Sage 齊天大聖
 
stj's Avatar
 
Join Date: Dec 2009
City & State: Europe
My Country: some shithole run by Israeli agents
I'm a: Professional Tech
Posts: 29,097
Default Re: ESR meter upgrades

the bat-out value is to counteract voltdrop through diodes & stuff.
stj is offline   Reply With Quote
Old 07-29-2017, 11:18 AM   #775
vinceroger69
Badcaps Veteran
 
Join Date: Mar 2012
City & State: Nuneaton Warwickshire
My Country: uk
I'm a: Hobbyist Tech
Posts: 6,493
Default Re: ESR meter upgrades

Quote:
Originally Posted by Per Hansson View Post
I have compiled the latest SVN version of Karl-Heinz firmware now.
As base I have used stj's Makefile from here.
I have only changed the type of font used in the Makefile.
Instead of "DFONT_7X12" I am using "DFONT_8X8"
This allows the firmware to compile:
Code:
16 MHz operation configured.
AVR Memory Usage
----------------
Device: atmega328p

Program:   32352 bytes (98.7% Full)
(.text + .data + .bootloader)

Data:        206 bytes (10.1% Full)
(.data + .bss + .noinit)

EEPROM:      914 bytes (89.3% Full)
(.eeprom)
Here is a screenshot of how it looks:

IMO it is much better with this font because the previous ones that stj used
Which were both bold and not bold resulted in much less info on the screen as seen here:
http://www.badcaps.net/forum/showpos...&postcount=446

EDIT: redwire, I have attached the compiler output as a zipfile.
thanks i will update both of my testers next week is there any diffrence in calibrating the unit? as ive read somewhere about measuring a capacitor 3 times does this apply too this firmware version many thanks
vinceroger69 is offline   Reply With Quote
Old 07-29-2017, 11:40 AM   #776
Per Hansson
Super Moderator
 
Per Hansson's Avatar
 
Join Date: Jul 2005
City & State: ----
My Country: Sweden
Line Voltage: 230v 50Hz
I'm a: Knowledge Seeker
Posts: 5,523
Default Re: ESR meter upgrades

Quote:
Originally Posted by vinceroger69 View Post
is there any diffrence in calibrating the unit? as ive read somewhere about measuring a capacitor 3 times does this apply too this firmware version many thanks
That only applies to Markus (Madires) firmware that I posted earlier.
Quote:
Originally Posted by stj View Post
the bat-out value is to counteract voltdrop through diodes & stuff.
How/where to measure this?
The manual does not go into any detail on the subject.
And does it matter at all when the 2.5v precision regulator is installed?

Last edited by Per Hansson; 07-29-2017 at 11:41 AM..
Per Hansson is offline   Reply With Quote
Old 07-29-2017, 04:11 PM   #777
stj
Great Sage 齊天大聖
 
stj's Avatar
 
Join Date: Dec 2009
City & State: Europe
My Country: some shithole run by Israeli agents
I'm a: Professional Tech
Posts: 29,097
Default Re: ESR meter upgrades

it's for battery status at power-up.
the original large value was because the original hardware had a 1n4007 inline with the power - big voltdrop of upto 1,4v on those!
stj is offline   Reply With Quote
Old 07-29-2017, 05:36 PM   #778
redwire
Badcaps Veteran
 
Join Date: Dec 2010
City & State: Alberta
My Country: Canada
Posts: 3,241
Default Re: ESR meter upgrades

The on/off switch transistor and reverse-polarity protection have some voltage drop.
Because the battery voltage-monitoring is upstream of these, I think BAT_OUT is a correction factor (in mV). Measure voltage drop from BAT+ to the battery sense resistor (10k) and use this number.

Some testers have mosfets or transistors or a diode on input power, so each has different voltage losses.
redwire is offline   Reply With Quote
Old 07-30-2017, 08:46 AM   #779
Per Hansson
Super Moderator
 
Per Hansson's Avatar
 
Join Date: Jul 2005
City & State: ----
My Country: Sweden
Line Voltage: 230v 50Hz
I'm a: Knowledge Seeker
Posts: 5,523
Default Re: ESR meter upgrades

Thanks for the explanation, now even I get it!
I used a bench PSU to power it and measured the voltage at the sense resistor.
The drop is ca 45mV according to two meters.
I put in 50mW for BAT_OUT
Per Hansson is offline   Reply With Quote
Old 07-30-2017, 10:01 AM   #780
stj
Great Sage 齊天大聖
 
stj's Avatar
 
Join Date: Dec 2009
City & State: Europe
My Country: some shithole run by Israeli agents
I'm a: Professional Tech
Posts: 29,097
Default Re: ESR meter upgrades

test it, put a meter across the battery and compare it to the value displayed at power-on
that's how i finetune'd it for the gm328 hardware.
stj is offline   Reply With Quote
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump



Badcaps.net Technical Forums © 2003 - 2023
Powered by vBulletin ®
Copyright ©2000 - 2023, Jelsoft Enterprises Ltd.
All times are GMT -6. The time now is 12:15 AM.
Did you find this forum helpful?