Wednesday, January 27, 2016

Paint Flow Control Project, Chapter 3.21, Check is in the Mail!

Thomas Nguyen, my cohort at Vivid Inc., tells me that they are expecting a check from UEI for Thomas and me to provide them four control systems comprising the Beaglebone Black (BBB), the 4D Systems Touch-Screen LCD and my Fuzzy-Logic-based control software. I believe that one controller will be used by Vivid Inc in their Santa Clara facility and that UEI plans to install three of the controllers in their painting facility in China. I understand that UEI will order an additional eleven systems if the first four work satisfactorily in their China facility.

I provided a list of the components, an Agreement for the development effort and a Software Licensing Agreement to UEI and Vivid and am expecting that they will authorize me to go ahead with the project.

Accordingly, I am elated that the project will be going ahead. I had done considerable work with the Fuzzy Logic algorithm and the simulation code that I reported in previous posts. And now I need to complete a few more tasks:
  1. Produce an interface board for the BBB to interface with the flow meter and the pump control,
  2. Redesign the enclosure to accommodate the BBB and the LCD Touch-Screen,
  3. Complete the Fuzzy Logic closed-loop software.
The BBB will need an interface board to output a 4-20 mA current for controlling the paint pump and for inputting the 4-20 mA current from the flow meter. I had gotten started designing the board using Kicad (http://kicad-pcb.org/) and need to finish up the design, then go on to manufacturing the board. It's a simple Voltage-to-Current circuit using an LM324 opamp and some transistors to produce the 4-20 mA current from the BBB's Pulse-Width-Modulation (PWM) output. The input current from the flow meter requires only a resistor to produce 0 to 1.8 VDC to be measured by the BBB's Analog-To-Digital Converter (ADC). I had made a similar Voltage-to-Current converter circuit for my Microchip paint flow controller board a few years ago and so will use a similar circuit for the BBB.

Here's a partial circuit schematic:
Voltage to Current Converter Schematic (partial)
and the layout:
Voltage to Current Converter Board Layout.

Previously we were planning on using a Digi International BL2600 Single-Board-Computer (SBC) for controlling the paint flow and a PC with a GUI to communicate with the BL2600 to establish the paint flow set-point and other parameters. I designed an enclosure for the BL2600 using the software from Protocase (http://www.protocase.com/). However, Thomas suggested eliminating the PC and instead use a Touch-Screen LCD attached to the BL2600. It didn't seem practicable to attach a Touch-Screen LCD to the BL2600 and then I hit upon the idea of using a low-cost SBC such as an Arduino or a Raspberry PI or a Beaglebone Black board with a 7" LCD Touch-Screen. I selected the Beaglebone Black (BBB) since it is more powerful than the others and has more on-board analog I/O with its Analog-To-Digital Converter (ADC) that I can use to measure the current from the flow meter and its Pulse-Width-Modulation outputs that I can use to produce a 4-20 mA current to control the paint pump motor. Consequently I will need to redesign the enclosure to accommodate the BBB and the 4D Systems LCD Touch-Screen. My original enclosure design is shown below. I got a quote from Protocase for a few boxes but of course I'll have to get new quote for the new enclosure design for the BBB and 4D Systems LCD. Fortunately the Protocase design software is quick and easy to use. I haven't yet purchased any enclosures from Protocase but I am fully expecting their products to be first-class.

Protocase Enclosure for Digi BL2600 SBC.
The BBB can run Linux operating systems. I installed an updated Debian Linux OS, the Python interpreter along with MatPlotLib etc as I mentioned in my previous post. My Fuzzy Logic simulation code ran just fine with only a few mods to the code to comply with the Python 2.7 version. I did have to resize the screen code to make it fit. The result is shown in the crude photo below, taken in my office/lab with the BBB and the LCD sitting in the 4D Systems cardboard box on my desk.

Fuzzy Logic Simulation Code Running on Beaglebone Black with Attached 4D Systems 7" Touch-Screen LCD.
Now to get on with the project for UEI and Vivid Inc.

No comments:

Post a Comment