Author Topic: DIY Modular Test Equipment Project  (Read 50142 times)

0 Members and 1 Guest are viewing this topic.

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
DIY Modular Test Equipment Project
« on: June 02, 2016, 02:07:10 pm »
Oh, hi there!

If you scroll down you might realize I've been consistently biting off slightly more than I can chew.

What started off with me trying to design and build myself a proper bench power supply has grown into a small collection of bits of test equipment being designed as functional modules sharing a common communication bus which is yet to be named.

There is no set date for completion of anything as I'm doing this in my spare time and don't expect regular updates. Since I'm stubborn and I've put a lot of time and effort into this I'm not going to abandon it and I've learned a lot so far.

Enjoy!

Almost forgot... UPDATES below.

UPDATES

2018.02.25

First draft of the UI is now on GitHub. Check the draft branch of the repo.

2018.02.26

First draft of the Waveform Generator + Frequency Counter module is up on GitHub. Repo here.

2018.02.27

First draft of the Regulator for the Digital part is also on GitHub. Link to the repo.

2018.02.28

First draft of the Regulator for the Analog part is also on GitHub. Here's the link to the repo. Damn, too many firsts :P

2018.03.04

Finished the PCB layout for the UI and yes, it's rev.0 again. Some MCU pins were moved around. It probably won't be the final version as some tweaking is still required.

2018.11.25

Updated everything. Switched to STM32F101 MCUs.

2019.12.27

Waveform Generator is now almost finished.
« Last Edit: December 27, 2019, 04:13:24 pm by void_error »
Trust me, I'm NOT an engineer.
 
The following users thanked this post: cellularmitosis

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project - User Interface
« Reply #1 on: June 02, 2016, 02:11:40 pm »
User Interface

This is the control panel shared by all the different modules. I tried to keep it as basic as possible, as well as easy to use. Nothing too fancy here.

User accessible features:
  • 128x64 2.8 inch monochrome LCD display - ERC12864-655
  • 4 square push buttons, backlit, function displayed on LCD - Omron B3W-9
  • 2 pushable quadrature encoding switches
  • Buzzer, in case you want those annoying beeps, can be turned off
  • USB connectivity via a USB-UART module, initially as USB-serial device, planning to include SCPI commands
  • Bootloader for relatively easy firmware updates

Specs:
  • DC input: 5V (3.3V onboard LDO)
  • Optional fan control/monitoring pins
  • Microcontroller generated synchronization signal, used to synchronize DC-DC converters (SYNC)
  • Microcontroller clock output (BUS_CLKR)
  • Off-board connector (2x10 pin IDC) for communication with other modules via 1-wire, I2C, UART

Hardware:
  • STM32F101VC
  • EEPROM for saving calibration data and presets
  • more details coming soonTM

USB-UART module
  • No idea anymore, could be anything
  • SiLabs digital isolators on the UART side
« Last Edit: November 25, 2018, 02:37:18 pm by void_error »
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
These two are going to share the same PCB

Waveform Generator

Features/Specs:
  • Sine wave / Triangle wave output - 0.1Hz - 10MHz for sine, 0.1Hz - 250kHz for triangle
  • Adjustable amplitude (up to 10VPP @ 50ohm) and DC offset (-5V...+5V)
  • Square wave (uses DDS chip) / PWM output (from UI MCU or local MCU) adjustable output level, frequency values for the PWM are limited by the capabilities of the User Interface MCU or local MCU
  • Output driver with adjustable current limit for Sine / Triangle

Hardware:
  • AD9834 DDS waveform generator chip
  • AD603 Variable Gain Amplifier
  • LMH6321 output driver (sine/triangle only), adjustable output current limit
  • REF2041 dual output voltage reference
  • [https://www.analog.com/media/en/technical-documentation/data-sheets/ad5761_5721.pdf]AD5721[/url] 12-bit DACs for setting offset & amplitude

Frequency Counter

Features/Specs:
  • 100MHz maximum input frequency
  • Adjustable input trigger level
  • Selectable divide by 10  or by 1prescaler
  • External 10MHz clock reference input

Hardware:
  • STM32F101RC
  • LMV7219 high speed comparator
  • MCP41050 digital potentiometers
  • glue logic
« Last Edit: November 25, 2018, 02:41:32 pm by void_error »
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project - Modular DC Electronic Load
« Reply #3 on: June 02, 2016, 02:15:11 pm »
Modular DC Electronic Load[OUTDATED]

Features/Specs:
  • 200W maximum continuous power dissipation per module depending on the cooling used, calculations were done using one cheap desktop CPU heatsink for each two MOSFETs
  • Two ranges: 50V maximum @ 4 A or 12.5V @ 16A - not a final spec, subject to change
  • Fan Control via the Aux Digital Power Board
  • Overtemperature protection
  • Overvoltage protection
  • Overcurrent protection
  • Optional on-board microcontroller for the "smart" load configuration
  • Two modules can be connected together to make a 400W load - subject to change (it's quite tricky to implement)

Hardware:
  • DAC: AD5662
  • ADCs: AD7683
  • LM56 temperature sensors in thermal contact with each MOSFET
  • LM4132-4.1 4.096V reference for DAC and the ADCs
  • 2 IRFP460 N-channel MOSFETs as current sinks
  • A bunch of op amps (see schematic)
  • PIC16F1619 optional microcontroller for the "smart" load configuration, will use the PID loop of the Math Accelerator module for Constant Voltage/Resistance/Power functions
  • Dirt cheap AMD CPU cooler
« Last Edit: November 25, 2018, 02:42:26 pm by void_error »
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project - Bench Power Supply
« Reply #4 on: June 02, 2016, 02:18:04 pm »
Bench Power Supply[OUTDATED]

Features/Specs:
  • Configurable for different output voltages, output currents and number of channels
  • Two current ranges
  • Overtemperature protection
  • Overvoltage protection
  • Overcurrent protection

Hardware:
  • DACs: AD5662
  • ADCs: AD7683
  • LM56 temperature sensors in thermal contact with each post-regulator BJTs
  • LM4132-4.1 4.096V reference for DACs, ADCs and OTP circuit
  • A bunch of op amps
  • It can be built with or without digital control

« Last Edit: November 25, 2018, 02:42:37 pm by void_error »
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project - Aux Power Supply
« Reply #5 on: June 02, 2016, 02:20:17 pm »
Aux Power Supplies

Provide the required supply voltages for the User Interface / Waveform Generator / DC Electronic Load Modules

Voltages required by each module:
  • User Interface: +12V or +7.5V
  • Waveform Generator:
    • Digital: +7.5V
    • Analog: +5V, -5V, +15V, -15V
    • The digital supply rails use switching regulators, while the analog supply rails use linear regulators.
  • DC Electronic Load Module: +12V, +3.3V provided by the User Interface via the IDC ribbon cable
  • Lab Power Supply: +3.3V provided by the User Interface via the IDC ribbon cable, powering the digital isolators

Aux Analog Power Board:
  • +/-15V& +/-5V (maximum current limited by the maximum allowable power dissipation)
  • uses 78xx/79xx and 78Lxx/79Lxx linear regulators

Aux Digital Power Board:
  • +7.5V or +12V @ 2A
  • uses an LT3680 step-down DC-DC switching regulator
« Last Edit: November 10, 2016, 05:42:26 pm by void_error »
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #6 on: June 02, 2016, 02:22:51 pm »
[reserved for future use]
Trust me, I'm NOT an engineer.
 

Offline BFX

  • Frequent Contributor
  • **
  • Posts: 376
  • Country: sk
Re: DIY Modular Test Equipment Project
« Reply #7 on: June 02, 2016, 07:23:31 pm »
I have similar idea for such 15 years :D But never was time to start  :-DD
Looking forward to progress  8)
« Last Edit: June 02, 2016, 07:26:27 pm by BFX »
 
The following users thanked this post: 001

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #8 on: June 02, 2016, 07:49:42 pm »
You would spend thousands of hours of work to complete this project. Is it really worth it?
Totally worth it. It's not even that complicated and most things are almost complete as far as the simulations and schematics go.
I'm doing this to learn a few more things, I could have bought all the test equipment.
You can buy a very nice used HP 33120A arbitrary function generator for ~300€.

Aux power supply function can be fullfilled using an off the shelf multi-output industrial power supply. You can find plenty of them in surplus sales for a bargain price. Example : http://www.ebay.com/itm/291682783473
Where's the fun in buying?
Trust me, I'm NOT an engineer.
 

Offline SaabFAN

  • Frequent Contributor
  • **
  • Posts: 735
  • Country: de
Re: DIY Modular Test Equipment Project
« Reply #9 on: June 02, 2016, 08:09:28 pm »
You would spend thousands of hours of work to complete this project. Is it really worth it?

You can buy a very nice used HP 33120A arbitrary function generator for ~300€.

Aux power supply function can be fullfilled using an off the shelf multi-output industrial power supply. You can find plenty of them in surplus sales for a bargain price. Example : http://www.ebay.com/itm/291682783473

Nothing hard about building an AWG. In the simplest form, it's just a N-Bit counter, an SRAM and a R2R-Ladder as a DAC with an amplifier behind it.
Can be easily assembled on a euro-card, or put inside a CPLD (the cheap chinese Signal-Generators are proof that the hardware is simple and easy to make).
What's a little bit more difficult is the software, but nothing one can't handle by smashing together some already made pieces of software - The hardest part is probably the software that runs on the PC to create and upload the waveform.

The other modules are excellent beginner-projects and provide good learning-experience.

Offline German_EE

  • Super Contributor
  • ***
  • Posts: 2399
  • Country: de
Re: DIY Modular Test Equipment Project
« Reply #10 on: June 02, 2016, 08:11:45 pm »
You would spend thousands of hours of work to complete this project. Is it really worth it?

Hell yeah! Why? Because it's FUN.

Rightnow I have a home made DC Power Supply, DC Dummy Load, 10 MHz Frequency Standard and RF Power Meter. On the ham bench there's also a home made DC Supply, home made Antenna Tuner and a home made transceiver that is a continuous work in progress. Only the scope, multimeter and VNA were made in a factory.
Should you find yourself in a chronically leaking boat, energy devoted to changing vessels is likely to be more productive than energy devoted to patching leaks.

Warren Buffett
 
The following users thanked this post: TiN

Offline TiN

  • Super Contributor
  • ***
  • Posts: 4543
  • Country: ua
    • xDevs.com
Re: DIY Modular Test Equipment Project
« Reply #11 on: June 03, 2016, 01:50:00 am »
Subbed.

I'd suggest 14-bit DAC for DC load. That will allow to set current in 1mA steps with some wiggle for calibration. Sometimes it's nice to have.
Or at least two ranges (low current, high current) like in some production DC loads. ;)
YouTube | Metrology IRC Chat room | Let's share T&M documentation? Upload! No upload limits for firmwares, photos, files.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #12 on: June 03, 2016, 08:22:28 am »
Subbed.

I'd suggest 14-bit DAC for DC load. That will allow to set current in 1mA steps with some wiggle for calibration. Sometimes it's nice to have.
Or at least two ranges (low current, high current) like in some production DC loads. ;)

Most likely going for the higher resolution DAC. 12-bit should do, that's 4096 steps and a suitable candidate is the DAC121C085. Same pinout as the DAC081C085, just more bits. Same 12-bit DAC will be used for the Lab Power Supply.

There's also a 10-bit variant, the DAC101C085.
Trust me, I'm NOT an engineer.
 

Offline spudboy488

  • Regular Contributor
  • *
  • Posts: 136
Re: DIY Modular Test Equipment Project - User Interface
« Reply #13 on: June 03, 2016, 11:42:13 am »
User Interface

Hardware:
  • PIC16F18857 8-bit microcontroller, relatively new part but extremely versatile, this is the brain of the User Interface
  • PIC16LF1455 8-bit USB microcontroller, used as an USB-UART interface
  • MCP7940N Real time clock/calendar with battery backup, for optional data logging, hmm, I might even program the UI as an alarm clock


Look at the MCP2200 if all you're using the PIC16LF1455 for is a UART. IC plus 12 MHz resonator is all you need. No programming of the part required.[/list]
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #14 on: June 03, 2016, 02:06:01 pm »
Look at the MCP2200 if all you're using the PIC16LF1455 for is a UART. IC plus 12 MHz resonator is all you need. No programming of the part required.
I intend to keep the micro for USB-UART, offers more versatility which might come in handy later. Maybe I drag a friend of mine who's a programmer, to write the PC software to control things, he's pretty good with C#. That would mean programming the micro as a USB HID device, not too complicated since it's going to be based on one of Microchip USB examples / demos, porting the code from the 16(L)F1459 to the 1455 isn't too difficult as I've already ported USB stuff from the 16F45K50 (used in the microchip demo code) to the 25K50 and added my own stuff on top of it with o problems.

I probably haven't mentioned it before or at least not too clearly, but the User Interface board is also designed to be used as development board. For example, since it has both SPI and I2C it can be used to test code for different peripherals with the LCD providing debug data... and then there's the alarm clock :-DD. I'll actually program one for that sole purpose, just for fun, it already has buttons, a buzzer , RTCC and a display.
Trust me, I'm NOT an engineer.
 

Online JPortici

  • Super Contributor
  • ***
  • Posts: 3452
  • Country: it
Re: DIY Modular Test Equipment Project
« Reply #15 on: June 03, 2016, 04:47:32 pm »
Why use two pics and not directly a usb capable one?

Keep posting. I think i am in a rather simillar situation (on the verge to design an electronic load because i'll soon need one.. and i have to keep my mind occupied these days)
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #16 on: June 03, 2016, 06:22:25 pm »
Why use two pics and not directly a usb capable one?
Time and money.
I did look into some 16-bit PICs with USB, they're only slightly more expensive. However, what I looked at didn't have as many peripherals and/or relocatable pins which would have made both firmware and PCB layout a bit more difficult.
There's also the 18F series with USB, but they don't have a PPS module or as many peripherals (which work independently of the core by the way). Initially I wanted to use those, having previously used them.

The USB capable micro I mentioned is an optional extra and can be left out.
Another reason is the "smart" version of the DC Electronic Load which will use the same 16F18857 micro as the User Interface, also sharing some bits of code like the fan control and I2C code (not too much but it's less work so it takes less time).
Trust me, I'm NOT an engineer.
 

Online JPortici

  • Super Contributor
  • ***
  • Posts: 3452
  • Country: it
Re: DIY Modular Test Equipment Project
« Reply #17 on: June 03, 2016, 07:48:17 pm »
Yes. Those pic24 are more like glorified pic18.. I never liked to use those.
and the dspic with usb is much, much, much more expensive.

I also gave another quick look at the catalog and usb pic16 are only up to 20 pins. Too small, i agree with you. A 28 pin smart pic16 with usb would have been the best.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #18 on: June 03, 2016, 07:49:14 pm »
Ran into a small problem:
The User Interface uses 3.3V logic while the Waveform Generator uses 5V. Logic level shifting is required.

There's a level shifting circuit using a small N-channel MOSFET which is quite popular and it'll do the job for I2C although I think it adds a singificant amount of capacitive loading. I don't plan to go anywhere above the 400kHz I2C fast mode so I think signal integrity won't suffer too much but correct me if I'm wrong.

SPI is going to run at the highest speed supported by the slowest device on the bus - the MCP3201 - which is 1.6MHz, so the simple circuit used for I2C won't do the job.

The Waveform Generator already uses a level shifting buffer for the square wave / PWM output, a 74LVC1T45 so I could go that route.

Since I have both SPI and I2C I'm using an I2C I/O expander for the SPI chip select on the Waveform Generator board so the SPI connector only has SCK, SDI and SDO.

There's going to be a +5V rail available on the Aux Digital Supply, sharing the same connector that goes to the User Interface board so I could do the level shifting there.

What's the best choice for level shifting on the SPI bus? I could post an unfinished schematic if it helps more.
« Last Edit: June 03, 2016, 08:23:05 pm by void_error »
Trust me, I'm NOT an engineer.
 

Online hans

  • Super Contributor
  • ***
  • Posts: 1626
  • Country: nl
Re: DIY Modular Test Equipment Project
« Reply #19 on: June 03, 2016, 10:19:47 pm »
Yes. Those pic24 are more like glorified pic18.. I never liked to use those.
and the dspic with usb is much, much, much more expensive.

I also gave another quick look at the catalog and usb pic16 are only up to 20 pins. Too small, i agree with you. A 28 pin smart pic16 with usb would have been the best.

PIC18 and PIC16 architectures are very similar. And I don't mean that in a positive way. The architecture is clearly not optimized for todays complex programs written in C and accessing 4K of RAM (that PIC in particular has 64 banks!). It will probably run and do it's job, but given it's limits.

PIC24 is completely different architecture. The instruction set is tailored to C which results in much faster code, it has a vectorized interrupts, proper software stack, etc.
dsPIC shares the same PIC24 basic CPU core, but has DSP instructions you specifically have to use. They are nice for higher throughput systems, but not a necessity for general purpose stuff.

Personally the only reason I would choose a PIC16 is if I can save 1-2 chips using an (unique) onboard peripherals (like the 24-bit measurement timer). However if that is not the case, I would always start searching at PIC24 or ARM.
I can understand bringing out the USB UART chip for a different reason; so you can isolate the UART to PC (this is test equipment after all). This is possible with USB but likely more complex/more expensive.

However for a 28-pin PIC24 my go-to chip is the PIC24FJ64GB002. Sure it has a few less I/O and PPS pins than the PIC16F18857, but if that's a problem I would opt for the PIC24FJ64GB004.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #20 on: June 03, 2016, 11:18:43 pm »
Is it really necessary to isolate the UART? I know it can be done with 2 optocouplers for less than $1... H11L1 comes to mind.

The Waveform Generator will be mains earth referenced, the DC Load modules will be isolated from the UI, same thing with the Lab Power Supply.

Actually... changing* from a 16LF1455 to a 16F1455 and powering it off the USB +5V and adding two optos with some resistors would do the job.
*so no 3.3V regulator would be required

I did use some (actually quite a lot) of H11L1s in a design, if resistors are chosen carefully you can easily reach 230.4k BAUD with a small but almost symmetrical delay between input and output rising and falling edges.

PIC18 and PIC16 architectures are very similar. And I don't mean that in a positive way. The architecture is clearly not optimized for todays complex programs written in C and accessing 4K of RAM (that PIC in particular has 64 banks!). It will probably run and do it's job, but given it's limits.
Yup, they're almost the same, the only thing I noticed on the PIC18s that PIC16s don't seem to have is the 8-bit x 8-bit hardware mutiplier. Most 18F also support higher clock speeds.

PIC24 is completely different architecture. The instruction set is tailored to C which results in much faster code, it has a vectorized interrupts, proper software stack, etc.
dsPIC shares the same PIC24 basic CPU core, but has DSP instructions you specifically have to use. They are nice for higher throughput systems, but not a necessity for general purpose stuff.

Personally the only reason I would choose a PIC16 is if I can save 1-2 chips using an (unique) onboard peripherals (like the 24-bit measurement timer).
At some point I thought about using a PIC24 for the UI but after looking confused at the datasheet and thinking about how much code would be required to make it work since it doesn't have the onboard peripherals the 16F18857 has I gave up on the idea.

Two relatively uncommon peripherals the drove my decision to use the 16F18857 are the Signal Measurement Timer, makes reading the fan RPM a piece of cake, just spits out the period between pulses, and the Numerically Controlled Oscillator which will be the Waveform Generator's square wave source. Haven't completely understood how to use it so I've got some reading to do.
Trust me, I'm NOT an engineer.
 

Online JPortici

  • Super Contributor
  • ***
  • Posts: 3452
  • Country: it
Re: DIY Modular Test Equipment Project
« Reply #21 on: June 03, 2016, 11:45:19 pm »
Older PIC24 are very close to pic18 in both the core and the peripherals.. the pic24hv family for example. The FJ is a much different beast, nearer to dspics but with no dsp core. still, I have no real use for most pic24 (if i need 16 bit arithmetics i also need the dsp... and dspics have nicer peripherals.)

Void Error has a point: the power of the modern PIC16 lies in its peripherals. with these new chips i mostly just have to move bytes around, call tables and the software is done.
(And they have had linear memory access, along bank switching, for a very very long time.)
 

Offline SaabFAN

  • Frequent Contributor
  • **
  • Posts: 735
  • Country: de
Re: DIY Modular Test Equipment Project
« Reply #22 on: June 04, 2016, 12:59:36 am »
Subbed.

I'd suggest 14-bit DAC for DC load. That will allow to set current in 1mA steps with some wiggle for calibration. Sometimes it's nice to have.
Or at least two ranges (low current, high current) like in some production DC loads. ;)

Just a little note here: Using old components bought on ebay, or from Grandpas part-box is often really worth it.
I have an almost finished (Haven't built a case yet) DC-Load flying around somewhere that uses a Ferranti 8-Bit DAC, a 4066 to switch between 2 current-ranges and an LM324 as the controlling Op-Amp on a Euro-Card. It's quite a mess because of the parallel data-bus, but you can debug the circuit with a Multimeter instead of a digital scope with Serial Bus-Decoding.
Also it looks kinda cool having some ceramic DIP-Package with a golden cap on it :)
And you can build it on Vero-Board in an afternoon instead of waiting for 3 weeks until the boards arrive.

Offline TiN

  • Super Contributor
  • ***
  • Posts: 4543
  • Country: ua
    • xDevs.com
Re: DIY Modular Test Equipment Project
« Reply #23 on: June 04, 2016, 02:31:54 am »
You can get away with a NFET and pullup resistor on SPI if speeds are slow or use more expensive Silabs digital isolators or AD ADUMs if you wish.

As of ebay parts. Its often a good way to get fancy parts, but also a non-zero chance to get remarked fakes. I got fake AD7534 DAC and even fake LM339s one time.
« Last Edit: June 04, 2016, 02:35:31 am by TiN »
YouTube | Metrology IRC Chat room | Let's share T&M documentation? Upload! No upload limits for firmwares, photos, files.
 
The following users thanked this post: Bukurat

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #24 on: June 04, 2016, 11:50:59 am »
You can get away with a NFET and pullup resistor on SPI if speeds are slow or use more expensive Silabs digital isolators or AD ADUMs if you wish.

I'm going to choose the safe route and go with some proper buffers for SPI.
The USB micro is going to be electrically isolated.
The User Interface will be mains earth referenced, same thing applies to the Waveform Generator. They're going to share the same transformer.
The DC Electronic Load modules will be isolated from the User Interface via ADuM1251 I2C isolators and probably powered off a different transformer or winding, haven't decided yet.
Right now I'm focusing on finalizing the schematics for the UI and Waveform Generator, I might post them this weekend.
One of the goals is to have as few different parts across all of the boards as possible, at least for the glue logic.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #25 on: June 04, 2016, 09:44:09 pm »
The User Interface schematic is almost finished but I thought I'd ask for a few more opinions before I call it finished.
A few component values still have to be calculated.

Trust me, I'm NOT an engineer.
 

Offline Mastrofski

  • Contributor
  • Posts: 16
  • Country: us
Re: DIY Modular Test Equipment Project
« Reply #26 on: June 05, 2016, 01:15:18 am »
Subbed.

I'd suggest 14-bit DAC for DC load. That will allow to set current in 1mA steps with some wiggle for calibration. Sometimes it's nice to have.
Or at least two ranges (low current, high current) like in some production DC loads. ;)

Just a little note here: Using old components bought on ebay, or from Grandpas part-box is often really worth it.
I have an almost finished (Haven't built a case yet) DC-Load flying around somewhere that uses a Ferranti 8-Bit DAC, a 4066 to switch between 2 current-ranges and an LM324 as the controlling Op-Amp on a Euro-Card. It's quite a mess because of the parallel data-bus, but you can debug the circuit with a Multimeter instead of a digital scope with Serial Bus-Decoding.
Also it looks kinda cool having some ceramic DIP-Package with a golden cap on it :)
And you can build it on Vero-Board in an afternoon instead of waiting for 3 weeks until the boards arrive.

I think for one-off pieces of equipment, using odds and ends is fine, but for something going into production, or something designed to be recreated by others(such as this project), sourcing components begins to become an issue.

Love the idea though! I'll definitely be following along.
 

Offline timofonic

  • Frequent Contributor
  • **
  • Posts: 904
  • Country: es
  • Eternal Wannabe Geek
Re: DIY Modular Test Equipment Project
« Reply #27 on: June 05, 2016, 04:59:26 am »
Amazing project!! Are you going to release as Open Hardware and Open Software at GitHub?

There's already a lab power supply project. Maybe a colaboraron would be possible of some kind.


Thanks.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #28 on: June 05, 2016, 08:40:54 am »
Amazing project!! Are you going to release as Open Hardware and Open Software at GitHub?

There's already a lab power supply project. Maybe a colaboraron would be possible of some kind.


Thanks.
You mean this?
Not sure yet if I'm going to make it open source, will decide after I build it.

I still have to make some changes, thinking of moving the USB micro of the UI to a separate board and have an off-board connector for UART. USB connectivity was something I don't plan to add before I have the UI board built and tested and I'll need some separate USB-UART modules anyway.
« Last Edit: June 05, 2016, 08:47:24 am by void_error »
Trust me, I'm NOT an engineer.
 
The following users thanked this post: bollio

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #29 on: June 05, 2016, 11:23:37 am »
If you're all wondering why I didn't use a SPI connection directly to the LCD and instead went for I/O expanders it's because SPI doesn't allow reading the LCD data (see UC1701 datasheet) such as BUSY status.

Modifications to the Waveform Generator have been completed, it's now time to switch from I2C I/O expanders to SPI ones for the UI as the Waveform Generator already contains one.
Trust me, I'm NOT an engineer.
 

Offline SaabFAN

  • Frequent Contributor
  • **
  • Posts: 735
  • Country: de
Re: DIY Modular Test Equipment Project
« Reply #30 on: June 05, 2016, 11:29:08 am »

I think for one-off pieces of equipment, using odds and ends is fine, but for something going into production, or something designed to be recreated by others(such as this project), sourcing components begins to become an issue.


Didn't realize that this one is intended as a (maybe commercial) product. In that case, only Components that at least "Active" or "Recommended for new Designs" should be used.
For standard-parts like diodes or transistors, there's normally a pin-compatible replacement, but ICs can become a pain real quick.

Btw. how are you planning to implement the Modularity?
- Mainframe-Style: One device with a backplane and Plug-In Modules
- Modular Construction: Complete devices that look different on the inside, but always have the same front-panel and case

Offline bktemp

  • Super Contributor
  • ***
  • Posts: 1616
  • Country: de
Re: DIY Modular Test Equipment Project
« Reply #31 on: June 05, 2016, 11:43:47 am »
If you're all wondering why I didn't use a SPI connection directly to the LCD and instead went for I/O expanders it's because SPI doesn't allow reading the LCD data (see UC1701 datasheet) such as BUSY status.
Do you need to read the data back?
I generally avoid connecting GLCDs using I2C, because it is slow. Especially in your case, because you need to send many I2C bytes for writing a single byte to the LCD (setup data byte, toggle WRITE. It looks like you need 3 I2C bytes for each write to the ouputs, so thats 9 bytes for each data byte).
The same applies for the rotary encoder. Depending on the encoder, you may need to sample the levels 100-1000 time per second otherwise it misses steps or gets the direction wrong.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #32 on: June 05, 2016, 12:10:01 pm »

I think for one-off pieces of equipment, using odds and ends is fine, but for something going into production, or something designed to be recreated by others(such as this project), sourcing components begins to become an issue.
Luckily for me there's a local distributor about 1km (actually same neighborhood) from where I live and they can get pretty much any part I want from the large distributors like Digikey and Mouser at a slightly higher price but without the $50+ shipping that I would have to pay if I got the parts straight from the overseas distributors.

I usually try to avoid sourcing parts from outside Europe, most of the stuff I order from TME. I think the Waveform Generator has all the parts available there, I'll have to double-check to be sure.

Didn't realize that this one is intended as a (maybe commercial) product. In that case, only Components that at least "Active" or "Recommended for new Designs" should be used.
For standard-parts like diodes or transistors, there's normally a pin-compatible replacement, but ICs can become a pain real quick.

Btw. how are you planning to implement the Modularity?
- Mainframe-Style: One device with a backplane and Plug-In Modules
- Modular Construction: Complete devices that look different on the inside, but always have the same front-panel and case

It's going to a combination of both Mainframe-Style and Modular Construction.

The case won't be the same but the front panel is always going to be the User Interface board.

For Waveform Generator I intend to make it a plug-in board with the BNC connectors on the front panel, whule the Aux Power Supply modules being separate boards or even stackable, that depends on how the PCB layouts turn out.

For the Lab Power Supply there are going to be several modules, with the digital isolator board plugging into the back of the User Interface board just like the Waveform Generator. I'm going to stick to 0.1 inch pitch connectors so I maintain some sort of compatibility with breadboards/arduino boards/etc.

If you're all wondering why I didn't use a SPI connection directly to the LCD and instead went for I/O expanders it's because SPI doesn't allow reading the LCD data (see UC1701 datasheet) such as BUSY status.
Do you need to read the data back?
I generally avoid connecting GLCDs using I2C, because it is slow. Especially in your case, because you need to send many I2C bytes for writing a single byte to the LCD (setup data byte, toggle WRITE. It looks like you need 3 I2C bytes for each write to the ouputs, so thats 9 bytes for each data byte).
The same applies for the rotary encoder. Depending on the encoder, you may need to sample the levels 100-1000 time per second otherwise it misses steps or gets the direction wrong.
I could get away without reading the data back but I might as well have the option to do it for example just updating a certain portion of the screen instead of the whole screen.

I did suspect I2C would be quite slow so I replaced the I2C I/O expanders with SPI ones.

The MCP23S08 expanders used have an interrupt output pin with programmable polarity, which is triggered depending on how the input pin interrupt registers are set. In other words, all the micro has to do when the expander's INT pin changes state is transfer the data. With SPI  that would be really fast, up to 10Mbits/s, depending on the UI micro's clock. With the USB-UART micro moved off-board the UI micro can run off an 8MHz oscillator (I had to use 16MHz when the clock was shared because the USB micro had x3 or x4 PLL to achieve the 48MHz clock required for USB operation), add x4 PLL and SPI can go up to 8MHz (Fosc/4).

The UI code will be heavily based on interrupts, taking advantage of all the core independent peripherals the PIC16F18857 has.
Trust me, I'm NOT an engineer.
 

Offline prasimix

  • Supporter
  • ****
  • Posts: 2022
  • Country: hr
    • EEZ
Re: DIY Modular Test Equipment Project
« Reply #33 on: June 05, 2016, 03:24:20 pm »
Didn't realize that this one is intended as a (maybe commercial) product. In that case, only Components that at least "Active" or "Recommended for new Designs" should be used.
For standard-parts like diodes or transistors, there's normally a pin-compatible replacement, but ICs can become a pain real quick.

Btw. how are you planning to implement the Modularity?
- Mainframe-Style: One device with a backplane and Plug-In Modules
- Modular Construction: Complete devices that look different on the inside, but always have the same front-panel and case

It's going to a combination of both Mainframe-Style and Modular Construction.

The case won't be the same but the front panel is always going to be the User Interface board.

For Waveform Generator I intend to make it a plug-in board with the BNC connectors on the front panel, whule the Aux Power Supply modules being separate boards or even stackable, that depends on how the PCB layouts turn out.

For the Lab Power Supply there are going to be several modules, with the digital isolator board plugging into the back of the User Interface board just like the Waveform Generator. I'm going to stick to 0.1 inch pitch connectors so I maintain some sort of compatibility with breadboards/arduino boards/etc.

Glad to see that you decided to define multi-modular solution with Mainframe-style possibility. That is ambitious project and hopefully more people will be attracted soon and decide to join you. If I "dream" about something then it's interoperability of what I made with other people designs. I don't have a problem to adopt everything that is already created to share the same "DIY-instrumentation-bus" and works under same software framework and successfully communicate with commercial instruments.

Like timofonic I vote for GitHub/Bitbucket openness in one moment because it could make a whole thing more interesting in the long run (and hopefully you are already aware of how looooooong could takes to make something in correct/usable way :)).

From my side I'm looking forward to see if your design could become a potential "target" for firmware that we are developing. Not sure for now, but if currently developed code could be ported to PIC that can save literally hundreds of hours for you.

One more thing because I been there: it's a LCD display or better to say its 128 x 64 (and monochrome) resolution. TFT LCD becomes really dirty cheap and they are not of equally dirty quality! Even if you hate "touch screen" you don't need to rely completely on it: there is no reason why encoders shouldn't be on your front panel together with touch-screen.

Finally something that I should mention on the beginning: I'm suggest to not take mechanical aspects too lightly! That can really generate a lots of frustration: because you realized that something is not accessible, cannot be mounted, have EMC or heating issue, etc. Of course today's 3D modeling, thermal modeling, etc. could help you to avoid such mistakes that will push you into another revision, but remember that you are still alone and even with 96 working hours day that will consume all your time (again I'm talking about something that will be usable for you and eventually many others). So, mind the mechanics! Define boundaries within everything will happen first.

 :-+

Online JPortici

  • Super Contributor
  • ***
  • Posts: 3452
  • Country: it
Re: DIY Modular Test Equipment Project
« Reply #34 on: June 05, 2016, 04:21:59 pm »
+1 on the tft screen. nowadays they are much cheaper than GLCDs.
One thing i wanted to try on a new project is going old school: encode the framebuffer in 4 bit per pixel and use a palette. a 320x240 screen would then need "only" 37.5 kB of ram for the framebuffer (and 16 colours are more than enough for my application.. and yours)
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #35 on: June 05, 2016, 04:41:24 pm »

Glad to see that you decided to define multi-modular solution with Mainframe-style possibility. That is ambitious project and hopefully more people will be attracted soon and decide to join you. If I "dream" about something then it's interoperability of what I made with other people designs. I don't have a problem to adopt everything that is already created to share the same "DIY-instrumentation-bus" and works under same software framework and successfully communicate with commercial instruments.

Like timofonic I vote for GitHub/Bitbucket openness in one moment because it could make a whole thing more interesting in the long run (and hopefully you are already aware of how looooooong could takes to make something in correct/usable way :)).

From my side I'm looking forward to see if your design could become a potential "target" for firmware that we are developing. Not sure for now, but if currently developed code could be ported to PIC that can save literally hundreds of hours for you.
There's still a long way until I start coding. Planning on ordering a few ERC12864-655 displays this month, it'll take another month for them to arrive so that's when work starts. They're about $10 a piece.
My general habit is to write modular code and reusing already written code, which I have a lot of, at least for peripherals, so only the display is something I might run into difficulties with.

One more thing because I been there: it's a LCD display or better to say its 128 x 64 (and monochrome) resolution. TFT LCD becomes really dirty cheap and they are not of equally dirty quality! Even if you hate "touch screen" you don't need to rely completely on it: there is no reason why encoders shouldn't be on your front panel together with touch-screen.
LCD description updated.

I don't hate touchscreens, I just like knobs and buttons more. I'm not using a touch screen because it would add more complexity to the firmware and it'll take me more time, and I've never worked with touch screens. I did look into using TFT color LCDs but I decided to go the simple way, again, because of the limited amount of time I have for this project, I also have a full-time job.

Finally something that I should mention on the beginning: I'm suggest to not take mechanical aspects too lightly! That can really generate a lots of frustration: because you realized that something is not accessible, cannot be mounted, have EMC or heating issue, etc. Of course today's 3D modeling, thermal modeling, etc. could help you to avoid such mistakes that will push you into another revision, but remember that you are still alone and even with 96 working hours day that will consume all your time (again I'm talking about something that will be usable for you and eventually many others). So, mind the mechanics! Define boundaries within everything will happen first.

 :-+

For the User interface at least, I found all the 3D models that weren't already in the DipTrace library, except for the display.

Starting next week I'm back to work at my full-time job, had this week off, so don't expect much progress on this project. I may have 3-4 hours of free time every weekday which I could use and a bit more during the weekends.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #36 on: June 06, 2016, 08:16:27 pm »
Having changed the I/O expanders going to the UI dispay from I2C to SPI I have another decision to make.

The MCP23S08 is addressable, up to 4 devices on the same bus using the same chip select. The User Interface uses two which means I have 2 addresses unused, so I can hook up 2 more chips on the same bus. Another board that uses an I/O expander is the Waveform Generator so it could share the CS pin with the ones on the UI if the address is set different from the other two.

I'm inclined towards sharing the chip select pin as it frees up an I/O pin on the UI micro. What do you think?
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #37 on: June 09, 2016, 09:11:22 pm »
Made a few more changes to the UI. Replaced the I2C I/O expanders with SPI ones (MCP23S08), both share the Chip Select pin and SPI lines. For the Chip Select that goes to the off-board SPI connector there's a separate pin.

I actually used up ALL the pins on the micro except for MCLR/Vpp (input-only and high voltage programming).
Pull-downs (33k) are ok with the programming pins, the two XOR gate inputs' capacitances are very unlikely affect programming. With the buzzer being driven by the ICSPDAT pin signal during programming I'm prepared to hear some weird noises.

PCB layout is progressing well, about two to three hours a day this week, all except one of the traces are laid out, they only need some tweaking.

Before I finish laying out the PCB I thought I'd ask for opinions/advice, just in case I missed something or made a stupid mistake on the schematic below. Feel free to ask any questions.

« Last Edit: June 09, 2016, 09:13:30 pm by void_error »
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #38 on: June 11, 2016, 12:29:21 pm »
The UI board layout is almost compete, some small tweaks and via stitching are still required.
Found the 3D models for almost all the parts so here's a sneak peek of the board. It's going to be the front panel for almost everything I build from now on.

The dual row connectors on top will either be regular pin headers for connecting to piggy-back boards or shrouded headers for using IDC ribbon cables.
The power connectors on the side can be either straight or angled.





« Last Edit: June 11, 2016, 12:33:09 pm by void_error »
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #39 on: June 14, 2016, 12:14:50 am »
Moved the mounting holes and the 6-pin UART connector on the UI board so I can make the Waveform Generator PCB narrower.

Speaking of the Waveform Generator, the schematic is almost complete, I only have to sort a few details out, spent most of the evening looking through datasheets and I still have a few questions unanswered, like the following:

If I use MLCCs for decoupling on the AD9835, do I still have to use a 10uF || 100nF pair or can I get away with just one cap? Same question for the LMH6321 output buffer.

While looking for MLCC characteristics I ran into this nice selection tool...

An unfinished Waveform Generator schematic can be found below. As always, suggestions are welcome.

Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #40 on: June 16, 2016, 07:00:44 pm »
Realized the digital output driving solution is dumb just because I can get away with using MOSFETs. Oh, and I'm at the 500 pin limit of my DipTrace Lite license, that's another reason using 74AHC125s is dumb, and yes, I was too lazy to come up with something else. I guess I just can't get away from DipTrace because I've been using it for a long time and I didn't need any tutorials to figure it out. Eagle would be another option, but the free version has a 80x100mm board limit, useless. KiCAD is a pain in the ass to use, installed it for the third time and then uninstalled it after 10 minutes, Circuit Maker has the annoying thing of having to be always online... anyway, rant over.

Mounting holes might cause me some problems, mainly because everything has to be stackable. The UI board is quite crowded, as you can see in one of the previous posts, but the 80(H)x100(W)mm size is pretty much what I'd like to stick with, or if it's not possible, something with nice round numbers. The main problem with the size comes from the fact that the Waveform Generator board has to be at least 70mm wide because of the locations of the mounting holes on the UI board and has to extend about 20mm below it because of the BNC connectors. So far it's 100(H)x80(W)mm.

On top of that there are going to be 2 Aux Power Supply boards, one with the Analog supply rails, the other one with the Digital supply rails. They'll have to be supported mechanically by the Waveform Generator board, that means 4 extra holes. No room for 4 mounting holes on the UI board but I won't need them there anyway.

Another plug-in board would be the digital isolation module for the Lab Power Supply, that will require only +5V which will be provided by the same board that powers the digital part of the Waveform Generator. I'll have to keep that in mind then I design the Aux Power Supply modules.

An alternative to the boards directly plugging into each other is to use angled pin headers and a pieces of stripboard (soldered or with connectrors) linking them together. Not very elegant but it would do the job. In any case spacers will still be required to keep everything from falling apart.

Finally, I've decided to make this Open Source, and I'll probably do some (rather amateur-ish) YouTube videos if I have enough time after I assemble and test the first boards. GitHub stuff coming after that. Stay tuned for more.

Oh, one more thing, does anyone know any free 3D modelling program that accepts .step or .wrl models and it's to use so I can check if everything fits together perfectly?
Trust me, I'm NOT an engineer.
 
The following users thanked this post: altaic, prasimix

Offline altaic

  • Supporter
  • ****
  • Posts: 45
Re: DIY Modular Test Equipment Project
« Reply #41 on: June 16, 2016, 09:25:09 pm »
Finally, I've decided to make this Open Source, and I'll probably do some (rather amateur-ish) YouTube videos if I have enough time after I assemble and test the first boards. GitHub stuff coming after that. Stay tuned for more.

Oh, one more thing, does anyone know any free 3D modelling program that accepts .step or .wrl models and it's to use so I can check if everything fits together perfectly?

Very cool, thanks!

On the open source CAD front, I've used FreeCAD and BRL-CAD, both of which have matured quite a bit in the last few years. The easiest option in this case, though, is probably Autodesk Fusion 360, which is "free for students, enthusiasts, hobbyists, and startups."
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #42 on: June 17, 2016, 10:54:02 pm »
FreeCAD seems to do the job, if I export a .wrl model of the board. Easy enough to use for basic stuff like adding boards on top of each other which is all I need to do.

With that said, having the BNC connectors of the Waveform Generator sticking out right below the UI board seems to be a bad idea so I'll move them to the left side. That implies rotating the Waveform Generator board 90 degrees and relocating a few connectors.

The result will look like this: (from left to right) BNC connectors -> Display -> Encoders. Buttons right under the display as seen in one of the previous posts.

I'll start working on it after my badly needed 12 hours of sleep...
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #43 on: June 18, 2016, 10:53:56 am »
Had a few 3D models for the pin header corresponding sockets used to interconnect the boards and started looking around. TE Connectivity seemed to have all the 3D models I needed.

Unfortunately their servers give me this after a few attempts. :wtf:
"(error 21) [ERR_NO_RESOURCE_AVAILABLE] CoreApi(allocate) A predetermined resource limit has been exceeded. Further connection attempts will be refused until sufficient resources are available. Your patience is appreciated. Please try again later."
:palm:
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #44 on: June 18, 2016, 11:42:07 am »
Found the 3D models elsewhere but had to register to be able to download.
Anyway, problem solved which means I can post a nice 3D preview of two of the nearly completed boards, the UI and the Waveform Generator.











Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #45 on: June 18, 2016, 10:37:07 pm »
I was doing thermal calculations for the different components which are going to heat up, like the linear voltage regulators for the +/-15V rails on the Aux Analog Power Supply module and the sine/triangle output driver of the Waveform Generator, the LMH6321.

Since the LMH6321 comes in a surface mount package there's a limit of how much power it can dissipate with only the PCB as a heatsink and also trying to stay away from the SMT heatsinks.

The datasheet says 300mA maximum output current, that's 15V into a 50 ohm load, assuming a dead short on the output. The output of the buffer doesn't swing to the supply rails so it's not really going to have to output more than 250mA. Worst case is outputting half the supply voltage - 7.5V - and that's 1.125W.

If the using the PCB as a heatsink doesn't do the trick I've got another solution which is already implemented in hardware. I can set the output current limit depending on the set output voltage, all in the micro on the UI board.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #46 on: June 20, 2016, 02:22:14 pm »
Connectors, connectors, connectors... and some more connectors.

This is when the 3D preview comes in really handy. I'm trying to make the boards as versatile as possible which means they must accept both straight and angled connectors. For the whole modular assembly of boards straight 0.1 inch headers will do the job just fine, no drama here. Angled PCB headers are not a problem either, unfortunately they're not keyed and you can plug stuff into them the wrong way around and we all know what happens afterwards.

Messing around with connector placement over the past two days trying to make the boards accept different types of 0.1 inch pitch connectors I found that the best placement for the connectors is at the top and bottom, with none going off to the sides.

This allows using both angled and straight pin headers as well as the keyed KK 2.54 connectors from Molex pictured below. Just making sure I don't plug the power connectors in backwards... :scared:

Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #47 on: July 05, 2016, 11:56:35 am »
Looks like the first layout pass for the UI board wasn't good enough and it also made the Waveform Generator board layout not to easy so it was back to almost square one. I wasn't expecting everything to be perfect first try anyway. Not even second try but I'm on the right track.

Being a modular design implies the use of a lot of mounting holes and a lot of boards that have to stack up.
Since the UI is actually the front panel it'll most likely be the only board which has connections on only one side (back side, the front side is the front panel). Most of the other boards will have connectors to both sides.

I managed to stuff a lot of components in a small space for cost reasons but I realized that for more flexibility I'd need more mounting holes, 8 just wouldn't cut it.
This would allow for extra combinations between modules stacking up in more ways, like this:

[UI] : [Waveform Generator] : [Aux Digital Supply][Aux Analog supply]

or

[UI] : [Aux Digital Supply][USB - UART]

or

[UI] : [Digital Isolators] : [Aux Digital Supply]

For the bigger modules like the DC Electronic Load or the Lab Power Supply the data connections (SPI/I2C) will be made using ribbon cables. I'm trying to keep the off-board wiring to a minimum.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #48 on: July 12, 2016, 07:58:12 pm »
Took a small but needed break from this project and it seems to have paid off.

The UI board seems to be sorted out, only a few more minor tweaks required... maybe(*)... wait, did I say that before?

Anyway, I moved on to another board that has to fit on the back of the UI board and that's the USB-UART module.
It's nothing fancy, just a PIC16F1454 with a few connectors and some optocouples so I thought why don't I make it more versatile, able to support some add-on modules such as RS-232 or RS-485 outputs.

Back to the Waveform Generator board again, I'll have another go at it this weekend probably. The tricky part is getting everything correct, both mechanically and electrically. In more detail, that boils down to BNC connector and other component placement relative to the LMH6321 output buffer while keeping the analog and digital signal paths clear of each other and at the same time have enough room to fit two power supply boards on top of that which will have to share a few components in some configurations (don't want to go into more details, it's a bit hard to explain).

(*) If you look below you might notice U5 (EEPROM) can be moved and J5 (Fan Connector) taking its place. Also, I color-coded a few traces as follows:
  • YELLOW:   +12V
  • ORANGE: +3.3V
  • PINK:       UART
  • GREEN:    I2C
  • BLUE:       SPI

Here's the UI board as viewed from the back, the display and controls along with the buzzer are on the other side:



And in 3D, with an example of the possible connector configurations:

Trust me, I'm NOT an engineer.
 
The following users thanked this post: gbyleveldt

Offline pmc

  • Contributor
  • Posts: 10
  • Country: us
Re: DIY Modular Test Equipment Project
« Reply #49 on: July 13, 2016, 04:15:41 am »
I just registered, and read this topic. So here goes the n00bish first post...

A couple of things:

1. You were looking for an alternative to DipTrace and free 3D modeling.
For schematics & layout, check out EasyEDA. From the little I've played with it, it seems to work. And it's free.
For 3D, check out OnShape -- a relative newcomer offering no-apologies parametric CAD for free. They claim to import step. Free accounts limit *private* documents. I like it, for what that's worth.


2. Maybe I'm just not understanding what you're doing. It sounds like a UI front panel, some stackable modules and a framework for making arbitrary other stackable modules. Then I imagine that means a UI panel can manage a mixed stack behind it. Is that the idea, or did I get lost?
If I'm not completely lost, then here's a thought: (assume easy answers to fab questions and) arrange modules to launch their real-world connectors/terminals from one side (both?) and angled ~45deg forward. The result would be stacks with a UI panel on the "front" face, and behind that along the "side" of a stack, all the external connectors facing front-ish.
(You're placing connectors at top and bottom not sides - but maybe the constraints that lead that way apply more to stacking connections than to external connections?)
Or more simply just go straight out the side - at cost of requiring more directly perpendicular access to the side of a stack.
Something kinda like this, but with the knobs on the front and connections down the side: http://w140.com/tekwiki/wiki/File:Tek_211_front.JPG
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #50 on: July 13, 2016, 09:29:44 am »
1. You were looking for an alternative to DipTrace and free 3D modeling.
For schematics & layout, check out EasyEDA. From the little I've played with it, it seems to work. And it's free.
For 3D, check out OnShape -- a relative newcomer offering no-apologies parametric CAD for free. They claim to import step. Free accounts limit *private* documents. I like it, for what that's worth.
Looked at EasyEDA too but it's online which kinda sucks.
For 3D modelling I'm using FreeCAD, and download the 3D models for parts from tracepartsonline.

2. Maybe I'm just not understanding what you're doing. It sounds like a UI front panel, some stackable modules and a framework for making arbitrary other stackable modules. Then I imagine that means a UI panel can manage a mixed stack behind it. Is that the idea, or did I get lost?
Yes, the UI board is the front panel and you can stack other modules on top of it, on the opposite side of the front panel, see older posts, I have an example of how two modules stack up in 3D.

If I'm not completely lost, then here's a thought: (assume easy answers to fab questions and) arrange modules to launch their real-world connectors/terminals from one side (both?) and angled ~45deg forward. The result would be stacks with a UI panel on the "front" face, and behind that along the "side" of a stack, all the external connectors facing front-ish.
(You're placing connectors at top and bottom not sides - but maybe the constraints that lead that way apply more to stacking connections than to external connections?)
Or more simply just go straight out the side - at cost of requiring more directly perpendicular access to the side of a stack.
Something kinda like this, but with the knobs on the front and connections down the side: http://w140.com/tekwiki/wiki/File:Tek_211_front.JPG
Thought about having boards plug in at a right angle but mounting everything in an off the shelf enclosure would be more difficult, so all the boards are going to be parallel to the front panel. That way if the stack becomes too heavy to be supported by the front panel only two L-shaped brackets bolted to the bottom of the enclosure would be required.
Trust me, I'm NOT an engineer.
 

Offline pmc

  • Contributor
  • Posts: 10
  • Country: us
Re: DIY Modular Test Equipment Project
« Reply #51 on: July 13, 2016, 09:06:26 pm »
... so all the boards are going to be parallel to the front panel.

Understood. I'm not understanding how boards will expose terminal connections. I do see the function gen arrangement with BNCs next to the UI/display - but that only works for the one board directly behind the UI. How would you connect stuff to a module further down the stack? Or did you have in mind just one _function_ per assembly, with one interface board directly behind the UI exposing terminals adjacent to the display, plus whatever stack of add'l boards that function requires?
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #52 on: July 14, 2016, 06:54:01 am »
Initially I wanted to use ribbon cables to connect the modules to the UI, that's the reason for the shrouded headers, but I figured out shortly after that the waveform gen can be strapped to the back of the UI after finding those BNC connectors that stick out.

One function per assembly is the general idea I'm sticking with but there will still be the possibility to add more functions which comes with a few small drawbacks like having to use some extra wiring if the board is located  further down the stack requires connections to the front panel or if the board is physically too large.

As an example, say we have the Lab Power Supply configuration. The connections will look like this:

[UI board] : [Digital Isolator board] - [A/D & D/A board] : [Lab Power Supply board]

":" means stacked
"-" means wires/cables are used

The main goal is to keep wiring to a minimum, I don't like things that have so much wiring they look like a spaghetti bowl.
In some configurations it's difficult or not practical or too expensive to avoid using wires/cables for some configurations.

Other options I was thinking about as far as add-on boards are concerned are the possibility to add a second display (for a dual channel lab power supply) and a keypad (quite handy for a waveform gen) but I haven't decided how they will connect to the UI.

For the waveform gen at least the third layer of the stack (first one being the UI) will consist of the power supply modules for the different voltage rails required.
Trust me, I'm NOT an engineer.
 

Offline prasimix

  • Supporter
  • ****
  • Posts: 2022
  • Country: hr
    • EEZ
Re: DIY Modular Test Equipment Project
« Reply #53 on: July 14, 2016, 08:42:31 am »
Hi void_error, this is a great step towards defining modular lab equipments "environment". Do you have in mind housing? I think that enclosure has to be added in the picture very early.

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #54 on: July 15, 2016, 08:42:34 pm »
I actually do have housing in mind. I've been following your lab power supply thread and I'm probably going to use one found on modushop.biz, Economica series, 80mm tall. Shipping to Romania is quite expensive though so if anyone knows about any other places in Europe where I can find similar enclosures please let me know.
Trust me, I'm NOT an engineer.
 

Offline prasimix

  • Supporter
  • ****
  • Posts: 2022
  • Country: hr
    • EEZ
Re: DIY Modular Test Equipment Project
« Reply #55 on: July 15, 2016, 09:04:25 pm »
I'll let you know what Varisom from Portugal could offer. Their initial price for customized solution was really appealing but lately our communication became slow (maybe we should take into account EURO 2016 factor :)

Offline pmc

  • Contributor
  • Posts: 10
  • Country: us
Re: DIY Modular Test Equipment Project
« Reply #56 on: July 21, 2016, 05:28:16 am »
Initially I wanted to use ribbon cables to connect the modules to the UI, ... but I figured out shortly after ...

Ok, stacked packaging was never a driver for the project. Got it.

Quote
... but there will still be the possibility to add more functions which comes with a few small drawbacks like having to use some extra wiring if the board is located  further down the stack requires connections to the front panel ...

That's what puzzled me on first reading -- stacking functions behind a flexible UI sounds interesting, but then extra wiring and loss of generality for front panel arrangement sound less interesting.

So, the idea thrown out for your consideration was basically: keep the UI in the front panel of some box and stick the T&M connections out one side of the box, directly off the edge of each module PCB. More modules -> deeper box/longer side behind the same front panel.  (thinking one side to avoid locking in other dimensions/board area)

That said...

Requiring a lot of clearance for that side -- to see, reach and push/twist/pull whatever connector on the 4th card back -- seems like a strike against. Aiming each card's connectors ~45deg toward the front might make side connections more usable. So that side would be, um, louvered. And you could see connectors/jacks/sockets/whatever without clearance for your skull + near point distance alongside the unit. Plausibility requires some design idea for simple construction -- IFF you think the result would be desirable. (have half an idea. or just short wires.)

And...

Out-the-front is still attractive for a single-function assembly like the freq gen arrangement you've modeled. PCB pads arranged for attaching either "vertical" or right-angle connectors (or angle adaptificator) would give the option to build a first/only module either way.

Makes sense?

Just some thoughts. Your ball.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #57 on: July 21, 2016, 05:33:47 pm »
So, the idea thrown out for your consideration was basically: keep the UI in the front panel of some box and stick the T&M connections out one side of the box, directly off the edge of each module PCB. More modules -> deeper box/longer side behind the same front panel.  (thinking one side to avoid locking in other dimensions/board area)

That said...

Requiring a lot of clearance for that side -- to see, reach and push/twist/pull whatever connector on the 4th card back -- seems like a strike against. Aiming each card's connectors ~45deg toward the front might make side connections more usable. So that side would be, um, louvered. And you could see connectors/jacks/sockets/whatever without clearance for your skull + near point distance alongside the unit. Plausibility requires some design idea for simple construction -- IFF you think the result would be desirable. (have half an idea. or just short wires.)
I think I get what you mean.

Say you're looking at the front panel on the Z axis, perpendicular to the plane formed by the X (horizontal) and Y (vertical) axis.
Say you want the connectors on the right side, so you take the connector which would normally be on the X axis (sticking out to the side) and twist it clockwise on the Z axis by 45 degrees.

That would be quite neat but on mechanical side of things there's going to be more work... and wires.

Let me know if I really get it.

And...

Out-the-front is still attractive for a single-function assembly like the freq gen arrangement you've modeled. PCB pads arranged for attaching either "vertical" or right-angle connectors (or angle adaptificator) would give the option to build a first/only module either way.

Makes sense?

Just some thoughts. Your ball.
The UI can also work as an (expensive) alarm clock or a development board. Some other modules I have in mind are a mains Watt Meter and a Frequency Counter.

If you use right-angle connectors you could use stripboards for board interconnects as all the signal/power connectors are aligned to a 0.1 inch grid - breadboard/protoboard compatibility.

Trying to keep it quite simple, mostly for time reasons. I want to have something done by the end of this year.

80mm tall
Different enclosures for different functions. As long as it has an easy to drill front panel.
« Last Edit: July 21, 2016, 05:41:16 pm by void_error »
Trust me, I'm NOT an engineer.
 

Offline rollingstone

  • Contributor
  • Posts: 19
Re: DIY Modular Test Equipment Project
« Reply #58 on: July 25, 2016, 08:35:27 pm »
Hi, Nice project. Sorry, I didn't followed Your post from the begginning. Just remembered I did once something like this. It was 8 HF generator modules and 8 HF amplifier modules using standardised EUROCARD subracks. What case you going to use for modular design? I used this one : http://lt.farnell.com/schroff/24563-191/subrack-3u-175mm-84hp/dp/1455794
http://www.farnell.com/datasheets/95177.pdf?_ga=1.224072792.2973774.1448267837
Only 40 eur and does it's job. Then you can use plug in units to slide in:
http://www.farnell.com/datasheets/95306.pdf?_ga=1.216596437.2973774.1448267837
or shielded module:
http://lt.farnell.com/schroff/20809-537/card-frame-3u-227mm-10hp/dp/1370403
You just need to drill or to cnc front plate to make holes for indicator LEDS, switches and BNC connectors and stuff like that.
You can make one universal power with many regulated voltages (3.3, 5, +12, -12, 24 volts etc.) as plug in unit for entire rack, and then many other modules that you can plug in and plug out into rack and make it configurable and very universal.
I don't have any photos but it looks something like this:
http://dinrackis.com/euro-card-racks.html
http://mulogic.com/UCF-3HE-rack.html
 (immages from internet).
 
« Last Edit: July 25, 2016, 08:52:15 pm by rollingstone »
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #59 on: July 26, 2016, 05:33:09 pm »
You got it a bit wrong, it's not the case that's going to be modular, it's the stuff inside the case.
Those rack-mount frames do look nice but the plug-in units are bloody expensive. I've already decided what kind of enclosures I'm going to use and I won't have anything standardized across all the different bits of test equipment I'm making, the decision to have everything share a common front panel was made mostly because of time available for this project.

As far as progress goes it seems that I've reached that part where I tweak stuff - quite happy with that.

Another change to be made to the UI is replacing the 74HC4094 shift register used for driving the backlight LEDs of the pushbuttons with a 74HC595 as it's also used for multiplexing the Chip Selects and other things on the Waveform Generator speaking of which... the PCB is quite a pain in the a$$ to route, taking longer than expected, and I want the whole assembly to mount into a 100mm tall enclosure - that makes the Waveform Generator board size have a limit of 90mm. There's the option to make the board physically larger at the cost of... well... cost. It'll take some time until I figure out the best compromise although I've got quite a few ideas... stay tuned.
« Last Edit: July 26, 2016, 05:42:50 pm by void_error »
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #60 on: July 30, 2016, 11:50:28 am »
Finally managed to find the best component placement for the waveform gen board, final dimensions are 60mm wide by 90mm tall, front view.
All that's left to route is the power traces and tweak everything (tedious), which means I'll leave that for another day and work on another module - the USB - UART board... and it's going to be modular too, it will be able to plug into the UI board or accept a plug-in board with RS-232 and/or RS-485 (half duplex or full duplex). Some changes are required though, since the PIC16F1454 doesn't have enough pins for all the control lines, so I'm replacing it with its bigger brother, the 16F1459, which is also used on Microchip's Low Pin Count USB Development Kit so it's just a matter of modifying the USB CDC Emulator demo code as far as firmware goes.

Power Supply boards are next on the list. No big deal there, see first page. A 3D model of the Waveform Generator assembly will follow soon after.
After all of the above are completed it'll be PCB ordering time, I'm going with PCBWay, they seem decent and cheap.

Since the waveform gen is almost finished, I'm posting the schematic just in case anyone notices anything wrong, call it revision 1. The posts on the first page will be updated with schematics as soon as I have them built and tested.

Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #61 on: August 03, 2016, 08:00:36 pm »
The USB-UART module is almost finished. I only have to figure out what I can do with the two free pins I have left on the PIC16F1459... any ideas? Already have RX/TX/USB LEDs. What else can I do with with two extra I/O pins? Monitor USB voltage with one of them? RS-232 flow control lines * and RS-485 direction control are already in place.

* do I even need those? if not then I might as well get rid of them and use the 16F1454 but it would require porting the USB CDC Emulator demo rather than just modifying it and that would take more time which I have very little of.

Other than that, I wanted to cheap out on the UI board and ditch those two MCP23S08 I/O expanders by using the PIC16F18857's bigger brother, the PIC16F18877 but haven't managed to assign all the peripherals to pins while maintaining an easy-to-do PCB layout even with all the flexibility the PPS has to offer so nothing changed there.

I'm starting to dislike the idea of the Aux Power Supply modules being held only by two screws on one side so I might have another go at making everything fit together with nothing "flapping in the breeze". I might end up with more mounting holes than you can poke a stick at... but if it works... :-//
All that while trying to keep the 0.1 inch headers on an imperial grid while everything that's going to poke through the front panel (buttons, encoders, display) is going to be metric.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #62 on: August 11, 2016, 05:34:55 am »
Other than that, I wanted to cheap out on the UI board and ditch those two MCP23S08 I/O expanders by using the PIC16F18857's bigger brother, the PIC16F18877 but haven't managed to assign all the peripherals to pins while maintaining an easy-to-do PCB layout even with all the flexibility the PPS has to offer so nothing changed there.

Wrong. It can be easily done. Found a way around to allocating some pin functions to locations not supported, through the CLC module. I've been looking into that lately and if I use one of the CLC modules I can move some PWM outputs to PORTA. Only CCP5 can be assigned to PORTA but also CLC1OUT and CLC2OUT and they can accept inputs from other CCP/PWM modules.
The control pins on the display are input-only so they can be driven by a 74HC595. There's already one driving LEDs, it's just a matter of daisy-chaining the second one.

I've also had a look at the NCO module for square wave generation. The MCC comes in handy here for checking stuff, removes the need for spreadsheets to calculate NCO output frequency. Using Timer0 as a clock source for lower frequencies gives quite accurate results. Accuracy should be less than 1% +/- clock generator accuracy. The square wave / PWM output was never intended to be high precision anyway.

So it's almost back to square one... but at least I won't have to write code for the MCP23S08 anymore.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #63 on: August 13, 2016, 10:13:15 am »
It's looking good so far. There's one MCU pin available which is going to be used for something eventually.
Board size will be increased from 120x70mm to 130x70mm to make room for extra mounting holes. This is actually a good thing since the waveform gen board could use some extra width.

EDIT: Got it slightly wrong. I actually have two free pins. I'll find a use for them.

« Last Edit: August 13, 2016, 01:52:00 pm by void_error »
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #64 on: August 24, 2016, 05:00:03 am »
Looks like I ended up with 16 mounting holes on the UI board.

Got some work done on the Aux Power Supply modules and ran into some issues again because of the board size limitations, both modules are going to be 34x70mm in size.
On the analog supply board the space issues were dealt with by moving the SMD parts (diodes, resistors, MLCCs) to the bottom side of the board, the top side being occupies by connectors, bulk filter caps and the +/-15V linear regulators mounted horizontally on heatsinks (no TO-220s flapping in the breeze here).

The digital supply board had a few changes. Initially I wanted to use LTC3824s but there wasn't any room for all the external components needed so I ditched the chip and went on to look for something else. Found the TPS54360 which comes with a really handy spreadsheet which does all the math for you. Now I can fit both regulators on one board quite easily.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #65 on: August 28, 2016, 05:54:23 pm »
The digital supply board had a few changes. Initially I wanted to use LTC3824s but there wasn't any room for all the external components needed so I ditched the chip and went on to look for something else. Found the TPS54360 which comes with a really handy spreadsheet which does all the math for you. Now I can fit both regulators on one board quite easily.

Nope... even more changes. The way I want to sync the two regulators, one with an inverted sync signal, was a bit tricky with the TPS54360 as the timing resistor pin also serves as a sync pin and needed more parts than I had board space so it was back to suitable part hunting.
LT3680 seems to do the job - 12V @ 2A for one of the regulators and 5V @ 3A for the other one. And everything fits. (Note: @ means at up to here)
A dedicated sync pin makes life much easier.

Of course, the component values can be recalculated for different voltages, who knows where else I might need one of these boards. The sync logic runs off a separate 3.3V LDO (LM3480) and you might be wondering why I chose to run it off the 12V rail. Here's why: 12V also powers the fans on the DC Load and on the Lab Power Supply and those two don't need a 5V rail.



I'll be playing with these a bit more in LTspice to find the proper values for the compensation network components. Would have been easier if LT just made a spreadsheet like TI did.

Back to the dreadful-to-route waveform gen board... nothing changed there except for the LDO for the 50MHz oscillator which was a MCP1700, now it's a LM3480. Once I finish moving component groups around to get the best possible placement and finish the layout I'll have a 3D model of the whole assembly. Finally.

The other power supply board required by the waveform gen is not really worth talking about too much as it's just a pair of 7815/7915 linear regulators, a pair of 78L05/79L05, a bunch of filter caps and some diodes. Oh, and two small heatsinks.

Should I add some PTC fuses (where?) just to be on the safe side or is it a bad idea?
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #66 on: August 29, 2016, 05:29:14 pm »
Eye candy time!

Although I can't call anything finished yet I'm close enough. Lots of minor tweaks and some double-checking is still required for every single PCB but I finally got as far as being able to slap everything together in 3D with all the connectors in place. There's still a long way to go.

Color coded for visibility reasons:

The white board is the front panel user interface. The waveform generator board is the blue one with the BNC connectors sticking out.




The 5-pin connector on the green board (USB-UART module) goes to a USB panel mounted connector. One side of the optoisolators is powered by USB +5V while the other gets power from the 3.3V rail on the user interface board.




The purple board provides the analog supply rails: +/-15V and +/-5V. The two TO-220 regulators will have some small heatsinks between them and the board. Filter caps placed below the heatsinks. There's still room for a frequency counter module ;)




There's more than enough space for those bulky inductors.




The two black connectors on the top accept terminal block headers(?). The wires will be coming from a 18V center-tapped transformer. I managed to keep wiring to a minimum ;D




Connectors on top for easy probing and firmware upgrade. Might include a serial bootloader at some point...


« Last Edit: August 29, 2016, 05:46:21 pm by void_error »
Trust me, I'm NOT an engineer.
 
The following users thanked this post: prasimix

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #67 on: September 03, 2016, 04:51:43 pm »
Haven't worked on any part of this project at all for a few days and that's when ideas start coming and it's time to start tweaking.

I was looking for parts on Farnell/element14 website and found out they have a lot of quadrature rotary encoders to offer which made me want to change things a bit, forget the Bourns PEC11-L which is available at distributors which have high shipping cost to my country. Alps seem to have some nice encoders at a decent price also with included push option so I'm going with one of those. $5 shipping is the same as TME charges. If I can stick to these two distributors I'm happy and so far they seem to have all the parts I need.

Speaking about tweaking the designs I'm starting to think the UI board doesn't need a SEPIC converter if I use a charge pump to generate the -5V rail on the lab power supply board instead of an inverting DC-DC converter which would have used the LT3580. The charge pump wouldn't be a big deal as I could just use some logic gates driving small dual MOSFETs and clock them with the SYNC signal. That would eliminate the requirement for coupled inductors which aren't as easy to get as regular ones.
The LT3580 would be then replaced by the LT3680 which is also used on the aux digital supply board, reducing the BOM count.

With the waveform gen configuration being almost complete it's time to focus on the next two groups of modules I have planned, the DC Load and lab power supply and sort out the mechanical aspects.
Since I want the DC load itself to be modular there are two possible setups:
  • Have the modules in parallel for more power
  • Have the modules grouped and isolated from each other, like a multi-channel power supply
The first setup can contain a local microcontroller (on the DC load PCB) or not. The micro would be used for constant resistance or constant power modes. Paralleled modules will share a single DAC .
The second setup will include some form of isolated DC-DC converter and logic isolators.

For the lab power supply things will be a bit simpler, each power supply module is going to have an isolator+ADC&DAC board on top of it.

Another piece of test equipment that I intend to design and build, another module in this case, is a mains Wattmeter.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #68 on: September 12, 2016, 05:01:50 am »
Over the last few days I've been trying to figure out how to make the DC load modular and spent a lot of time looking for suitable parts.
Had to stick with SPI because there are not many I2C ADCs available.

The tricky part is making the modules daisy-chainable for the two main configurations - with or without an on-board micro.
Why? Because there is only one Chip Select line available.
With an on-board micro it can be done in firmware, each microcontroller will have an address. The peripherals will be on a second SPI bus.
When there is no on-board micro I'll be using cascaded 74HC595s to multiplex the Chip Select signals for the DAC, ADCs & Temperature sensors.
In the end it all boils down to a lot of jumper links used depending on the board configuration.

I still have no idea if passing the analog signals from one DC load board to another is a good idea for "slave" boards containing only the analog stuff and temp sensors with the "master" board having the optional micro and DAC/ADCs.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #69 on: September 12, 2016, 07:43:03 pm »
Before thinking of finalizing the DC load design I thought I'd check if the load modules scale up nicely and are stable in parallel with the help of LTspice.
The actual control loop will be using an OPA2727 but for the simulation I used the closest LT part I could find within 5 minutes which is the LT1213.
Everything seems to scale up nicely with no parasitic inductances/capacitances so a 400W DC load comprised of 4 DC load modules appears to be possible. Many thanks to Jay_Diddy_B for thoroughly explaining how to get the loop stable.

On the digital side I had a few issues with designing the module for operation with or without an on-board microcontroller but most of them are now dealt with.
One of the issues was multiplexing the fan rpm signal on the non-micro configuration but I had some free pins on the 74HC595 shift register used for multiplexing the ADC/DAC/Temp sensor chip select pins and used one to enable/disable the output of a 74LVC1G126 3-state buffer. A schematic would probably explain this better but it's not finished yet.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #70 on: September 17, 2016, 06:13:19 pm »
At this stage I'm jumping between the (still) nearly completed UI/aux psu/waveform gen/USB-UART boards tweaking stuff and thinking of things I might want to add.
Found one: add some energy storage caps to the UI board so they can power the EEPROM, micro, oscillator, and the optional RTC for an EEPROM write after power off as there will be no standby power supply and I'd like to have the previous settings saved until the next power on. Yes, it's going to have a "big clunkin' power switch".

There are two things that come into play here:
  • Detect the 3.3V rail voltage decrease
  • Write to the EEPROM before the capacitor voltage drops below a certain value, about 2.7V in this case, the micro can run at 32MHz down to 2.5V

The first one will be handled by one of the comparators, input via an externally available pin.
The second will be dealt with using the same comparator but with the input connected to the internal DAC acting as an internal voltage divider (referenced to Vdd).
The other input of the comparator will be internally connected to the internal voltage reference.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #71 on: October 01, 2016, 11:54:31 am »
Found one: add some energy storage caps to the UI board so they can power the EEPROM, micro, oscillator, and the optional RTC for an EEPROM write after power off as there will be no standby power supply and I'd like to have the previous settings saved until the next power on.
Good thing I remembered to RTFM for the oscillator, which is an ILSI ISM95 or ISM97 because it doesn't work down to 2.7V so I'll have to switch to the PIC's internal RC oscillator when a power failure is detected and that's possible according to the datasheet.

Another possible issue which I'm glad I didn't overlook could have been caused by the input protection diodes within the micro but another P-channel MOSFET which disconnects the resistor divider's positive side solved the problem.

With that said, the schematic for the UI seems to be complete... except a few part values...

EDIT: Forgot to change the nets for the encoders from +3V3 to VDD... and maybe a few more pull-ups. Corrected everything. Even had some MOSFETs backwards...:palm:

« Last Edit: October 01, 2016, 02:52:38 pm by void_error »
Trust me, I'm NOT an engineer.
 

Offline max_torque

  • Super Contributor
  • ***
  • Posts: 1272
  • Country: gb
    • bitdynamics
Re: DIY Modular Test Equipment Project
« Reply #72 on: October 01, 2016, 03:45:37 pm »
maybe silly question, but wouldn't it be worth doing all the different modules on a standarised card, with a std backplane connector?  therefore you could add extra modules, or change the allocations easily.  Even better, build them into a std rack mount enclosure like this sort of thing:



and it would look pretty professional too  :-+
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #73 on: October 01, 2016, 04:52:51 pm »
Someone else also suggested that, but it would be too expensive. Rack mounted enclosures aren't cheap either.
Trust me, I'm NOT an engineer.
 

Offline max_torque

  • Super Contributor
  • ***
  • Posts: 1272
  • Country: gb
    • bitdynamics
Re: DIY Modular Test Equipment Project
« Reply #74 on: October 01, 2016, 09:43:02 pm »
whilst proper eurocard rack enclosures are expensive, i bet you could do a simple DIY solution using std back plane connectors and some laser cut acrylic or simple ally frame etc??

Design you "processing" pcb as the back plane, with the IO and numerous serial bus connections, and have the various cards slot into that!
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #75 on: October 02, 2016, 06:46:30 am »
whilst proper eurocard rack enclosures are expensive, i bet you could do a simple DIY solution using std back plane connectors and some laser cut acrylic or simple ally frame etc??

Design you "processing" pcb as the back plane, with the IO and numerous serial bus connections, and have the various cards slot into that!

That would be possible but I would lose compatibility with solderless breadboards and protoboards which both use 0.1 inch spacing. The reason for the modules having 0.1 inch headers is if someone wants to hook up a module (like the waveform generator) to their own "processing board" like an arduino or raspberry pi they wouldn't need a custom made adapter board. They also have to fit in an off-the-shelf enclosure.

The other issue with plugging the modules at 90 degrees is that all the different IO would have to be on the processing board so they would be accessible on the front panel and they would take up a lot of space, not to mention the mechanical part, securing all modules so they don't flop around. That's the reason the current mechanical layout was chosen, as it only needs one surface to attach to, in the case of the waveform generator which has a 3D model shown shown here, is the front panel.

I also have to mention that all the bits of test equipment here are not precision driven but more by price, ease of construction and versatility so some compromises have been made.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #76 on: October 04, 2016, 04:58:05 pm »
Some significant progress has been made on the DC Electronic Load module.

The microcontroller for the "smart" version is going to be a PIC16F18345, again, a newer part, chosen for the pin reallocation feature and the multitude of peripherals, most notable being the availability of two hardware SPI ports, one used for communicating with the UI board, the other one handles the peripherals.

Having all the versions on one board is going to be a bit tricky and it'll involve a few jumper links.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #77 on: October 12, 2016, 02:28:04 pm »
The DC load will be split into two, one board with the analog stuff and temperature sensors, the other board will include the ADCs and DAC with the digital isolator and shift registers, haven't decided exactly what goes where but I'll make it in such a way so it will be shared with the lab supply.

I'm also thinking about a purely analog version, but that implies analog temperature sensors and comparators for the over temperature pretection as well as some solution for fan control.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #78 on: October 21, 2016, 12:05:40 am »
Made some block diagrams of what I have in mind so far. Hopefully I find a way around the tricky DC load requirements...
While I was still at it I decided to make one for each piece of test equipment.

If anyone's wondering what Q7 & Q15 are they're the last stage outputs of the shift registers used for Chip Select multiplexing.
DAC_I, ADC_I etc. are the chip select signals.
For the Waveform Generator I chose +7.5V to feed the linear regulator powering the square/PWM output driver but that might change. I could just slap a 5V linear regulator and ditch the +5V output from the Aux Digital Power Supply. It'll be cheaper too.





« Last Edit: October 21, 2016, 12:14:22 am by void_error »
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #79 on: October 25, 2016, 06:37:18 am »
The DC load final schematic is beginning to take shape.

Some changes were made to accomodate analog control so the digital temperature sensors were replaced by a pair of LM56.

The nice thing about them is that they have two built-in comparators with an input and an output available externally for each of them and the obvious way to go was to slap an SR flip-flop (with an inverter on one of its inputs) and turn each temperature sensor into a schmitt trigger with the input being the temperature and presettable high/low temperature thresholds.
It even has an internal voltage reference but it's not going to be used as there's already a more accurate LM4132-4.1 on board.

The UI board will read the temperature via two MCP3001 ADCs, the cheapest I could find with a SPI interface and external voltage reference input. 10bit is probably overkill anyway.

What's left to add is a PWM circuit for fan control for a fully analog version.

With all of those things in place I had an idea...

On paper a single DC Load module should be able to dissipate 100W but it should be tested after the thing is built. How? The answer lies in some lines of code that have yet to be written. I'm thinking about a test mode where you connect the load to a 150W+ voltage source and start "cranking" the current up while keeping a close eye on the temperature. Once things start warming heating up to a predefined temperature reduce the the current until thermal equilibrium is reached (in other words temperature reaches a stable value) and read the input power.

Another thing worth mentioning is the availability of two current ranges implemented like Dave described in his EEVblog #931. Look it up on youtube if you haven't already.

The SPI Isolation board will also include fan control/monitoring as well as the MCU for the "smart load" configuration along with isolated power. Nothing fancy, just a tiny MCP1416 driven pulse transformer with a few diodes and caps feeding two LDOs. The tricky part is having the whole lot of variants on a single board. :scared: I've previously done something similar and it's so easy to screw it up. Triple-checking won't cut it.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #80 on: October 26, 2016, 08:06:23 am »
:scared:
I just realized I could simplify some things... maybe... :blah:
And reduce the BOM.
The only thing I have to do is delete the level shifters from wherever they're used and put them on the UI board but there might be some drawbacks...
You won't be able to use modules with different I/O voltages together without an additional level shifter but I won't do that so it's fine with me. :phew:
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #81 on: October 26, 2016, 08:19:23 pm »
Found another thing I f***ed up badly at. 74HC595 as SPI Chip Select multiplexer. I'll either have to use its reset pin or find a way to interrupt the data flow past it to the other SPI peripherals while shifting data into the 595 preferably using existing connector pins.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #82 on: October 27, 2016, 04:45:36 am »
Problem solved using a 74HC74 configured as a 2-bit Gray code counter since I only have one pin available for latching the 595's outputs. One output goes to 595 latch pin, the other to the reset.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #83 on: October 29, 2016, 12:43:35 pm »
Problem solved using a 74HC74 configured as a 2-bit Gray code counter since I only have one pin available for latching the 595's outputs. One output goes to 595 latch pin, the other to the reset.
Better/simpler idea: divide the 74HC595 latch pulse by 2 and use it as a clock enable to the other SPI peripherals. Only a D-type flip-flop and some gates are required. The reset pin on the 74HC595 won't be needed.
« Last Edit: October 29, 2016, 12:52:27 pm by void_error »
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #84 on: October 30, 2016, 01:04:35 pm »
Eventually I ended up with a demultiplexer for the SPI clock line.
While looking for parts I ran into these really versatile configurable gates:
http://cache.nxp.com/documents/data_sheet/74LVC1G57.pdf
http://cache.nxp.com/documents/data_sheet/74LVC1G58.pdf
I might actually replace all of the different discrete gates with some of these so there are less part numbers on the BOM.
Trust me, I'm NOT an engineer.
 
The following users thanked this post: salbayeng

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #85 on: November 10, 2016, 05:32:53 pm »
Looks like having two current ranges for the DC Load is pointless but I might keep the range switching for voltage measurement just to get better resolution at lower input voltages.
I settled for 2A & 50V per module.
Minimum current will depend on the minimum output voltage of the DAC and the offset of the op amps but it will go down to 1mA.
Trust me, I'm NOT an engineer.
 
The following users thanked this post: salbayeng

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #86 on: November 10, 2016, 11:54:25 pm »
I did mention I found pin-compatible ADCs and DACs from TI & AD.
Here's a small list. These are the parts available at Farnell, and there's also a LT part I found.
  • ADC
    • 12bit
      • ADS7816
      • LTC1860
    • 16bit
      • ADS8320
      • ADS8325
      • ADS8326
      • AD7683
      • AD7684
  • DAC
    • 16bit
      • AD5662
      • DAC8501
      • DAC8531
      • DAC8551
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #87 on: November 12, 2016, 11:20:07 am »
Had an idea for an OPP (Over Power Protection) circuit. That means I don't have to settle for 50V & 2A but an upper power limit while keeping a maximum voltage limit.
One way to achieve this is to set the threshold for the OVP (Over Voltage Protection) comparator based on the set current determined by the DAC output voltage. An op amp should do the trick. Time to play with LTspice.
Trust me, I'm NOT an engineer.
 

Offline prasimix

  • Supporter
  • ****
  • Posts: 2022
  • Country: hr
    • EEZ
Re: DIY Modular Test Equipment Project
« Reply #88 on: November 12, 2016, 12:29:43 pm »
I don't see an OPP as critical to deserve dedicated circuit and not be limited/calculated by MCU or you want response time in microseconds range? Of course if you have dedicated OVP circuit than suggested method make sense when you are in CC mode, isn't it? For CV mode you have to take into account max. current.

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #89 on: November 13, 2016, 12:11:20 pm »
If there is a MCU then there won't be a dedicated OPP circuit but since there'll also be a non-MCU version on the same board I thought I'd design that in so it's harder to blow the MOSFETs up.
Trust me, I'm NOT an engineer.
 

Offline 0xPIT

  • Regular Contributor
  • *
  • Posts: 65
Re: DIY Modular Test Equipment Project
« Reply #90 on: November 13, 2016, 12:26:31 pm »
You might be interested in this project: http://www.heise.de/ct/projekte/machmit/ctlab/wiki (German)
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #91 on: November 16, 2016, 03:28:24 pm »
You might be interested in this project: http://www.heise.de/ct/projekte/machmit/ctlab/wiki (German)
To be honest, it would take me about a decade to build something like that on my own...
NI have done something similar but it's bloody expensive...

I never intended to put everything in the same box. Maybe I should change the title to "DIY Partially Modular Test Equipment Project"?

Anyway...
OPP circuit is working in simulation (LTspice). I used a discrete VCA and I know it has a lot of drawbacks as I played with one on a breadboard a few years ago. Since OPP doesn't have to be accurate it should be enough, limiting the maximum power to roughly 105% which is within safe limits. Hopefully this is the last thing I have to implement.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #92 on: November 18, 2016, 01:33:53 am »
OPP circuit is working in simulation (LTspice). I used a discrete VCA and I know it has a lot of drawbacks as I played with one on a breadboard a few years ago. Since OPP doesn't have to be accurate it should be enough, limiting the maximum power to roughly 105% which is within safe limits. Hopefully this is the last thing I have to implement.
And it's ditched as soon as I did a temperature sweep and expected it to be a mess and I was right.
I guess I'll have to live with some limitations for a fully analog version if anyone wants to build one...
In that case for a 2A version the load will shut down above 50V. Nothing more than a schmitt trigger needed.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #93 on: November 19, 2016, 02:39:55 pm »
I'm thinking of changing the MCU again for something more powerful. Although the new 8-bit 16F1xxxx series has a lot of good stuff built in it might be a bit slow and lacking memory, and so far the only one I could find at Farnell and TME is the PIC16F18875 which has only 1k of RAM.
The other MCU which will be part of the control loop for the E-load, the 16F18345 is not available at the aforementioned distributors either.
EDIT: Guess I was wrong. Farnell has it.

Changing to a PIC18F would be quite pointless because I won't gain much from the 8x8 HW multiplier but the PIC24s have a 17x17bit multiplier and 32/16bit divider which is useful given the multitude of tasks it has to do.

To summarize, I'd use a PIC24FJ series 64-pin MCU in a TQFP package which will allow me to remove the shift registers on the UI board, and a PIC24F04KA201 for the E-load control loop for constant resistance / constant power loop. The other modification would be switching from SPI to UART for communication with the "smart" load modules since the 24F04K201 has only one MSSP module.They're both quite cheap.

Any thoughts on this? Let me know.

Too complicated, would take me too much time.
« Last Edit: November 20, 2016, 01:57:06 am by void_error »
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #94 on: November 22, 2016, 07:35:23 pm »
The SPI isolation board is turning into a connectivity nightmare when it comes to routing. I'm limited to a width of 80mm and height of 20mm less than the DC load board which has to fit into a case which is 100mm or 115mm tall since it's going to sit on top. It'll also have to support both regular 0.1 inch pin headers as well as IDC headers. The pin headers will be used for daisy-chaining and the IDC headers only for the first board in the chain on the UI side. Daisy chaining using the pin headers also requires a mirrored pinout for right angle pin headers so this means another row of pins connected to ground.

Since the SPI isolation board also has to plug into the Lab PSU board it means that that latter has to also be 80mm wide so I guess I'll have to start working on that too to make sure everything fits together.

This is going to be tricky.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #95 on: November 26, 2016, 03:33:26 am »
Everything is starting to come together nicely. The DC load schematic is almost finished as well as the SPI isolation board.
I've also started working on the linear part of the lab power supply aka the post-regulator to make sure the SPI isolation board fits on top of it and the whole thing seems to end up around 100x80mm.

The pre-regulator is going to be on a separate board which will also output the +/-5V rails required by  the lab power supply as well as a bias voltage around 5V above the pre-regulator voltage.

There's still a long way to go.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #96 on: January 31, 2017, 03:58:50 am »
Sorry for not posting anything lately... that doesn't mean I abandoned this though.

Some changes are in place, mainly changing the bus used to link all the modules together to something similar, a simplified version of what prasimix proposed here, which he's developing with a bit of assistance from me.

For the simplified version of the bus only 15 lines are necessary, as described below for the UI board:

  • CLK - clock line for feeding a clock signal to other microcontroller in the bus
  • GPO - General Purpose Output - user configurable output, can be used to control fans, etc.
  • GPI - General Purpose Input - user configurable input, can be used for measuring fan rpm, etc
  • SDA - I2C data line
  • SCL - I2C clock line
  • 1-WIRE (Note 1) - for connecting devices using Maxim's one-wire bus
  • TX - UART TX - configured as open drain to allow multiple master devices
  • RX - UART RX
  • ST_CP - 595 shift register storage pulse, latches the shifted data to the ouputs
  • SH_CP (Note 2) - 595 shift register clock, driven from the SPI clock line
  • QS (Note 3) - SPI data output to 595 shift register
  • MOSI - SPI data out
  • MISO - SPI data in
  • SCLK - SPI clock
  • nCS - SPI chip select output


Notes:
1. the one wire bus uses a UART module
2. SPI output available via Peripheral Pin Select (PPS)
3. on peripheral boards (waveform gen, etc) it will connect to the 595's data input via the bus input connector, while the 595's last bit shift register output (QS) will connect to the bus output connector and to the data input on the next board for daisy chaning, a schematic will explain this better

Changes have been made to the UI board to accommodate the new bus connection which uses 5V signalling. The microcontroller used will be a PIC18F65K40 or any of its bigger brothers in case more RAM is needed. Ditched the switchmode regulator in favor of cheaper LDOs. Since the LCD runs on 3.3V while the MCU rins on 5V some level shifting was required. This was achieved by making the I/O pins open drain and setting the input levels to TTL, with pull-ups to 3.3V.

The Waveform Generator has changed a bit, with the square wave output fed from a comparator connected to the first amplification stage after the DDS filter, capacitively coupled. What that means there's no PWM capability on that output anymore, that will be available on the Frequency Counter module, the next one I'll be working on. I'm also using a dual output reference, a REF3140 since it's easier to bias things.

As far as connectors are concerned no changes will be made, sticking to ribbon cables for data and keyed headers for power.

If anyone's still following this I have to say I want to see this completed as soon as possible but with so many modules I have to make sure everything fits together before throwing money at it. I don't want to have a second revision right after I build the first one so I'm taking my time to make sure it works first go.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #97 on: June 27, 2017, 03:21:22 pm »
Quote
Warning: this topic has not been posted in for at least 120 days.
Unless you're sure you want to reply, please consider starting a new topic.

Looks like I haven's posted anything in here for quite some time...
Well then...

After running into the 500-pin limit of the free non-profit version of DipTrace more than enough times I decided to give KiCad another go after watching some random presentation on YouTube so here goes me redrawing everything. There won't be any lack of drawbacks however, because you can't use sheets in KiCad yet(?) and although there's a workaround using hierarchical sheets you can't copy |O anything from the root sheet so unless you start messing with the files you've got your work cut out so I'm not going to do everything twice and since this is not a review of KiCad I shall end the rant here.

What I'm going to end up with due to the lack of sheets is huge schematics :scared: but at least they'll be separated into functional blocks.

Creating all the missing components is going to take some time as well.

More updates coming soonTM.
Trust me, I'm NOT an engineer.
 
The following users thanked this post: Aigor

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #98 on: July 08, 2017, 04:03:40 am »
Things look like they're coming together nicely. Since I have no pin limit anymore I'm going to put the Waveform Generator and the Frequency Counter on the same PCB while keeping the mounting on the back of the UI board.

The Lab Power Supply schematic is almost finished, the only thing that's preventing completion is that I'd like to have as many components / functional blocks shared between all modules, making PCB layout, firmware and ordering of parts less tedious. I'm also keeping the option of having it work without digital control while keeping switchmode regulator sync, fan control with OTP (Over Temperature Protection) and switching off the pre-regulator for low output current settings.

It has been previously mentioned that there were going to be two AUX power supply modules, they're now going to be merged into one and used to power the Waveform Generator + Frequency Counter or the DC Load modules. Where there are linear regulators there will be the option to choose between TLV1117/LM317 and 78xx for the positive supply rails and LM337 and LM79xx for the negative supply rails. There might also be a fan control circuit on that, haven't decided yet.

Since I've mentioned the DC Load I might as well get into some details, first of which will be the 'weird' supply voltages of +7.5V and -2.5V for the op amps (OPA2727, also used in the Lab Power Supply) since their maximum supply voltage is 13.2V along with +5V/-5V

On the ADC side I ended up using only one with a 74HC4051 multiplexer for all measurements on both the Lab Power Supply and the DC Load. There's a list of pin-compatible ADCs and DACs a few posts back.

As you've probably noticed, updates on this will be fairly random.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #99 on: August 04, 2017, 05:14:18 am »
It's Aux Power Supply time.

With some of the modules using more power rails than you can poke a stick at (you need more sticks) some form of power sequencing will be required, not so much because the power rails need to all come up at exactly the same moment in time but for that fault scenario when one of the rails outputs a voltage out of spec which could cause current to take the shortest path through the input protection diodes of some ICs and weird stuff could happen.

A simple solution to this is to use a window comparator circuit (LM393) for each rail and some P-channel MOSFETs paired with a delay circuit (CMOS 555 or some monostable using logic gates) and a cheap voltage reference (TL431 or LMV431).

It has been previously mentioned that there were going to be two AUX power supply modules, they're now going to be merged into one...
That turned out to be not such a good idea. I want to be able to use the boards for other things and not having them only 20% populated.

One more thing worth mentioning is the use of a 74HC138 3-to-8 line decoder to drive the CS pins of the SPI peripherals on the boards that use them, which means I can use only one 74HC595 where I would have otherwise needed two and adding an extra level of idiot-proofness.

Trust me, I'm NOT an engineer.
 

Offline Leo Bodnar

  • Frequent Contributor
  • **
  • Posts: 801
  • Country: gb
Re: DIY Modular Test Equipment Project
« Reply #100 on: August 04, 2017, 08:12:23 pm »
If you are designing your own modular instrumentation project you might find this http://www.easy-phi.ch/ interesting.
Leo
 
The following users thanked this post: prasimix

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #101 on: August 05, 2017, 08:49:57 pm »
Prasimix has an idea like that. I did mention in a previous post that my version of modular is not going to have everything in the same enclosure and try to keep the costs down, although you could combine some of them. It's not going to be rackmount either.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #102 on: August 09, 2017, 07:23:51 am »
A simple solution to this is to use a window comparator circuit (LM393) for each rail and some P-channel MOSFETs paired with a delay circuit (CMOS 555 or some monostable using logic gates) and a cheap voltage reference (TL431 or LMV431).
Turns out that it's not going to be so simple so I'll just use an undervoltage lockout comparator for each rail, OR them together, some TVS diodes for overvoltage protection and rely on the polyfuses at the linear regulators' inputs to limit the current. The reference for the UVLO comparator is  going to be a TL431. Output disconnect will still be done using MOSFETs.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #103 on: August 10, 2017, 01:49:29 pm »
After more than enough stupid ideas I managed to come up with a circuit that seems to work. You can find a crude mock-up of it below (http://falstad.com/circuit/circuitjs.html - File > Import From Local File). It's neither built up to scale (component values are subject to change) nor painted (no part numbers). Used a simple zener based series regulator instead of an LM317 just because it'll do for the simulation.

Time to see how I can add most the same to a negative rail. After that I'll draw it in LTspice and 'virtually' abuse it some more then breadboard it at some point.

Yes, I know, it's overkill.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #104 on: October 06, 2017, 10:41:19 pm »
It's now time for a design goal (or feature?) update for each of the pieces of test equipment, it's the stuff on the first page.

Someone mentioned a useful feature would be to turn two channels of a bench power supply on at the same time here so I went ahead and opened my KiCad project for my bench supply to see if it was possible and it apparently is but more on that after I polish the schematic a little bit, I think it's lacking a few details at this point, like component values and associated footprints, maybe I should make a new component library for passive components with footprints associated instead of the standard generic resistor/capacitor ones which need to be linked to footprints manually since I have quite a few different size passives... anyway, since I'm using 595 shift registers for SPI addressing and the DACs used to set the voltage and current only have the clock input (SCLK) and the data input (MOSI) pins tied to the SPI bus they can be updated at exactly the same time given the output voltages are the same which is not that useful so I'll either have to find a DAC with a Latch DAC pin or find another way to make the DAC outputs rise at roughly the same time with the latter being an easier task as I already settled on some specific parts (see first page).

Another idea I've been messing around with is completely ditching the on-board fan control circuit on each of the PSU channel. The new location will be the aux digital supply board since that will be used by the DC load modules anyway, which are now going to be 200W or lower, depending on the power MOSFETs' type and number of devices used. An extra connector will be required. In the case of the bench power supply the aux digital board's fan control circuitry will drive one fan for both channels.

Also, sorry for not posting in a while, I thought I'd get enough stuff done first.
Trust me, I'm NOT an engineer.
 

Offline prasimix

  • Supporter
  • ****
  • Posts: 2022
  • Country: hr
    • EEZ
Re: DIY Modular Test Equipment Project
« Reply #105 on: October 07, 2017, 11:47:12 am »
[reserved for future use]

Maybe it's time to think about data acquisition module, for beginning a modest one for e.g. multiple/multiplexed channels temp sensor logging and slow changing signals. The same module could also include few buffered PWM and/or DAC outputs and multiple protected/buffered Digital I/O.

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #106 on: October 08, 2017, 08:26:45 am »
That has been thought of, although I haven't mentioned it anywhere. I could add that to a third power supply channel (the 0-5.5V one for powering digital circuits). An ethernet connectivity module is also planned.

Right now I'm standardizing the 595+SPI addressing across the three modules I'm currently working on. I've also been thinking about a way to identify the location of each module on the bus without changing things too much or using an EEPROM which will have to be written to before assembly and I have a possible solution which is going to fit the current bus architecture.

Since the addressing and multiplexing of different functions on a module is based on daisy-chained 595 shift registers it appears to be simply adding a 74HC165 with its inputs tied to either the positive or negative supply like the address pins for I2C chips (see PCF8574 or similar). One of the  pins will be used to indicate whether it's the last module in the chain. The firmware on main MCU will know how many bytes it needs to shift through the 595s and the location of each module regardless of the the order based on the definitions of each module programmed in. I'll need to modify the communications bus a little bit to accommodate an input from the shift register side or switch back to the initial idea to switch between MCU SPI connected to the shift registers or to the SPI slave devices outside the MCU which will free a few lines on the bus.

I must admit I was too slow to reserve posts for future use as the replies started coming in too fast when I started this topic...

Another module will be the front panel for the PSU / Electronic load which will also use 595s for the different functions it'll provide like channels in series/parallel or whatever else comes to mind. Or I might put the digital I/O and temp sensor inputs in there...
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #107 on: October 08, 2017, 08:20:42 pm »
Since the addressing and multiplexing of different functions on a module is based on daisy-chained 595 shift registers it appears to be simply adding a 74HC165 with its inputs tied to either the positive or negative supply like the address pins for I2C chips (see PCF8574 or similar). One of the  pins will be used to indicate whether it's the last module in the chain. The firmware on main MCU will know how many bytes it needs to shift through the 595s and the location of each module regardless of the the order based on the definitions of each module programmed in. I'll need to modify the communications bus a little bit to accommodate an input from the shift register side or switch back to the initial idea to switch between MCU SPI connected to the shift registers or to the SPI slave devices outside the MCU which will free a few lines on the bus.

Ended up using a 74HC166 with a D type flip flop connected to the data output (pin 13) to make it compatible with one of the SPI modes, using the SH/~LD pin (15) as Chip Select and an extra AND gate to gate the clock of the flip flop (one input goes to SH/~LD, the other one to SCLK, output to flip flop CLK) and a tri-state buffer tied to the Q output of the flip flop, enabled by a low chip select signal. The whole thing end up as a SPI General Purpose Input expander and it's cheaper than say, a MCP23S08 8-bit GPIO expander, by a factor of two or more.
Trust me, I'm NOT an engineer.
 

Offline prasimix

  • Supporter
  • ****
  • Posts: 2022
  • Country: hr
    • EEZ
Re: DIY Modular Test Equipment Project
« Reply #108 on: October 08, 2017, 09:14:54 pm »
The whole thing end up as a SPI General Purpose Input expander and it's cheaper than say, a MCP23S08 8-bit GPIO expander, by a factor of two or more.

That is not a real saving when MCP23S08 is around $1. On the other side you're decided to use not so cheap ADC and DAC for e.g. Power supply and electronic load. Also when you are thinking about savings, that is fine, take into account that one component even more expensive then few used as its substitute could cost less at then end (if you or anyone else want to organize production, because assembly line "time is money").

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #109 on: October 09, 2017, 05:15:32 am »
But on the other hand you can pair the read of the expander configured in this way with something that only uses the MOSI line like a DAC. Since I only need to read inputs a fully featured GPIO expander seemed overkill and it also has some communication overhead for configuring, making it slower. The read can also be paired with a DAC write if the DAC only uses the MOSI line and the same SPI mode.

You're right about assembly line time, but I'm not going straight for production-readiness with the first revision.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #110 on: October 17, 2017, 05:35:20 pm »
After spinning around in circles looking for suitable DACs with an LDAC pin in order to update two power supply or DC load channels at the same time it seems I'm back to the initial selection of cheap string DACs.
  • DAC
    • 16bit
      • AD5662
      • DAC8501
      • DAC8531
      • DAC8551

None of them have a LDAC pin which means I'll need to find a way to update them at the same time. Having the MSB the first bit that needs to be shifted in makes it more difficult so I should find a way to delay the LSB by at least one clock cycle and use that to clock it in simultaneously for both DACs. Some glue logic will be required or just ditch them and go for an AD5761 which has everything I need. The latter option is easier to implement so I'll probably be sticking with it.

EDIT: Looks like the AD5761 is a clear winner. Just had a look at the waveform generator output stage and I'll use the 12-bit variant there for output offset adjustment since it gets rid of one op amp used for level shifting. Problem solved.
« Last Edit: October 17, 2017, 05:54:03 pm by void_error »
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #111 on: November 18, 2017, 12:40:51 pm »
Time for another short progress update...

The UI board is going to use 3.3V logic, mostly due to the fact that the display is a 3.3V part and there's no information in the controller's datasheet regarding the output current of the data lines which means using open drain outputs and pull-up resistors to do the level shifting from the previously 5V powered MCU might not work properly so I'm not risking it.

The changes to the UI board aren't going to affect the DC load or the Lab Power supply since they use digital isolators.
What needs changing so far is the Waveform Generator / Frequency counter board and the good thing here is that the AD9834 DDS chip can use different supplies for the analog and digital supply pins which means I can get rid of a few parts like the level translator chips for the clock generator chips which run on 3.3V. The analog stuff will still run on 5V.

Regarding the 595 shift registers, each board is going to use two of them because I couldn't find a way to implement all the SPI addressing and any other functionality using only 8 pins.

I want to have everything ready for the PCB design stage by the end of the year but I might not be able to since the front panel board for the Lab Power Supply and DC Load as well as the digital channel for Lab Power Supply haven't been designed yet.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #112 on: December 31, 2017, 02:07:12 pm »
Looks like the frequency counter part is almost complete with only a few tweaks here and there still to be done. Managed to get rid of the MCU and replaced it with about two truckloads of logic chips, mostly counters, flip-flops and multiplexers. It should go up to 20MHz @ 1Hz resolution with LVC series counters (74LVC161) but I've also included a divide by 10 prescaler which should allow it to go up to 100+ MHz with 10Hz resolution.
Trust me, I'm NOT an engineer.
 

Offline Kleinstein

  • Super Contributor
  • ***
  • Posts: 14080
  • Country: de
Re: DIY Modular Test Equipment Project
« Reply #113 on: December 31, 2017, 03:26:46 pm »
Looks like the frequency counter part is almost complete with only a few tweaks here and there still to be done. Managed to get rid of the MCU and replaced it with about two truckloads of logic chips, mostly counters, flip-flops and multiplexers. It should go up to 20MHz @ 1Hz resolution with LVC series counters (74LVC161) but I've also included a divide by 10 prescaler which should allow it to go up to 100+ MHz with 10Hz resolution.

This direction is odd. The more normal way today is to get rid of the logic chips and use a µC to implement a reciprocal counter.  This way a frequency counter is a rather simple task and still can get really good resolution. So more like 8 digits of resolution after 1 or 2 second in a frequency range of about 10 Hz to around 50 MHz (more with prescaler) with just a single µC (like STM32F3...) and an external clock (e.g. TCXO) and the input stage. So the difficult part today are more like the input stage and maybe the software. So a frequency counter today is a small project, unless you want to go beyond something like 8 or 9 digts. With some special TDC modules / chips very high resolution is possible, that might want a good OCXO or more to get a meaning to 12 digits.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #114 on: December 31, 2017, 05:15:44 pm »
This direction is odd. The more normal way today is to get rid of the logic chips and use a µC to implement a reciprocal counter.  This way a frequency counter is a rather simple task and still can get really good resolution. So more like 8 digits of resolution after 1 or 2 second in a frequency range of about 10 Hz to around 50 MHz (more with prescaler) with just a single µC (like STM32F3...) and an external clock (e.g. TCXO) and the input stage. So the difficult part today are more like the input stage and maybe the software. So a frequency counter today is a small project, unless you want to go beyond something like 8 or 9 digts. With some special TDC modules / chips very high resolution is possible, that might want a good OCXO or more to get a meaning to 12 digits.

Yes, I know it's odd. Initially I went for a local MCU as a frequency counter but I figured it wouldn't be too nice to force anyone who wants to build this to use a PIC (16F1619 in this case).

But in one of the next revisions I will change to a MCU which is going to be installed on a daughter board so one can use their MCU of choice.

With that in mind, the old-school version of the frequency counter it will be on a separate board, with the waveform generator having a MCU-based frequency counter.

I'll build both versions, I'm curious how they perform.
Trust me, I'm NOT an engineer.
 

Offline Kleinstein

  • Super Contributor
  • ***
  • Posts: 14080
  • Country: de
Re: DIY Modular Test Equipment Project
« Reply #115 on: December 31, 2017, 05:31:01 pm »
One can also do classical counting with an µC. AFAIK the PICs are quite good at this. Other µs might need a little extra HW to get to higher frequencies. AFAIK some of the PIC18 include hardware that is supposed to be useful for analog time interpolation with relatively little additions This would give a rather high resolution reciprocal counter (e.g. sub ns resolution) with moderate effort.

Usually reciprocal perform better than simple classical counters, as the resolution is no longer limited to fixed increments of 1 over gate time. Its only at the upper limit that both ways have about similar performance.

Many other function would need an µC anyway - so I see no big advantage in avoiding an µC for a counter, if this is something the µC can do very well.
 
The following users thanked this post: void_error

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #116 on: January 01, 2018, 08:55:38 pm »
One can also do classical counting with an µC. AFAIK the PICs are quite good at this. Other µs might need a little extra HW to get to higher frequencies. AFAIK some of the PIC18 include hardware that is supposed to be useful for analog time interpolation with relatively little additions This would give a rather high resolution reciprocal counter (e.g. sub ns resolution) with moderate effort.

Usually reciprocal perform better than simple classical counters, as the resolution is no longer limited to fixed increments of 1 over gate time. Its only at the upper limit that both ways have about similar performance.

Many other function would need an µC anyway - so I see no big advantage in avoiding an µC for a counter, if this is something the µC can do very well.

It seems that I have implemented a reciprocal counter. Didn't know it was called that.

I guess I'll be sticking with a MCU in the end. Found this neat little document.

For anyone not wanting to use a PIC there will be the possibility to put their own MCU on a daughter board.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #117 on: February 07, 2018, 08:27:10 pm »
I've almost finished everything needed for the waveform generator / frequency counter as far as schematics go, with the electronic load and lab power supply not far behind. Depending on how things progress I might have stuff on GitHub this weekend.

One thing I've settled for is using 3.3V for the logic and +/-3.3V for the analog stuff where digital isolators aren't used, the only exception being the AD603 used to adjust the output amplitude of the waveform generator's output for sine/triangle which requires +/-5V, delivered via a pair of LM317L/LM337L off the +/-15V supply of the output stage.

As far as the electronic load and lab power supply are concerned, they're 80% done unless I find easy ways to add more features which I've been doing a lot lately at the expense of them not being finished yet (like another multiplexer for the option to measure all the internal supply rails). :scared: Oh, and it's 80% of the schematics, PCBs not included.

Speaking of PCBs, that's another can of worms since it's about a dozen of them... almost:
  • UI board
  • Waveform Generator & Frequency Counter
  • Lab Power Supply
  • Electronic Load
  • Front Panel & Aux Digital Channel
  • USB Charging Module
  • USB - UART interface
  • Aux Analog Supply (linear regulators - easy)
  • Aux Digital Supply
Ok, it's only 9 of them.

Another thing I have planned for sometime in the future is an ethernet module based on some PIC18 and Microchip's TCP/IP libraries but I'm not going too far with it from the start and I'll probably base it on an existing example.

One thing I still have to look into is whether I can reuse the Front Panel module designed to be used with the lab power supply for the electronic load as well, without the relays used to switch the two channels between independent/series/parallel and for that I have to decide what the high current range will be and what connectors I'll use and whether they'll be PCB mounted or panel mounted. Looking for parts is very time-consuming, especially when I'm trying to stick with only 2 distributors - TME & Farnell. Digikey and/or Mouser will have everything anyway but shipping cost will be higher for me at least.

If anyone has any comments or questions or pretty much anything related you can leave them below. Blame the way the forum works if they end up on the next page (joking). :blah:
Trust me, I'm NOT an engineer.
 

Offline bg9gas

  • Newbie
  • Posts: 3
  • Country: cn
Re: DIY Modular Test Equipment Project
« Reply #118 on: February 08, 2018, 04:33:45 am »
 :-+ :-+ :-+ :-+
 

Offline xani

  • Frequent Contributor
  • **
  • Posts: 400
Re: DIY Modular Test Equipment Project
« Reply #119 on: February 08, 2018, 01:10:05 pm »
For ethernet side honestly you're probably better off just sticking raspberry pi there, it has serial, SPI and I2C on it, it's cheap, and you can then run any data acquisition directly in the system instead of pushing data to dedicated PC. Or even run a web UI with modules state/controls

For IDing modules daisy chaining is probably easiest option, but you should also probably have modules send their name and some unique ID if a micro has it) with it. That makes it possible for code to work regardless of which order modules are put in or even (if unique IDs are used) if you reorder stuff for whatever reason. Of course, that requires a micro per board

If you go with micro per board it would also be worth to add a single LED dedicated to identify function, that allows for making queries like "which board is ADC number 4" or "which board is one with ID 413e6f"

Or go even fancier and put RGB led on, then you can do "connect left channel to green input, and right channel to purple one"

 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #120 on: February 08, 2018, 04:53:06 pm »
For ethernet side honestly you're probably better off just sticking raspberry pi there, it has serial, SPI and I2C on it, it's cheap, and you can then run any data acquisition directly in the system instead of pushing data to dedicated PC. Or even run a web UI with modules state/controls
Adding ethernet is just an idea, only mentioned it because I saw it's possible with what I have so far. I'm just playing with the idea and not taking it too seriously at the moment.

For IDing modules daisy chaining is probably easiest option, but you should also probably have modules send their name and some unique ID if a micro has it) with it. That makes it possible for code to work regardless of which order modules are put in or even (if unique IDs are used) if you reorder stuff for whatever reason. Of course, that requires a micro per board
Found a way that requires no micro and with jellybean parts. The ST_CP pulse is already used to latch the data onto the 74HC595's outputs so it's reused by U713 to latch the input data. U715 & U712 just make the whole thing SPI compatible. U712 outputs into the SPI MISO line and the STS line acts as an active high chip select. U715 is there to delay the data by one bit. In other words, the board ID is programmed via 6 solder links. D0 & D1 will have board specific functions, like signalling an overtemperature condition.



Why I went that route is because I don't want to force anyone else building one of the aforementioned modules into using the same micro I used. Perhaps one would want to use an arduino, or STM or raspberry pi or whatever else to control the module(s).

If you go with micro per board it would also be worth to add a single LED dedicated to identify function, that allows for making queries like "which board is ADC number 4" or "which board is one with ID 413e6f"

Or go even fancier and put RGB led on, then you can do "connect left channel to green input, and right channel to purple one"
Going one micro per board would have been one way to make everyone happy but only if I provided a way of mounting a daughter board for each module which IMHO I found it would be a pain in the butt so I'm only doing it for the module that has the frequency counter where a micro is the only sane way to go. I should probably make a new lock diagram of how things would work together as the last ones I posted are quite outdated.
« Last Edit: February 08, 2018, 04:56:37 pm by void_error »
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #121 on: February 11, 2018, 02:47:46 pm »
I've almost finished everything needed for the waveform generator / frequency counter as far as schematics go, with the electronic load and lab power supply not far behind. Depending on how things progress I might have stuff on GitHub this weekend.
This guy spoke too soon.

I thought I'd first see if everything fits together and it's not a huge pain in the ass to route where MCUs are employed so I had to move pin functions around. After finally getting to something doable for the UI board (yes, it strikes again) I realized it's way too big so I'm changing the connector placement from something like this to moving the 30-pin bus connector to one side and maybe the pushbuttons to the bottom below the display depending on how much I can shrink the board vertically. It currently looks like this and one can almost build a factory on top of it:
« Last Edit: February 11, 2018, 02:50:13 pm by void_error »
Trust me, I'm NOT an engineer.
 

Offline John Heath

  • Frequent Contributor
  • **
  • Posts: 444
  • Country: ca
  • 2B or not 2B
Re: DIY Modular Test Equipment Project
« Reply #122 on: February 11, 2018, 04:20:13 pm »
I like it. Do you have a picture of what it physically looks like on your bench? Have you thought of a computer interface secondary display and mouse buttons for secondary desk top computer control. This would open new doors for your modular data acquisition system . One of those doors would be the internet where I from 1000s of miles away could press a bottom to make a measurement on your bench. Can not think of a practical reason to do this but then again why does a man climb a mountain , because it is there.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #123 on: February 11, 2018, 08:27:56 pm »
I'll be using one of these because they're cheap and I'm cheap, unfortunately (not for me) no backplane/rackmount possibility out of the box, too much work for too little gain.

Modular... hmm... nope, won't change the title but you can find something being designed to be modular here.

This is just a collection of bits of test equipment sharing a similar communications bus simply because it was easier to have it that way.

Internet? Just hook up a raspberry pi or something via UART and you can have it. Going for practical first, after fancy a bit later.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #124 on: February 23, 2018, 06:02:51 pm »
I think I have finally managed to get the PCB sizes right for the 4 stacked boards of the waveform generator. UI ended up 115x70mm, with the waveform generator 115x95mm. It might be the time to upload some schematics to github as drafts since things might change a bit with the PCB layout which is what I'm currently working on.
« Last Edit: February 25, 2018, 11:48:32 am by void_error »
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #125 on: February 25, 2018, 11:50:36 am »
GitHub repo is now up :scared:. Check first post.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #126 on: February 26, 2018, 10:04:08 pm »
Waveform Generator + Frequency counter project has also been uploaded to GitHub. Link on first page. Don't be afraid to point out any mistakes you may or may not come across.

I'll also have to update the individual posts for each module. They're getting outdated.
« Last Edit: February 26, 2018, 10:05:57 pm by void_error »
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #127 on: February 27, 2018, 06:14:46 pm »
The first of the two voltage regulator modules is up on GitHub, the one for the digital part. It also has a... hmm... no idea how to call it... but it's basically a step-down regulator power stage with a PWM input and it's used for fan control. I'll upload the one for the analog part sometime later today if I don't get caught up in other stuff.

On another note, most of the 4 PCBs that make up the minimum setup for the Waveform Generator + Frequency Counter are being worked on and their sizes set. I'm still having a few issues with connector placement but those will be sorted out. I haven't included the isolated USB-UART module since it's tiny in comparison but it also has to do with connector placement. In case I haven't mentioned already, it's going to use either a PIC18F13K50 or a MCP2200, they're pin compatible with the latter requiring no firmware.

Almost forgot, I updated the first post. Again.

EDIT: Forgot to add that regulator modules will also be used by the Electronic Load Module.
« Last Edit: February 27, 2018, 06:21:03 pm by void_error »
Trust me, I'm NOT an engineer.
 

Offline prasimix

  • Supporter
  • ****
  • Posts: 2022
  • Country: hr
    • EEZ
Re: DIY Modular Test Equipment Project
« Reply #128 on: February 27, 2018, 11:44:01 pm »
I'd like to encourage you to use GitHub Master branch as much as possible, and that important milestones, prereleases or releases simply mark by publishing it where you can include some description or list of accomplished tasks. Making multiple branches especially in early phase is a good source of confusion for one how is following you, want to fork a project and stay synced.

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #129 on: February 28, 2018, 05:31:17 am »
Will switch to master branch as soon as I get to past Rev 0. I'm still making small changes to the schematic as I work on PCB layout with one example being multi-part components which will be swapped around quite a lot. Rev 1A will be the first to be merged into master.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #130 on: February 28, 2018, 07:10:49 pm »
Finally had some spare time to add the voltage regulator module for the analog sections to the draft branch of the related repo on GitHub.
As always, the link has been included first post.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #131 on: March 04, 2018, 08:01:45 pm »
Wasted the whole weekend on PCB layout. Results in first post / on GitHub. There's room for improvement. I haven't included the footprint libraries although I will since there are some footprints I made myself. Not all parts have 3D models yet.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #132 on: March 13, 2018, 07:37:31 pm »
There might be a problem with the +/-5V regulators on the waveform generator schematic, thought I'd redo some math on the thermal side of things and it looks like those LM317L/LM337L won't be too happy at a little under 50mA with a 15V input and I don't want to 'Rigol it' .

I have two options:
1. Use physically larger packages for the regulators
2. Move the analog supplies of everything using +/-5V apart from the AD603 to other rails.

I'm inclined towards number 2 since the DACs can take up to +/-15V and the LMH6642 can easily live off +/- 3.3V. Only the DAC for adjusting the offset will need to be run off +/-15V though.

As for option 1, I'm looking at D2PAK packages for LM317 / LM337 but those take up considerably more space compared to SO-8.
« Last Edit: March 13, 2018, 09:29:59 pm by void_error »
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #133 on: March 14, 2018, 09:54:45 pm »
I have two options:
1. Use physically larger packages for the regulators
2. Move the analog supplies of everything using +/-5V apart from the AD603 to other rails.

I'm inclined towards number 2 since the DACs can take up to +/-15V and the LMH6642 can easily live off +/- 3.3V. Only the DAC for adjusting the offset will need to be run off +/-15V though.

As for option 1, I'm looking at D2PAK packages for LM317 / LM337 but those take up considerably more space compared to SO-8.

Yet again I realize I didn't have my head screwed in properly and while both of the above would work the voltages need to be +/-5V so there's no need for adjustable regulators. 7805/7905 will do just fine. As far as the case goes, D2PAK is HUGE and SO-8 can't handle half a watt... at least with a temperature of 50C inside the case which isn't likely since there's going to be a fan in there.

Luckily the 7805/7905 also come in DPAK cases which are considerably smaller than the chopped up TO-220 which is the D2PAK, they're roughly the same size as an SO-8 and have significantly lower thermal resistance, under the form of 78M05 and 79M05. Junction to ambient thermal resistance doesn't exceed 100C/W so that's only a 50C rise for 0.5W (10V drop @ 50mA) which is well within acceptable limits and real world thermals will be significantly better since it's mounted on a PCB. Problem solved. I choose option 3.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #134 on: March 22, 2018, 05:30:38 pm »
waveform generator 115x95mm.

Nope. That was a bad idea. Plus the case which was my initial choice would have ended up being mostly filled with air so I'm swapping it with this one and making the waveform gen PCB 175x70mm.

Just so this is more fun, it looks like differential signalling might be required since the traces are getting quite long, not to mention that adding a ribbon cable would make things a lot worse. That means adding some differential transceivers and have the UART over RS-485, use RS-485 transceivers for SPI like metioned here, same for the GPO and GPI, differential signalling for the clock (haven't looked into that but it should be able to handle 16MHz), should get away with single ended for the 400kHz regulator sync signal as long as it's buffered on every board I think, the 1-wire bus should be fine since it's really slow anyway.

The only thing I have no idea what to do with is I2C. Any suggestions?
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #135 on: April 10, 2018, 05:17:09 pm »
Small progress update:

After messing around with the idea of using RS-422/RS-485 transceivers I ditched it in favor of LVDS/M-LVDS. Since I also want to reduce crosstalk between pairs I'll be upping the pin count of the bus connector to 40 pins to allow for ground between pairs, although I'm not sure if the differential impedance will affect signal integrity and/or reflections across the ribbon cable too much at the rather low speeds the SPI will be running at - 16MHz clock or lower.
Also, the glue logic used to switch between SPI and the shift register lines will be moved to each individual board so there's only going to be one differential SPI line with an extra line to select who gets clock and data.

Another problem I ran into is having to sample voltage and current simultaneously and while there are simultaneous sampling ADCs out there I couldn't find anything suitable at a reasonable price so I'm opting for a bit of a hack here: clock both AD7683s at the same time, with one outputting it's data directly into the MISO line, while the other outputs into a 24-bit SRAM made out of D-type flip-flops. To get the data from the makeshift SRAM there's going to be a pin used in the same way as the ADC Chip Select. And in case you were wondering, there's a pin-compatible replacement from TI for the currently used ADC which is slightly cheaper - ADS8326.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #136 on: April 30, 2018, 09:43:28 pm »
Minor setback: graphics card RAM died and I have no onboard graphics. Result: Windows commited suicide while attempthing to repair itself.
Took this as an opportunity to boot linux mint in text mode off a USB flash drive and use lynx to navigate the interwebz and also post this simply because I can and I hate typing on my smartphone.
The good thing is that the card's under warranty for another 3 months so I should be getting a replacement within the next 2 weeks so I can get back to adding LVDS to all the boards...
Speaking of which, the GPO and GPI lines will be gone and a trigger line will be added.
Trust me, I'm NOT an engineer.
 

Offline prasimix

  • Supporter
  • ****
  • Posts: 2022
  • Country: hr
    • EEZ
Re: DIY Modular Test Equipment Project
« Reply #137 on: May 18, 2018, 06:33:50 am »
Another problem I ran into is having to sample voltage and current simultaneously and while there are simultaneous sampling ADCs out there I couldn't find anything suitable at a reasonable price so I'm opting for a bit of a hack here: clock both AD7683s at the same time, with one outputting it's data directly into the MISO line, while the other outputs into a 24-bit SRAM made out of D-type flip-flops. To get the data from the makeshift SRAM there's going to be a pin used in the same way as the ADC Chip Select. And in case you were wondering, there's a pin-compatible replacement from TI for the currently used ADC which is slightly cheaper - ADS8326.

Did you possibly consider ADS131A02? It's 24-bit but with very attractive price.

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #138 on: May 19, 2018, 04:42:35 pm »
Thanks prasimix, I had a look at the datasheet and it looks like a candidate for for the Power Supply Module, the Electronic Load Module and the Mains Power Meter Module, the only tricky part id the fact that it requires a 16.384MHz clock, which I could provide via the clock line on the bus and will also be used for switching regulator sync after division, the problem being that is I use 4x PLL on the main MCU I'd have to use a 8.192MHz crystal due to the 64MHz maximum clock limit and send the x4 multiplied by the PLL out the CLKR pin after it's divided by 2.
Since the same clock is used by any other MCUs (PIC18F25K40) they'd have to run at 16.384MHz (4.096MHz instruction clock) unless I divide it by 2 and use the 4x PLL multiplier which is not that big of a problem.

On the bright side, my PC is back up and running. Work will resume as soon as I have enough time and energy to put into this which might be totally random.

I managed to mess around with adding LVDS and changing the bus connector yet again to one with more pins (40) and changing the PCB layout for the UI. I've also been looking into the possibility of keeping the ribbon cable for LVDS and it seems like a viable option as long as I keep stub lengths short (>30mm at the moment) and the clock speeds low, with the highest frequency being 16MHz. If anyone knows why this wouldn't work please don't hesitate to let me know.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #139 on: June 25, 2018, 06:53:46 pm »
After being stuck for quite some time with having to use two 40-pin connectors on each peripheral board due to the daisy chaining requirement for the 595s which makes PCB layout a complete mess, I've ditched the shift registers and quite a bit of the glue logic in favor of a some of 3-to-8 decoders and a MCP23S08 I/O expander.

The lines formerly going to the 595s are now address lines, a sort of bank select for the MCP23S08s. The chip select lines for the SPI stuff (ADCs, DACs, etc) on each board will be the decoded outputs of another 3-to-8 decoder with the 3 inputs connected to the outputs of the MCP23S08 which also offers a level of idiot-proofness (is this a real word?) in the sense that only one chip select can be active at one time in addition to the reduction of the number of lines required on the I/O expander.

I won't be putting any of these changes on GitHub just yet as I still have to fiddle with the pins on the micro when I start working on changing the PCB layout.

Speaking of which... is anyone interested of having the possibility putting your own favorite micro (on a daughter board) so I can add a bunch of pin headers to facilitate that?
EDIT: That would include all of the boards which will have a micro, except for the UI board.
« Last Edit: June 25, 2018, 07:11:46 pm by void_error »
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #140 on: July 14, 2018, 02:37:56 pm »
Speaking of which... is anyone interested of having the possibility putting your own favorite micro (on a daughter board) so I can add a bunch of pin headers to facilitate that?
No more need for that. Switching to STM32s which have an integrated ROM bootloader. I've been looking into them for quite some time but until January this year all the decent development tools weren't free. Now there's this which is basically eclipse with GCC & GDB and works out of the box. No more slapping development tools together.

The MCU of choice is going to be STM32F101VC for the UI. 100 pins LQFP, has a RTC with battery backup so no need for a separate RTCC chip.
ROM bootloader is accessible via USART1. At the moment I'm not too sure about how I'll update the firmware on the MCUs of the other modules so I might have to abandon the half-duplex RS-485 style of communication via UART and think of something else just so I (or you) can flash everything after it's been all put together.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #141 on: November 25, 2018, 02:32:20 pm »
Updated all of this project's github repos, have a look if you want. PCB layouts aren't finished and schematic need some cleaning up. I'll do it when I have the time and energy.
Trust me, I'm NOT an engineer.
 

Offline void_errorTopic starter

  • Frequent Contributor
  • **
  • Posts: 673
  • Country: ro
  • I can transistor...
Re: DIY Modular Test Equipment Project
« Reply #142 on: December 27, 2019, 04:00:21 pm »
Waveform gen is almost finished, everything's now up to date on Github as I finally found some time to work on it. The PCBs need a bit more work, via stitching in some places and spme traces need tweaking. Everything stacks up nicely.
Trust me, I'm NOT an engineer.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf