© Copyright 2005, Peacoque Labs

Background; HamsterTracker™ Point Of Sale display

HamsterTracker™-ed FT100 Point Of Sale (POS) display in action:

FT100 Point Of Sale display in action.


I recently (end of September, 2005) obtained a very nice Point of Sale - Customer display (commonly referred to as POS-display. To find out more about it, I was planning to take it apart and analyse it. Then I looked under it:
Here I learned that I've got a true and original FT100 Display.

I also need a DB25 serial connector,

as well as a regulated 5 volt powersupply.
Picture of the underside of POS-display

In this picture you can clearly see the DB25 connector.

The 5 volt connector is also a pretty standard one.

Picture of the underside of the underside of POS-display.  ;-)

A 5 volt regulated (and stabilized) powersupply, was not a problem. I've build this little gem, when I was something like 13 years of age. (It was the powersupply of my then build alarm system).

I just needed another connector, and it was off to go.

The RS232 cable gave me a bit more trouble:

I'd thought I'd try a Modem cable first, but that gave absolutely no response, whatsoever. Then I found a very long cable with just the right connectors: a DB25 Male connector - cable - DB9 male connector. Before cutting it up, and soldering, I gave it a go: YEAH, PRESTO! I got my cable!

Ofcourse I had to develop some software in order to test the cable. More details on that below
Picture of the underside of the underside of POS-display.  ;-)

I also needed to find some kind of documentation.

Picture of the display in closeup
This is the display I had in mind, when playing around with this

Visual Basic (6.0) Software

The most important routines are ofcourse the FT100 drivers. I've kept it to a minimum here:


' POS Initialize stuff:
Private Sub FT100_Initialize()
    ESC = Chr(27)
    FT100_CLS = Chr(12)
    FT100_SELECT_LINE_1 = ESC & "QA"
    FT100_SELECT_LINE_2 = ESC & "QB"
End Sub

These are the (minimum) of command's the FT100 display needs.

Then you'll need a sort of display routine:


' Display a string on a certain line on the FT100 P.O.S. display:
Public Function FT100_Display(ByVal LineNumber As Byte, ByVal DisplayString As String)
    With FT100
        Select Case LineNumber
            Case 1:
                .Output = FT100_SELECT_LINE_1 & DisplayString & vbCr
            Case 2:
                .Output = FT100_SELECT_LINE_2 & DisplayString & vbCr
        End Select
    End With
End Function

The following routines, write their appropriate data to the second line of the POS-display:


' Timed display stuff:
Public Sub UpdateDistance()
    If TotalDistance = "" Then Exit Sub             'If not found, then ignore
    Call FT100_Display(2, "Total " & TotalDistance)
End Sub
Public Sub UpdateDistanceToday()
    If TodayDistance = "" Then Exit Sub
    Call FT100_Display(2, "Today " & TodayDistance)
End Sub
Public Sub UpdateMaxSpeedToday()
    If TodayMaxSpeed = "" Then Exit Sub
    Call FT100_Display(2, "Max today " & TodayMaxSpeed)
End Sub
Public Sub UpdateMaxSpeedKmhToday()
    If TodayMaxSpeedKmh = "" Then Exit Sub
    Call FT100_Display(2, "Max today " & TodayMaxSpeedKmh)
End Sub
Public Sub UpdateLastUpdateTime()
    If LastUpdateTime = "" Then Exit Sub
    Call FT100_Display(2, "Last update " & LastUpdateTime)
End Sub
Public Sub UpdateTimeToday()
    If TodayTime = "" Then Exit Sub
    Call FT100_Display(2, "Time today " & TodayTime)
End Sub
Public Sub UpdateTotalMaxSpeed()
    If TotalMaxSpeed = "" Then Exit Sub
    Call FT100_Display(2, "Max ever " & TotalMaxSpeed)
End Sub
Public Sub UpdateTotalMaxSpeedKmh()
    If TotalMaxSpeedKmh = "" Then Exit Sub
    Call FT100_Display(2, "Max ever " & TotalMaxSpeedKmh)
End Sub
Public Sub UpdateTotalTime()
    If TotalTime = "" Then Exit Sub
    Call FT100_Display(2, "Total" & TotalTime)
End Sub
' Show day number and time on line 1,returns current second:
Public Function GetAndUpdateCurrentTime() As Byte
strTime As String
tmpSeconds As Byte
    strTime = Format(Time, "hh:mm:ss")
    tmpSeconds = Val(Right(strTime, 2))
    strTime = DateDiff("d", constStartDate, Date) & ":" & strTime   'Add day number
    strTime = Space(14 - Len(strTime)) & strTime                    'Align it
    FT100.Output = FT100_SELECT_LINE_1 & "Lucy's" & strTime & vbCr  'Display it
    GetAndUpdateCurrentTime = tmpSeconds
End Function

Create a new form, and add two controls: MSComm control, for the serial communication and a Timer control.

Screenshot of the form, with added controls.

This got me writing on the Form specific routines:


Dim FT100 As MSComm
' Form stuff:
Private Sub Form_Load()
    Call FT100_Initialize                           'Initialize FT100 control variables.
    Set FT100 = Me.MSComm1                          'Make link with MSComm control.
    With FT100
        .PortOpen = True                            'Enable communications with FT100.
        .Output = FT100_CLS                         'Clear the screen, because when powered on,
                                                    'the display displays arterisks.
        .Output = FT100_HORIZONTAL_SCROLL_MODE      'Set horizontal scroll mode.
    End With
FT100_Display(1, "   Peacoque Labs")       'Display an intro
    Call FT100_Display(2, " HamsterTracker(tm)")
    Me.Timer1.Interval = 1000                       'One second.
    Me.Timer1.Enabled = True                        'Start the timer.
    Me.Show                                         'There is not a whole lot to show, but anyway.
End Sub
' More form stuff:
Private Sub Form_Unload(Cancel As Integer)
    FT100.PortOpen = False                          'Close in a fasionly way.
End Sub

Putting it all together

Here is the main timer routine, that controls the display every second.


' The Timer handler:
Private Sub Timer1_Timer()
    SecondsCounter = GetAndUpdateCurrentTime    'Always update time every second
    Select Case SecondsCounter
        Case 0:
            Call DownloadData                   'Refresh data once every minute
            Call UpdateDistance
        Case 10:
            Call UpdateLastUpdateTime
        Case 20, 24, 28:
            Call UpdateMaxSpeedToday
        Case 22, 26:
            Call UpdateMaxSpeedKmhToday
        Case 30:
            Call UpdateDistanceToday
        Case 40, 44, 48:
            Call UpdateTotalMaxSpeed
        Case 42, 46:
            Call UpdateTotalMaxSpeedKmh
        Case 50, 54, 58:
            Call UpdateTotalTime
        Case 52, 56:
            Call UpdateTimeToday
    End Select
End Sub

Monday, October 29, 2007 Day 123 current treadmill total: 181,145.38 meters! (19:05 CET)

Geekin' Weekend Project

I've been working on assembling, installing and tuning my new 'Dream Machine'
for over three (very enjoyable) weeks now.

The dowside of this new system is, that it has only one
serial communications (RS-232) port on the motherboard.
And this port is used by the HamsterTracker™-Data-Collector hardware.

Remember my Point of Sale- or (more simply stated) POS-display?
That one too, uses a serial communications port.
So I bought a USB to RS-232 converter. And I moved a USB card from the ol' PC to the Dream Machine
Which does the job fine (I must add).

Because the USB card has a port INSIDE the casing, I thought I would jam the USB-RS-232-thing,
also inside the computer case.
That required some soldering and stuff:

Weekend project, installing USB-RS232 device.
This will, after soldering, hookup to the USB-thingy.

Weekend project, installing USB-RS232 device.
The new soldered cable hooks up to a RS-232 jack that I can fit in the back.

Weekend project, installing USB-RS232 device.
Here's how it all looks hooked up,
before installing in PC.
Note the connector on the right (a printer connector),
remains unused ... I just didn't want to leave an empty hole in there.

Weekend project, installing USB-RS232 device.
On the back of the computer,
it's now installed in the dead middle of this photograph.
(To the left of the VGA connectors (one is a DV-I or something,
which is fitted with a VGA converter-connector.
(That was supplied with the Graphics card btw.)

Note the three 'new' USB (2.0) connectors,
that have also been installed

Weekend project, installing USB-RS232 device.
The USB plug plugged in into the back of the newly installed USB card.
(I should have dusted that card before installing, I know)

Weekend project, installing USB-RS232 device.
It's still messy,
but it did clear ONE wire from the USB thingy!

I'll work on the wire-ing as soon as all is installed and functioning
the way we envisioned here at HamsterTracker™

And we are really getting there!

Almost forgot: Proof of concept:

Here's a mute video of the POS display in action:

Monday, November 26, 2007 Day 151 current treadmill total: 189,928,72 meters! (18:00 CET)

Geekin' Weekend Project

This weekend the Temperature-measurement-software-module,
development was (finally) finalized !
As a test; this software module was (finally) included in the POS display,
showing the living-room temperature as well as the other sensor-temperature under Lucy's bedroom:

The FT100, Point Of Sale display, geekin' weekend project.
" Lucy was in her bedroom when this photograph was made,
note a few degrees rise in temperature.
" - HamsterTracker™-Geek Dept.

The FT100, Point Of Sale display, geekin' weekend project.
" The livingroom temperature... " - HamsterTracker™-Geek Dept.

The degrees symbol ° was a bit of a puzzle before it displayed correctly.

It took us a while to figure out the communications with the Point Of Sale (POS) display,
was set to 7 bits; this setting ignored all special characters to display.

So using the original ! documentation, we found that a dip-switch setting should be modified.

Here's the hunt,
for finding the dipswitches.

The FT100, Point Of Sale display, geekin' weekend project.
" It's not under the base,
it's under the display.
" - HamsterTracker™-Geek Dept.

[ The box on the right, is a powersupply I built when I was 13/14 years of age.
It has been converted, over the years,
from a 15 volt DC unit to the current 5 volt DC unit.
this supplies the power to the POS-display.

The FT100, Point Of Sale display, geekin' weekend project.
" Dip-Switches 3 and 4 should be set in the 'OFF' position. " - HamsterTracker™-Geek Dept.

I couldn't wait to tell Lucy...

My hamster Lucy being ULTRA CUTE !
" But, Why ? Dude ? " - Lucy

My hamster Lucy being ULTRA CUTE !
" I can see the analogue thermometer, from over here ! " - Lucy

My hamster Lucy being ULTRA CUTE !
" It reads 20 °C,
that's a proper... 68 F
If I did my math right ...
" - Lucy

Tuesday, February 26, 2008 Day 243 current treadmill total: 215,275.66 meters! (19:15 CET)

Geeking Weekend Project!

This weekend (up until today and still going on) project was the POS-Display
(POS = Point of Sale); which is now dubbed internally as the HamsterTracker™-Clock-project.

In an attempt to save some time in the morning,
I thought it would be cool for the HamsterTracker™-Clock to show the latest rating.
Figuring if the clock shows it every minute, then there's no need to check the webpage.

I needed a brush up on my PHP-Programming and SQL query language knowledge,
to develop private PHP-(programmed)-Page to supply the latest data (using SQL),
for the HamsterTracker™-Clock to retrieve.

Then, ofcourse, the HamsterTracker™-Clock software also
needed some serious enhancements.

Let the tests begin:

So I setup a Demo Rating, to show to you how it looks like:

Here's a (hypothetical) 3 star rating

Geeking Weekend Project: HamsterTracker(tm)-Clock-Ratings.
" This is how the rating shows up on the HamsterTracker™-Clock,
alternating between 'graphical' and percentages
while showing the number of votes.
" - HamsterTracker™-Geek Dept.

Geeking Weekend Project: HamsterTracker(tm)-Clock-Ratings.
" Here's how this rating shows up on a Palm LifeDrive. " - HamsterTracker™-Geek Dept.

Casting a (wireless) vote

Geeking Weekend Project: HamsterTracker(tm)-Clock-Ratings.
" Casting a 4 star rating,
to show how a 3.5 (70%) average looks like.
" - HamsterTracker™-Geek Dept.

It shows up like this:

Geeking Weekend Project: HamsterTracker(tm)-Clock-Ratings.
" Instantly updated (a minute later)
Note the number of votes on the bottom right, it also changed !
" - HamsterTracker™-Geek Dept.

This morning I had an extra 'minute' with Lucy

I told her about her last rating, at this time of writing; (4.78 - 9 votes see yesterday, below),
she responded:

My hamster Lucy dancin' to tha tunes on the couch !
" I love good ratings, Dude.
Makes me wanna Supah-fly !
" - Lucy

Monday, June 16, 2008 Day 354 current treadmill total: 235,505.94 meters! (19:10 CET)

Geekin' Maintenance Fun at HamsterTracker™

Last week the FT100 - Point of Sale Display started to goof up seriously.
Between displaying Lucy's and HamsterTracker™-Website statistics,
it was displaying a a whole lot of nonsense, hundreds of characters at one go.

After checking the HamsterTracker™-Software that is controlling it,
it took a little while to deduce that the power supply was causing this.

This 220 Volt AC to 5 Volt regulated powersupply,
was outputting a solid 1.15 Volts when I measured it (with my new Volt-meter).
So it was time to open it up, (assembled when I was 14 years of age, opening it approx. 27 years later):

Fixing the FT100 (Point of Sale) Power Supply.
" This old beauty has powered a lot of projects ... " - Mathijs

Fixing the FT100 (Point of Sale) Power Supply.
" Opening it ... " - HamsterTracker™-Geek-&-Fix Dept.

Fixing the FT100 (Point of Sale) Power Supply.
" Getting all the stuff ready; Multi-Meter, Solder Iron, Solder & Screwdrivers ...
Together with some obligatory pliers ...
" - HamsterTracker™-Geek-&-Fix Dept.

Fixing the FT100 (Point of Sale) Power Supply.
" After opening:
the powersupply cable connection broke (1)
as well as the problem area became apparent (2)
" - HamsterTracker™-Geek-&-Fix Dept.

The heating and cooling off,
has (over the years) worn down the (2) connection,
thereby outputting only a slight part of the total power.

Fixing the FT100 (Point of Sale) Power Supply.
" Here it is all (re-)soldered again. " - HamsterTracker™-Geek-&-Fix Dept.

Fixing the FT100 (Point of Sale) Power Supply.
" Re-Assemblin' ... " - HamsterTracker™-Geek-&-Fix Dept.

Fixing the FT100 (Point of Sale) Power Supply.
" It has been running since this fix ... " - HamsterTracker™-Geek-&-Fix Dept.

Then Lucy asked:

My hamster Lucy inspecting the repaired FT100.
" Tell me it DOESN'T show Pine-Seed consumption, Dude ! " - Lucy

" It [ (un-)fortunately ] doesn't. Dear Lucy ! " - Mathijs

© Copyright 1994 - 2008, Peacoque Labs
ing. Mathijs A. van der Paauw