Featured Post

Site Navigation is in the Left Column

Friday, August 27, 2021

Constructed Log File Management Library (C++)

To track progress of the required metrics of the freezedrying process,I needed a logging library.

Initially it was made to track events and times, but I decided to expand it to use the high-precision clock in the crono library.  This adds the ability to not only perform event logging functions, but also high-precision scientific data logging 

The library will record elapsed time accurate to the nano-second, if your hardware is capable of such precision.  If your hardware is not capable of nanosecond precision, the library will automatically adjust to the highest precision the hardware is capable of.

Wednesday, August 18, 2021

Trying to Resolve Temperature Errata

Occasionally, temperature readings will spike.  This is most likely due to reading the Hot Junction register before ADC is completed.   The native library does not have a means to handle this, so I am collaborating with the designer of the thermocouple amplifier to develop or repair the native library to prevent the errata.

Tuesday, August 17, 2021

Duty Cycle Programming Complete

The duty-cycle routines have been written and tested.  

Now, the relay library includes functions to turn the relays on and off as well as functions to control the duty cycle of the device controlled by the relay.

For instance, I do not want to have to constantly check and see if the compressor is being ran too much. With the duty cycle routines, I can program the duty cycle for 90 seconds on and 90 seconds off.  All the main routine needs to do is call for service. The relay will immediately turn on for 90 seconds, then turn off for 90 seconds.  If the main program is still calling for service, the relay will turn on for 90 more seconds.

The duty cycle is completely driven by event handlers and timers.  So the main loop does not need to check the duty cycle times or anything like that.

Monday, July 19, 2021

Duty Cycle Library Development Started

I have begun writing a library that allows me to regulate parts of the freezedryer according to a programmable duty cycle.

Several aspects of the freezeDryer need a duty-cycle for achieving its goal.  For instance, the compressor cannot run continuously as it tries to reach the extreme temperatures required for the trap.  For instance, the compressor will run for a period of time, then it will need to stop for a period of time in order to cool down.  

This library will allow me to "call" for cooling.  The library will then cycle the compressor on its own until I stop calling for cooling.

Sunday, June 27, 2021

Second Relay Array Ordered

I have ordered a second relay array.  I decided to order it because it will help facilitate a second stage cooling unit to be added without having to wait for it to arrive.

There are several aspects of the Freeze Dryer that needs to be controlled by relays.

The compressor needs to be cycled in order to keep it from overheating.

The compressor fan needs to be cycled independent of the compressor.  If the compressor is off, the fan may still need to be on in order to continue removing heat from the condenser coil.

The fan in the trap needs to be cycled.

The fan in the chamber needs to be cycled

The compressor needs to be cycled

The second stage cooling system may not be needed, but if it is, it will need a relay.

Wednesday, June 9, 2021

Process Control Logic Framework Constructed

Framework for processing logic has been created.  

Process indicators are updating based on sensor feedback.


Sunday, May 23, 2021

Log Graphing Added

Added the ability to scale the graph to logarithmic functions.  This allows extremely large scales to be plotted in smaller areas.  

This can be expanded to create log-linear and log-log graphs.

Graph Calculations abstracted

In drawing the graph (lacking any C++ graphing libraries for the RPi) I had to scale the measurements to fit in the graph area. I abstracted the calculation so it can be used for any size graph with any span.  This will allow the graph the be zoomed in to in future enhancements

Charting extended

Charting is now working on both the x-axis and the y-axis. 

Scaling to temperature and pressure has been completed. 

Charting across both chambers has been completed.

Saturday, May 22, 2021

Charting now working

I have added out-of-band charting functions to the code that will allow me to chart in GTK:DrawingAreas without having to trigger an event. 

It sounds simple, but apparently GTK::Draw is not really robust when it comes to just drawing a simple line. They prefer you create and event handler and have the event handler draw the line when the event is triggered. 

 Unfortunately, Unix, C++, RaspberryPi combination is the perfect storm for zero interactive grahping support.

Saturday, May 8, 2021

GUI now functioning

After a few small setbacks, I have reloaded the Operating System and Integrated Development Environment on the Raspberry Pi. I was then able to add the GTKMM GUI libraries in the IDE. Now I have a functioning GU?I for the Freeze dryer project up and running. I am running Raspian OS with the Codelite IDE and the GTKMM GUI library. Once the GUI was up it was fairly easy to import all of the old Command Line Interface libraies for the sensors and relays. They were designed from the ground up to be ported to a GUI, so it went pretty smooth.

Monday, February 22, 2021

Pressure Sensor Coding Done

I have developed the driver for the pressure sensor.  It appears to be functioning correctly.

Thursday, February 11, 2021

The Parts have Arrived

The relays are mounted and wired to the board.

The Pressure sensor has its contact points soldered in.

Wednesday, February 10, 2021

Ordered Relay Array

I ordered a 4-relay I2C control module and 4-40 amp zero-crossing solid state relays.  These will be used to control parts of the freeze dryer, such as the compressor, the vacuum pump, the second stage cooling unit, the cooling fans in the two cold chamber etc.

Ordered Pressure Sensor

I ordered the pressure sensor for the vacuum chamber.  I found the MPRLS0025PA00001A pressure sensor.

It has a 24-bit Analog-Digital-Converter reading a max pressure of 25 psi.  

It also has an I2C interface

Monday, January 4, 2021

RDP sevice up and running

I added an RDP service to the RPi so I can work on code form anywhere on the planet.

Alert Limit Function Complete

Function to read and write Alert Limit registers has been completed. 

Alert Hysteresis Registers Tested

 I have completed round 1 testing of the alert hysteresis registers and associated functions.  

Hysteresis settings allow the user to set a range of acceptable temperatures. If the measured temperature is outside that range, the alert will go to a set state.