Per Malmberg
Everything is possible, including the impossible. It just takes a little longer…
Everything is possible, including the impossible. It just takes a little longer…
Jan 30th
I’ve begun implementing support for another output format generated by Statlink. In this format, some additional information can be logged and thus entered into a database.
Jan 14th
I’ve just uploaded a beta 1 version of the flat file to database conversion tool I’ve been working on. You can download it here: (beta download no longer available)
To run it you’ll need to extract the files to a folder of your choice an then edit the settings. The “settings.xml” that comes with the archive is setup to work with the files produced by Husdata.se’s Statlink software, as well as Lämpömittari (although I have yet to verify this).
The configuration should be pretty self explanatory. There are really only a few settings you’ll need to change; the FlatFileToDb/DatabaseConnection/* and the FlatFileToDb/DateSortedFiles/RootPath settings.
If you’re going to use this software with Statlink, you’re now all set. Users trying to get it to work with Lämpömittari need to edit the FlatFileToDb/DateSortedFiles/* settings as the filenames are likely not the same as Lämpömittari produces.
I don’t recommend changing the <../File/RegExp>-tags unless you really know how regular expressions works.
Once you have the settings sorted, you can now use the SQL script file that comes with the archive to create the required database on your MySQL server. If you’re not using the default configuration in the FlatFileToDb/DateSortedFiles/ section you’ll have to create your own database with associated tables.
There are two modes the application can run in; Auto parsing and manual. To enable the auto parsing mode you’ll have to start the application using the command switch “/auto”, ie. “c:\path\FlatFileToDatabase.exe /auto”. When in auto mode, most of the user interface is disabled.
Exiting the application can only be done using the exit-button, other ways (ALT-F4 etc.) will only hide the application window; it will then only be available through a double-click on the applications icon the notification area (or Systray, depending on who you ask) on your Start-bar.
Even though I doubt that by using this application you put you and yours in danger (or your files for that matter), you use this software at your own risk.
Jan 11th
The work on the new TWatch (I’ll likely change that name later on) has begun. I’m currently working on the Flat-file-to-Db application. The core is about 80% finished and working fine.
The main purpose of this application is to read the flat file database produced by Statlink, but it will also have a limited support for other flat files; as long as the values are in the form date-value, and one item per line, the application will be able to read it (with the appropiate configuration, of course).
I’ve decided to make this applications work in two modes:
The First Use Conversion mode will have a simple user interface allowing the user to make some choices before the flat-file-to-database conversion starts.
The Monitoring mode will work in the background, parsing the flat files in real-time. Naturally, this is the mode the application will run in once the initial data conversion is complete.
The application is configured using a XML file. Seeing as the configuration is very simple I’ve opted not to make a configuration dialog; this might be added at a later time if enough requests are voiced.
I’ve opted for a MySQL database since it is very easy to install and configure, and it also runs good on older computers with good performance. The fact that it also has very good support for .Net didn’t make the choice any harder
Jan 8th
I got a response from Dallas-Maxim today regarding the pure C# link layer. Apparently they have no more recent release of that software than the one linked in their forums which is from 2004. *cry*
Update: I just received word that there won’t be a release of this package before the Vista-drivers are completed, which are scheduled for release in ~3 months. And then add the time it takes them to complete the package for release…
Jan 7th
Today I’ve spent some time thinking about what I want to do with TWatch and here’s what’s going to happen:
I feel that continuing working from the flat files delivered by Statlink, puts quite a lot restrictions on what I can do without writing a database-like layer around the files. The current TWatch does its job nicely, but adding more features requires more work than it should due to the lack of a real, searchable database.
I’ve opted to use MySQL as the database since it is freely available and very easy to install, even for someone who’s never done it before.
That’s all for today, now it is time to do some sketching on the design. Cheers!
Jan 6th
Today I found a topic (registration required) on Maxim-Dallas forums about an alpha-release about a pure C# 1-Wire link-layer. This topic was started on June 25:th 2004. I quickly looked through the three pages in search for the post that would state where I could get my hands on the latest version of this framework. To my very big disappointment, they still haven’t released this package, not even an updated version that includes the bug fixes posted by other developers in that thread.
It’s been two and a half year, and they’ve still not released it! I wonder if someone switched the numbers for the deadline around; 2060 instead of 2006?
Hopefully someone who knows can provide us all with an update on the status of this project – I’m quite sure there’s plenty of developers who’d like to know.
Jan 6th
It is indeed the home built adapter that is the cause of the problem – it does not support strong power pull-up the .Net code tries to initiate during the temperature conversion. What I need is a DS9097U, or alternatively to power the attached devices using a separate wire.
Jan 5th
Today (night rather, it is 01:33 *cough*) I built myself a RS232/1-Wire adapter (replacement for a DS9097E) and managed, using Maxim/Dallas .Net wrappers for their J# classes, to read the current temperature value from a 18S20-temperature device. Apparently the underlying J# code is written for J# 1.1, which feels a bit…old.
Anyway, there was only one problem along the way; the method doTemperatureConvert() in the OneWireContainer10-class only throws a OneWireException, and so does all other methods that writes to the sensor network. In the end I had to resort to use a call to DSPortAdapter.putByte(0×40) which is the same as calling doTemperatureConvert(), but on a lower level.
I suspect that it is the home built adapter that doesn’t allow me to write to the device, but I’ll have to dig deeper into this. I seems I’m not the only one with this problem.
Jan 4th

Peter, over at husdata.se, has released a new version of his software for the IVT heatpumps. The major improvement is the ability to place the status labels on a custom background, so that you can create your own view of your installation – very nice! Since he hasn’t posted any screen shots on this feature, I’ve added a screen shot from my own setup so you can see what it is all about. I made the background image in SketchUp, a very easy-to-use 3D rendering program.
Another new feature that has been added are graphs for the temperature readings, also a nice thing to have. Depending on which features Peter intends to implement TWatch might become obsolete… I’ve had some thoughts to move from todays flat-file database to a SQL database to both increse the parsing speed and to ease the addition of new featers to TWatch.
Lastly, I’ve ordered a few samples of the 1-Wire temperature sensors from Maxim and I’m going to try their .NET API, should be an interesting experiment.
Update: Someone else also liked the 3D model I made: Click me
Recent Comments