Collecting Readings from Mettler Toledo Balances
Windmill software lets you continually log data from Mettler Toledo balances, and other instruments with an RS232 serial port, on a PC running Windows. All data is time-stamped and can be imported into Excel either during or after data collection. Our Windmill data acquisition software is currently reduced from £145 to £50. Alternatively, subscribers to the Monitor newsletter (ISSN 1472-0221) can download free logging software: ComDebug. This lets you log data from one instrument and save it in a text file. After collection is finished data can be imported into Excel.
Windmill has been used with a Mettler Toledo balance to, amongst other things, monitor ripening grape weight for wine production.
To use Windmill to collect data from a Mettler Toledo balance: download the software then..
- Run the Windmill ComDebug, select Create a new Windmill Instrument File, and enter your balance's serial communication settings.
- Run the Windmill DDE Panel, Logger or Chart program to save or display data from your balance.
After you have entered your configuration settings with ComDebug, you don't need to use this again and can go straight to the logging and display programs.
"I have succeeded in interfacing four different Mettler Balances to Excel using your free Windmill product and am
DA, Mettler balance user
For an overview of entering the configuration settings see the Getting Started with COMIML and ComDebug page. Specific example settings for Mettler Toledo balances are given below.
COM Port Settings
These must be the same as your balance uses. Check the Mettler "Data Interface Operating Instructions" for your model, if in doubt start with...
|Comm Port:||Select the port to which your instrument is connected.|
In ComDebug's Terminal or Message Screen, enter a command or prompt string to send to the balance to ask for data. Click the Send button, and the instrument should send a reply (see Fault-Finding below if not). Now click the Parse button and enter instructions to extract the data from the balance's reply. Check your balance's Interface Operating Instructions for details of the commands to send, and the format of the balance's reply. The example given below requests a single stable value. Use the non-print menu to enter the carriage return (<CR>) and linefeed (<LF>).
|Example prompt command:||S<CR><LF>|
S is upper case.
|Example data text string:||S S 100.0 g|
|Example parsing:||Ignore Until 0123456789|
Extract Until space
|Instrument Idle Time:||0|
|Data Persistence Time:||5000 ms|
Now open Windmill SetupIML
SetupIML lets you choose how to use individual channels. You can rename channels, set alarm thresholds, set units, etc. SetupIML saves your settings in an *.ims file.
Open Windmill DDE Panel
Use DDE Panel to show your data.
- From the File menu select Load Hardware Setup and choose the *.ims file you just saved.
- Connect your weight channel. You should see the correct weight in DDE Panel.
- Proceed similarly for the Logger and Chart programs.
- Log only when new data is available from your instrument: when a weight changes on a balance for instance. Even if two items weigh the same, Windmill knows that a change has occurred, so no readings are missed.
- Log to a new data file at regular intervals, every hour or every 5 minutes for example. This is useful in continuous, long-term logging.
- Log data only when channels are in an alarm state.
- Log data for a fixed duration, for example during an alarm condition and for ten minutes afterwards.
- Log data when you press the space key on the keyboard
- Use Excel to start and stop logging.
- Log from different channels at different rates.
- Log from different channels to the same or different files.
- Log data from RS232 instruments alongside Modbus and Ethernet devices.
You can use the Windmill Logger or ComDebug program to collect data, and after collection has finished import it into Excel. Alternatively, you can collect data with Excel in real-time by using an Excel macro to read data from the Windmill DDE Panel or RTD server.
If you are unable to get data from your balance go back to ComDebug's Terminal screen. Make sure your command is shown in the prompt grid, like in the picture. Click the Send button: does your instrument reply?
- If you only see your command being sent, and no data...
- Make sure that the balance is switched on and plugged into the PC's com (RS232) port.
- Check that the communication settings you entered in ComDebug match those currently in use by the balance: COM port, baud rate, parity, etc.
- If using a USB-RS232 converter, it's settings must also match those used by the balance - read the USB-Serial page for details, especially point 7.
- If your balance says it is using 2400 baud, 7 data bits and even parity you may have it setup to talk to a printer rather than a computer. Use the balance's menu to change the Peripheral Unit from Printer to Host.
- Make sure your balance's send mode is not set to off. Check the balance's Send mode menu.
- If you still have problems then get the balance to send an identification message. Switch it off and then on and it should send identification string I4, e.g. I4 A "0123456789". If not check your cable. At least three connecting lines are needed: Data line from the balance (TxD signal), Data line to the balance (RxD) and Signal ground line (SG). If possible try swapping the cable between the balance and the PC for another to see if that is the problem.
- If still no luck see our Testing Serial Port
- If, in ComDebug you see data coming in but DDE Panel isn't showing it, you may need to edit your parsing settings.
Go to ComDebug's Terminal or Message Screen, click the Parse button.
Enter your Ignore and Extract Settings and click the Step menu. Is your data shown in the Value column?
If not adjust your settings.
- If you are getting accurate data readings, but much slower than expected, change your sampling rate. With COMIML, Windmill can make 5 readings per second per channel. So it can record one weight measurement every 0.2 seconds. If you have the sampling interval set much smaller than this, then Windmill may slow down considerably and only make a couple of readings per minute.
Have you successfully used Windmill with your balance? Let us know about your project.
Tip: When using Google+ comments alert us by adding +Windmill Software