Saturday, August 24, 2013

Alive with basic functionality!

Today I posted source code version v0.0.3 on the links above, this represents a usable source stream on actual hardware.  Over the past few weeks I have been fine-tuning the PID factors, and debugging the auto-size determination.   With today's release I think the core and basic functionality works:


  • Regulator ramps up slowly
  • Will auto-size, including re-triggering when the RPMS have changed substantially
  • Regulators to Voltage, Amp, and/or Watts as configured.
  • AND - key here:  Exits Acceptance phase when the battery is actually  FULL as indicated by Amps, not time...

ASCII communications is working well, I added a "RTS;" string to indicate the regulator is resetting either due to a recoverable fault, or in response to a change to the regulator EEPROM saved configurations.

Two areas not tested / fully debugged:
  • Dual regulator synchronization and communication.
  • Temperature probes - I am not happy with the assemble method for these NTC probes.
  • Bluetooth - More thought need to be put into the initialization of this device.

I also am not happy with some of the hardware design elements, specifically the following subsections will need to be looked at more closely:
  1. Use of Zener Diodes for clamping input voltages (as opposed to discrete Diodes).  They show an impedance that impacts high impedance lines (ala the NTC probes)
  2. VBat pre-scaler - Also an impedance issue on both the INA-220's and the raw Atmel A/D. 
  3. Amps pre-scaler - Already noted, the INA-220's have a max voltage limit of 28v, so will need to use gnd based shunt, or do some pre-conditioning for allow for a high amp shunt.
  4. Switching power regulator.  I am getting issues with I2C noise and faults whenever I start the main engine, and am thinking it might be related noise coming in via the Enable line.
  5. FET Driver;  The current chip is working well, but will be a bit stressed when doing Equalization on 48v systems.  

I have ideas for each of these:
  1. Return to clamping diodes instead of zeners - might have to use SMT parts due to PCB space though . . . 
  2. There is an improved version of the INA220 called an INA226 with higher Vmax and better resolution on sampling.  I MIGHT be able to get away using resistor dividers using it, but in worst case will need to add perhaps an op-amp pre-scaler.  In any case, I am thinking of abandoning the switching ckt for the prescaler, as well as the RAW A/D sampling and just go with a fixed ckt to cover the whole voltage range.
  3. Already looking at adding an AD8217 as a level shifter for the Amps shunt.
  4. Need to scope the power-supply ckt, but one improvement idea I have is to use the Enable pin as a true Enable driving say a FET and relocate the LM5008's power source to the Alternator Alt+ line.  I figure with the heavy cables this will be much cleaner - and I can apply effective filtering to the Enable line driving the FET much easier and at lower cost than trying to filter out Enable based noise feeding the switching supply directly.
  5. Will look at other FET drivers - am going to have to break down and add an external charge pump though :-(
I also need to consider to keep the largely through-hole PCB design, or give up and switch over the SMT parts.  I am finding the Through-hole parts harder to locate, some parts not even available anymore, and at times more costly...  Have been looking at toaster-over and electric fry-pan approaches to reflowing small batch SMT boards :-)


OK, will likely lose internet connection for a few weeks - but this code-drop will give some hope to those who case!







No comments:

Post a Comment

Note: Only a member of this blog may post a comment.