-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
thermostat v2.0 #4
Comments
We can ask the student to port the PIC code to the TI CPU. |
Which PIC code do you mean? |
@gkasprow yes - I generate the CTLI signal from a PWM output and a two-pole reconstruction filter (10k,100n). |
@hartytp I'm preparing second version of the PCB, without Wiznet module and Thorlabs modules. We will produce both versions at the time. Fitting both configurations in single design would cost too much work. |
@gkasprow perfect! I agree: these should be two separate designs rather than trying to fit everything on one board. The Thorlabs version gives us something we can use with minimal effort/risk of hardware bugs, the ADC version should work better in the long run but will need software development and careful hardware characterisation. |
@hartytp please have a look |
@gkasprow wow! Thanks for turning that around so fast! @cjbe any thoughts? Things you'd want to change if you did this design again? Basically that looks good to go as far as I'm concerned. Small thoughts/comments:
|
I used tiny SMD shielded inductors that saturate at 3A. |
As a humorous side remark: I've heard talks by high profile representatives of well known companies in all seriousness claiming that inductors are what's limiting miniaturization, integration, scaling, and technological progress in laser current and TEC drivers. |
@gkasprow what capacitors (voltage rating, case size, dielectric) are you using for IC1? That reg needs 1uF for stability, so we need to make sure we don't use a cheapo ceramic which gives far less capacitance when biassed. |
You won't find 1uF NPO. I used X7R. |
Yes, X7R is good for this, but we need to watch the case size and voltage rating or the capacitance can be way lower than expected. Since this is required for stability, I'd probably make it a slightly higher capacitance and use a decent voltage rating and case size. |
Can you add an annotation that the 5k11 resistors must be 5ppm/K temp co? (if you upload the altium files I'm happy to do this). |
If we swapped the AD7191 for something like AD7172-2 then the typical gain temp co is a factor of 5 lower (0.2ppm/K typical). That eliminates the ADC from the error budget. Still, however, that only makes a factor of <2 change in the overall temp co since the 5ppm reference resistors give a 0.1mK/K temp co. |
@gkasprow let's tie the ADC CLKSEL high to ensure the internal clock is correctly enabled. |
let's connect the ADC TEMP pin to the microprocessor to allow access to the ADC's on-board temperature sensor. |
ADC NC should be tied to GND according to the data sheet. |
We're driving the ADC AVDD and DVDD from the same supply. Usually, I would expect to provide separate supplies for these (e.g. connect the DVDD to P3V3A via an independent 33R resistor with a 1uF||100nF capacitor). @cjbe I guess the reason you chose not to do that in your design is that we keep the digital interface inactive during sampling so we don't need to worry about noise on DVDD. Is that correct, or is it worth isolating? |
Since the MAX1968 max output current is +-3A isn't it worth using inductors that saturate at something a bit higher than 3A. We don't want to operate the converter with the inductors close to saturation do we? |
@gkasprow it's definitely worth adding some schottky diodes to protect the ADC inputs in case the user messes up the wiring harness and connects the TEC outputs to the thermistor input. That would put 5V across the ADC inputs, resulting in an ADC input current beyond the 10mA abs maximum rating. Just use the same diodes on Sampler (to be extra sure, we can split the 100R into 50R->diodes->50R->ADC). |
not that it really matters, but afaict it's more natural to connect LX2 to tec_n and LX1 to tec_p (i.e. swap the _p and _n around on the tec connectors). |
Is it worth having a CMC on the TEC outputs to reduce EMI (there is quite a lot of common-mode noise on those outputs)? |
The TEC driver recommends having a 100uF electrolytic somewhere on the supply to smooth out ripples. Worth adding one? |
NB on @cjbe's design this wasn't necessary since we had an external 5V supply with a big output capacitor. However on Thermostat the 5V is sourced from an internal 5V SMPS. |
Okay, that's everything I can think of for this design. @gkasprow not all those suggestions need to be implemented; they're just thoughts. Do what you think is best. One closing comment, however: this design will be fairly robust to damage from various ways the output connectors could be mis-wired. There is only one thing I can see that will kill the design: shorting the LX2 output to ground. This is because the current limit measures the current from the LX1 pin (so shorting that pin to Vcc or GND shouldn't be an issue since the current limit protects it) but it doesn't check the return current. There's no way easy way around that with this TEC driver, and I think that's fine, but seems worth mentioning... |
We have to relay on 5V supply itnernal protection then. |
That can supply 8A, which is more than enough to trash one of the max chips. I don't think there is any way of getting around this; mis-wiring the connector so that TEC_N, but not TEC_P, is shorted to V+ or GND will always kill this chip. |
@gkasprow anyway, I don't think this needs to turn into a multi-round review. Do what you think is best based on my feedback, and let me know when you're happy with the design. Once that's done I'll order a few boards from TS to play with. |
hmmm let's see @gkasprow. Here is a really crude analysis (correct me if I'm wrong here):
That's easily doable with appropriate diodes. However... The more I think about it, the more I think the diodes were a bad idea. On second thoughts (as I pointed out above) given the design of the TEC controller IC, we can never make this circuit robust to all kinds of shorts between the various pins on the connector. So, is there any point in working hard to make some combinations work if it still dies when the TEC controller is shorted to GND? Better to keep it simple and rely on some common sense from the user not to kill it. |
I already added the diodes. If we discover that they ruin our temp stability, we can always remove them. |
Sounds good @gkasprow. Anyway, am I right in thinking that the leakage will be significantly lower when the reverse bias is only 1V or so? Once we have the boards, we can easily make a temperature stability measurement to confirm that the performance matches our calculations. Use one channel to perform an open-loop measurement of the "temperature" of a precision 10k resistor, and use the other channel to temperature control the Thermostat board. Look at the reported "temperature" of the resistor as we change the actual temperature of Thermostat. |
This is what I expect and probably leakage current won't be an issue here. |
@hartytp please have a look at newest release. |
Great, thanks! @jordens FWIW I'm planning to order a few of these next week, so any feedback you have before then will be gratefully received.
FWIW, a Git branch is probably a better way of doing that. |
These are two modules that don't have many common things. There won't be common firmware, chipset is different. |
Look beautiful @gkasprow! Many thanks for doing that, another great design! While I'd be happy to send it off to manufacture as it is now, I had a few final thoughts:
|
CMC wont saturate up to 5A |
added power budget. We will fit within 20W. Continous PoE converter Pmax is 24W, 30 peak. |
Splendid :) No further feedback from me then. Let's give others until end of Weds to give any further comments and then produce a batch (email Greg/Me/Wojciech if you want some). |
@gkasprow well, the only other comment I have is about the layout. The 24-bit ADC is packed in tightly between the microprocessor and the TEC driver, so there is quite a bit of potential for EMI issues. I don't think there is much we can do to improve this without making the board quite a bit bigger, so let's build one and have a go. We can easily test this by using a precision 10k resistor instead of a thermistor and looking at the rms noise in the ADC measurements. We can also look at the change in measured temperature as a function of the TEC current with the device running open loop. Anyway, hopefully this won't cause any issues, but it's worth being aware of it. |
I designed it in such way to make sure the return currents don't pass via the ADC circuit. |
Okay, good! :) |
|
For me, using the MAX chip mainly comes down to convenience. Its performance is pretty good, it packs a lot into a small board area with fairly low EMI, it's relatively cheap, and, most importantly, it reduces the amount of design + software development work we need to do to get a high-quality board up and running. If we're going to switch to a roll-your own solution that requires more work (and probably costs more, requires more board space etc) then there should be a strong performance reason to do so. Do you think the MAX IC's noise etc performance won't be good enough for us?
I agree that it's conceptually less neat than rolling our own, but that doesn't mean it's not the best means of achieving the result we want. If you're keen on an H bridge approach, can you suggest a topology + some components you'd like to use? |
I'm not suggesting to roll your own H bridge. There are small fully integrated H bridges with gate drivers and power-MOS, some even with current sensing, and multiple channels in one package. And I am not doubting the specifications of the MAX. I'd just try to get a bridge driver that doesn't come with its own PWM modulator and current loop. Instead I would look at those integrated bridges/drivers and add the missing features (current/voltage sensing/limiting). That all looks well within the scope of the on-chip ADCs (I/V sensing and limiting is not a precision or high resolution job). Instead of one modulated control signal going to the driver you'd now have two. You'd save on the filtering components and you'd get voltage monitoring as well. What else is missing that you need the MAX for? Does it have better performance than a typical bridge driver? From the datasheet it is meant to be used in an analog loop, not in a digital one. |
Well, it hinges on someone doing the design. I'm short on time right now and the MAX IC will be absolutely fine for all the applications I have in mind, so it won't be me who does all the legwork for this. If you can convince someone else to do the design work required for this then it's fine by me. What do you think @gkasprow
By this point, there isn't much common between the two boards, and I have some temperature control needs coming up for which the Thorlabs chip is a bit marginal. So, unless someone is planning to test the Thorlabs version of Thermostat reasonably soon then I'd prefer to press on to manufacture. |
@jordens The MAX works at 1MHz. Even with 10 bit PWM you would need 1GHz clock in CPU. One can do some tricks with 8 bit PWM and noise shaping but IMHO it is not worth the effort. |
The PWM from the CPU to the MAX will also need dithering to get the needed resolution. There is no change from that. |
Even if you were to stay at plain PWM from the CPU, you get even more resolution by adjusting the frequency. The continued fraction algorithm to do that will fit just fine into the ~10ms sample rate. I assume that's what @cjbe was already doing. |
I"d like to treat the version with MAX chip as a first iteration. |
@gkasprow It sounds like the plan is to keep the MAX IC for Thermostat v2.0. If we decide it's not good enough, we can replace it in v3.0. Thermostat v2.0 will give us a high-performance board that we can develop most of the required firmware on. Please could you update following @jordens comments (copied below) and then upload a release and close this issue?
|
done for both designs. |
Thanks! Okay, let's close this. We'll keep the new TEC driver design in mind for v3.0 |
We've had some problems recently with a common commercially available temperature controller, which we've tracked down to inadequate EMI filtering in the temperature controller AFE and use of unscreened cabling in the wiring harness provided by a different vendor (the 10k NTC has a 100uA sense current so is a high-impedance node which is very prone to pickup even at 50Hz).
To solve this, I'd like to swap out these temperature control units for Thermostat, but there are two annoyances:
So, I'd like to revive the discussion about replacing the Thorlabs chip with something along the lines of @cjbe's design based on a 24-bit ADC and the Maxim TEC driver IC. As a reminder, the big win from using a 24-bit sigma-delta ADC is that the sample rate is high and the ADC includes very good digital filtering (including extreme rejection of 50/60Hz signals). Combined with a basic CM/DM analog RFI filter, this provides a level of EMI rejection that is essentially impossible to achieve in the analog designs that seem to be used in almost all COTS units. Using @cjbe's prototypes of this design, we were able to achieve stabilities better than 100uK long term without issue.
As I see it, the main challenge here is software. The hardware redesign is very easy and I'd be happy to do that myself using @gkasprow's Altium library. The more involved part is writing decent software: command handler; simple PI(D?) loop; some basic features like thermal runaway detection, current limiting, anti-wind up, etc. I don't have time to do that part. @gkasprow do you have a student who might be interested in doing that? (otherwise, if anyone is potentially interested in funding M-Labs to do this then let us know!)
The text was updated successfully, but these errors were encountered: