OSI PI is a historian database. I had a task to connect a python application to this database. Unfortunately, the vendor doesn’t support Python (odd, they are named “PI”, but I digress). Additionally, the drivers provided by the company initially didn’t work. This post details how I was able to finally connect python to OSI PI. It may not be the most elegant, but it functions for the purposes of my application Read the rest of this entry »
Archive for category Programming
Recently, I needed to access the quantized coefficients of a JPEG image. Fortunately, MATLAB has an amazing JPEG tool box that makes this an easy to accomplish task. Read the rest of this entry »
In programming, you will often want to match a pattern of text against a string or file. This can be helpful to do everything from validating runtime arguments to processing data during execution. Regular Expressions (or regex for short) provide you with the syntax to be able to do everything from very simple to very complex pattern matching in both Unix/Linux commands and in programming.
There are many different flavors of regex. Each programming language uses slight variations on the syntax, and each also has its own different shortcuts. The most commonly taught and documented regular expressions are Perl or Perl-compatible regex. Perl compatible regular expressions (PCRE) are used in .NET, Java, Ruby, Python, and many more languages. Again, each language has its own variation, so you’ll need to find the exact syntax for your particular language. All of those will be very close to the Perl regex I’ll document here.
Read the rest of this entry »
This is a short series on how to create a PHP SOAP based web service and WSDLs. We will start with setting up the developer environment, move on to a simple “Hello World” example and then move through a few examples of increasing complexity. Hopefully after this is done we can expand on the examples to create a web service as simple or as complex as we want. We will also build a simple client interface for each service to demonstrate how to access the new web service.