Tuesday, April 30, 2024

ESP-32 data logger (3): logger redesign

 I have redesigned the ESP32 logger: 

  • I have abandoned using the ESP32 ADCs entirely
  • The logger will use an ADC module with the 16 bit 4 channel ADS1115 ADC
  • Rather than use a current sense resistor, I have opted to use a ACS712 Hall effect module, which will feed a voltage proportional to current to the ADS1115
  • Battery voltage will be fed to the ADC  using a voltage divider, not shown on the schematic below. 
  • I've added an SSD1306 OLED display. 
  • I added a voltage divider breakout with a 0.2 voltage reduction for sampling the battery voltage
The schematic for the new logger design is below.  I have ordered the ADS1115 module and the ACS712 module from Amazon.com. Delivery is due Friday/  

click to enlarge









Monday, April 29, 2024

ESP-32 data logger (2) --- 12V 7.2AH SLA battery (5) -- partial failure (UPDATED)

 I conducted a test of the ESP32 data logger (link), and simultaneously testing the LM317 charger circuit (link). 

Details: 

  • The current limit on the LM317 circuit was set for 0.72 amps
  • The charge voltage was set to 13.8 volts
  • The battery was discharge to about 30% capacity 
  • Charging was done over a 10 hour interval
  • The logger was set for 1 measurement every 10 seconds
  • Voltage sense was through ESP32 ADC0 using a 1:0.128 voltage divider (6.8K-1K).
  • Current sense was through ESP32 ADC3 taken across the charger's 0.825 ohm, current sense resistor. 
  • The ESP32 ADC channels were set at 12 bits, 0 to 3.3V
  • Logged data was smoothed using Excel moving average filter, 20 samples wide. 
Logged charging curve is shown below: 


The charge current failed to reduce below 0.2 amps after 10 hours of charging.  I am not sure why.  I suspect the  battery has some leakage.  Will be checking this.

The  IR drop across the charger current sense resistor causes an error in the battery voltage measurement.  This is compensated in Excel by subtracting the voltage drop from the measured battery voltage. 

The measured current doesn't seem capable of going less than 0.17 amps.  I think this is a problem with the ESP32 ADC.  I'll need to investigate further.  It's a little disappointing. 

This task is to put the charger and logger circuit into separate enclosures. 

UPDATE:
1. For the logger circuit, it seems the ESP32 ADCs have a very evil reputation.  I am going to order  some ADS1115  4 channel 16 bit ADC modules, and try to improve the ADC accuracy.

2. For the charger, I am going to put away the LM317 charger for now and build a circuit around the UC3906 SLA battery charger chip.



Sunday, April 21, 2024

Husky 2 gallon compressor repair

 My compressor crapped out about a week ago.  After I took the cover off, I discovered a circuit board inside with a DC motor.  The fuse on the circuit board was blown.  After making a trip to Lowe's to get 3A 1-1/4 inch AGC fuses, I replaced the fuse. When I powered the compressor it blew the fuse again. 


I suspected a burned out motor, but didn't see any indication.  I made sure the compressor was unplugged and removed the cover again.  The small circuit board seemed simple enough, as it contained only a bridge rectifier and a capacitor and fuse. 


I removed the screws holding the circuit board to the chassis and turned the board over to look. 


I traced out the circuit, as shown below: 


The input ac power is fused, then run to the power switch. From there the AC line goes through a 100 psi pressure limiter switch.   After this the AC line and neutral are applied to a diode rectifier. The rectified DC is filtered by a small capacitor and then applied to the DC motor. 

The motor resistance was 13 ohms which seemed reasonable.  I clipped one of the wires to the motor to isolate the circuit from the motor.  Then I used my multimeter in diode voltage mode to check the diode bridge.  One of the arms of the diode bridge was shorted.  The bridge is a KBPC610, which I found I could order 10 pieces from Amazon for $8. 


When I received the replacement diode bridge, I soldered it in and tested the compressor, but it didn't work.  After some troubleshooting I found that one of the AC input connections to the board had broken off under the insulation.  After fixing this the compressor ran ok.  I carefully spliced and insulated the wire I had cut to the motor.  Then put everything back together, making sure that none of the wires was in danger of getting caught by the small axial fan that is under the cover. 

I hope the air compressor will keep running. I bought it about 15 years ago at Harbor Freight in Houston. 

Wednesday, April 17, 2024

ESP-32 data logger (1): micro SD logger design

 I am backing away from the battery charger project because I need to complete another project to continue.  So far I've been using a pencil and paper to record battery charge and discharge curves.  I am going to automate that data acquisition process using a ESP-32 microcomputer.  The first attempt will be to store the data to a micro SD card.  The second version will be to use WIFI to store the data on thingspeak.com. 

I have an ESP-32 development board that I bought off of amazon.com. (link).  It's a pretty sophisticated MCU.  I program it using the Arduino IDE.  The development package is 38 pins.  A diagram of the different pin functions is shown below



The test circuit for the micro SD logger is shown below.  The circuit will be powered through the development board USB port.  I order the micro SD card module from amazon.com (link).

click to enlarge

The circuit is wired up on solderless breadboard as shown below, The ESP32 dev board is on the left and the micro SD reader is on the right.   The first experiment will be to simply write some data into the micro SD card and read it back. 





Friday, April 12, 2024

12V 7.2AH SLA battery (4): LM317 battery charger test

 When I originally tried a LM317 circuit, I used the circuit I found at this link.  The LM317 charger circuit is quite popular and can be found all over the web. The circuit I'm using differs from that at the above link in that I added a 100 ohm resistor in the base of the 2N3904 current limiting transistor. I did this to protect the transistor. The circuit is design for a charge voltage of 13.8V and a charge current limit of 0.75A. 

Click to enlarge

The charging circuit works as follows: 

  • The LM317 regulator controls the voltage drop between the power source on the left and the battery on the right to maintain 1.25V from the VO pin to its ADJ pin. 
  • The regulator voltage is set by VO = (1+(RV1+R5)/(RV1+R5+R4)*1.25V)
  • The battery charge voltage is set to 13.8 volt. Given the values in the schematic, this corresponds to RV1 = 2.52Kohm
  • R6 and Q3 form a foldback current limiter circuit. The current limit cuts in when the voltage at R6 reaches about 0.6V.  If R6 = 0.82 ohms (four 3.3 ohm resistors in parallel), then the current limit will be 0.6V/0.82ohm = 0.73A. 
  • In actual operation with a discharged SLA battery, the circuit will initially attempt to regulate the battery voltage at 13.8V but current limiting would cut in, resulting in constant charge current as the battery charged.  As the battery charge voltage approached 3.8V the current limiting would cut out and battery charge current would fall while the charge voltage remained constant. 
I built the charger circuit 


After building the circuit, the LM317 charger was tested as shown in the photo below.  In the upper left is a 23V source taken from the unregulated side of a 13.8V power supply. The charger circuit is in the lower left while a voltage and current monitor for the battery is in the lower right while the battery itself is in the center right. 

click to enlarge

The initial test of the LM317 charger is shown below.  A problem with is test is that the voltage was not set to 13.8V as required.  The voltage was set to 13.4 volts. The battery fails to charge fully and final battery charge voltage settles at 13.3 volts.  

click to enlarge

The test will be conducted after adjustment of the set voltage to 13.8V. 



Thursday, April 4, 2024

Craftsman 10" bandsaw 113.244513 (5): Testing new lower blade guide (updated)

 I installed the new lower guide into the Craftsman saw, as shown in the photo below.  There were minor issues and one major issue as noted in the photo and the list below the photo.

click to enlarge


  • There is interference between the left side of the thrust bearing axle and the case. This is easily fixed by cutting the ends of the axle down.
  • There is possible interference between the right blade guide and the case.  Fix by cutting the guide length down. 
  • Change all the set screws to Allen style headless screws.  This will help reduce places to snag when installing the sawblade.
  • The thrust bearing is not centered on the blade.  For now I will install a shim under the lower blade guide support to move the guide over about 1 mm. 
The saw runs fairly well, with some noise. Once I get the above issues on the lower guide fixed, I'll replace the wheel bushings with ball bearings, and replace the worn tires. 

UPDATE: 
I bought a bottom style 10-24 tap on Amazon.com for $3.  It cleaned out the set screw holes very well.  Now the set screws don't jam and it's easy to feel when the screw contacts the blade guide.   I also shortened  the thrust washer bearing axle and the two blade guides.  Now there is no interference of those features with the case.  

I printed a set of shims to use under the lower guide support to center the thrust bearing  on the blade. The shims were nominally 1mm, 0.5mm, and 0.25mm thick.  Upon actual 3D printing, each shim was 0.13mm or so larger than nominal.   The 1mm and 0.5mm shims together seemed to center the blade on the bearing the best. 

The photo below shows the shims after 3D printing.



The photo below shows the guide installed with notes on latest changes.

click to enlarge





Craftsman 10" bandsaw 113.244513 (4): Lower blade guide redesign (results)

This lower guide replaces Craftsman Part 69174  in the 113.24413 model bandsaw. 

I did the lower blade guide redesign in Fusion 360.  See the diagram below with changes noted.  I increased the material volume around the blade guide set screws and added holes normal to the layer planes to accommodate 2mm reinforcing screws. The holes for the thrust bearing axle were enlarged to get a sliding fit on the axle, and 3mm set screws were added to hold the axle fixed.

click to enlarge



I 3D printed the guide out, using black PLA, 100% fill.  Because of the black plastic of the guide it is hard to photograph. The photos below show the guide with hardware installed from a front and rear view.  

click to enlarge


Some notes: 
  • I have not used the Cura slicer software to calibrate hole sizes while printing. All holes in the guide were slightly small. I spent a lot of time drilling out holes, experimenting on test pieces to check for correct size. 
  • I was not able to use a tap well for the 10-24 saw guide set screw holes.  The tap bottomed out against the bottom of the blade guide holes. Because of this the set screws tend to jam as they get near the blade guide. That makes it difficult to feel when the set screws are solidly against the guides.
  • The 2 mm tread inserts I used from the bottom for the reinforcement screws were a little tricky to install. I put them on the tip of a soldering iron and melted them into the guide body.  I had to use a screw from the bottom side  to clean out the melted plastic from the from the holes, then install the reinforcement screws from the top side. 
  • I didn't use a tap on the thrust bearing axle set screws, but rather let the screws cut their on threads in the plastic.  I don't think this will be a problem as the screws don't have to be torqued very much to prevent lateral movement of the axle.   Next time I'll use thread inserts to get  better seating on the screws. 
I will be installing the guide in the saw today and testing how well it works. 

Monday, April 1, 2024

Craftsman 10" bandsaw 113.244513 (3): Blade guide redesign plans

 I bought this Craftsman 10" 3-wheel saw in August of 2023 for $10.  At the time, it didn't have the switch key or a blade installed, so the owners just sold the unit for salvage.


I found a switch key for  Craftsman products on Thingiverse.com (link).  I  then  3D printed the key in PLA, The key has to be positioned with the "legs" up while printing, and then the support material under the "head" has to be whittled off, but the switch key functions very well, as shown below. 


The saw needs new tires, but I haven't ordered any yet. I bought a 56-7/8 inch 1/4" 14TPI bandsaw blade (link) for the saw and spent some time trying to tune up the saw.   In the process I discovered that the lower blade guide to the saw was broken.   The guide body, Craftsman part 69174, is cast from pot metal, and broke at an obvious weak spot as shown in the photo below.  I found a Thingiverse.com replacement (link).  The printed out replacement part is shown below.  It was printed in orange PLA with 100% fill.  The hardware for the thrust bearing has been moved to the new PLA bearing  The blade guides were missing in the original part. I used 1/4" bookshelf pins for the side guides. 



The photo below shows the lower guide after installation. The thrust bearing has a groove in its surface and needs to be replaced. 

click to enlarge

The problem with the 3D printed part is immediately apparent as shown in the photo below. The blade guide set screws produce stress that is normal to the 3D printed layers.  The part is weak in that direction and the stress causes fractures parallel to the layers as can be seen in the photo. 


Someone must have experienced this problem and revised the part to be more robust (link).  See screen capture below. 

Another problem to consider is the replacement of the thrust bearing.  See the photo below and the issues list below that. 

click to enlarge



Thrust bearings issues list: 
  1. There is no provision for moving the thrust bearing laterally to center it on the saw blade. The lateral position of the blade is mostly determined by thickness of the bandsaw tires.  I don't know how much of an issue this lack of lateral adjustment will be. 
  2. The current bearing is worn with a groove on its surface.  I found replacement bearings on Amazon.com (link). They are 3mm ID X 10mm OD X 4 mm wide.  I've also found 3mm stainless steel rod to make the axle (link).  I haven't yet found material to make the spacers.
  3. The thrust bearing is difficult to install on the guide. The axle is currently pressed through the guide plastic body.  I don't like guessing the proper diameter to get a good interference fit for the axle.  Also without some sort of installation jig, pressing the axle stresses the plastic guide body and distorts the part. 
My plan for the plastic guide redesign are shown in the sketch below, which is a side view of the guide: 

  1. Extend the material adjacent to the saw guide set screws and add reinforcing screws to prevents cracking of the plastic when the set screws are tightened
  2. Eliminate the interference fit of the thrust bearing axle and make the holes a free fit. Then add set screws to prevent the thrust bearing axle in place. 
  3. Produce the thrust bearing axle spacers using 3D printing, making their lengths asymmetric to keep thrust bearing centered on the saw blade. 
I will import the bearing guide stl file into Fusion 360 and modify it as needed to get a revised part.