Lissajous Clock

by Gammawave in Circuits > Clocks

9925 Views, 94 Favorites, 0 Comments

Lissajous Clock

DSCF7349_2.png

Having previously made a couple of clock projects with different themes I wanted to retain the differentiation on the next clock themed project. Therefore, there would be no Neopixels or mechanical indicators and in this case elected to use an LCD display.

Yet another departure was with regard to the microcontroller which previously had been a Microbit and this was to use a Raspberry Pi Pico.

However, not wanting to go for a classic numeric display the plan was to display the time using Lissajous figures in the style of a carriage clock, using wood, Acrylic and Brass.

The attached video shows 29 minutes compressed in to 27 seconds (Showing time from 21:09 to 21:38), to illustrate the changing figures.

Details

This project displays the time using Lissajous figures on a (320 x 240) IPC LCD, two figures for hours and two figures for minutes and the seconds as a progress line.

Using a Raspberry Pi Pico (Pico Lip 4MB), programmed in MicoPython V1.18

Time is set with a RGB rotary encoder with the time maintained by an RTC (RV3028).

Powered via 5V USB with a Lipo (3.7V/500mAh), battery backup.

Current Consumption ~70mA

This is all contained within a wooden and Acrylic enclosure with brass accents in the form of a Mantel/Carriage clock complete with handle. Measuring 140(W) x 65(D) x 187(H) mm.

Downloads

Supplies

Raspberry Pi Pico Lipo

Pico Display Pack 2.0 (320 x 240) IPC LCD

Pico Omnibus (Dual Expander)

RGB Encoder Breakout

RV3028 Real Time Clock (RTC) Breakout

Switch - Momentary SPST

Switch - Rotary SPDT

Brass sheet - 0.5mm

Acrylic sheet Clear - 3mm

Acrylic sheet Black - 5mm

Vent Grille Covers - 45mm

Straight Pin Header 1 row x 36 way - Qty 5

Right Angle Header 1 row x 36 way

Straight PCB Socket 1 row x 10 way - Qty 16

LiPo Battery 3.7V/500mAh

Stripboard

Jumper wires (socket to socket) - Qty 24

Jumper wires (socket to pin) - Qty 4

Handle Bow type 110mm(L),x 22mm(H)

Decking Plank 120mm(W) x 180mm(L) x 24mm(D) - Qty 2

Screws - M2 x 16mm - Qty 6

Screws - M2 x 8mm - Qty 10

M4 Allen bolts 25mm - Qty 4

M4 Allen bolts 50mm - Qty 4

M4 Allen bolts 10mm - Qty 2

M4 threaded insert nuts - 10mm(L) - Qty 10

M4 screws contersunk 25mm - QTY 4

Stick on feet - Qty 4


No affiliation to any of the suppliers used in this project, feel free to use your preferred suppliers and substitute the elements were appropriate to your own preference or subject to supply.


Tools

Step cone drill bit 4 to 12mm

2mm drill bit

5mm drill bit

7mm drill bit

9mm drill bit

Counter sink bit 8mm

Counter sink bit 10mm

Counter sink bit 12mm

2mm Allen Key

4mm Allen Key

Saw

Drill

Oscillating Multitool

Combination Square

Scribe

Marker

Soldering Iron

Solder

Clamps

Sander


Know your tools and follow the recommended operational procedures and be sure to wear the appropriate PPE.

Lissajous Figures

Lissajous_line.png
Lissajous_circle.png
Lissajous_2lobes.png

Lissajous figures named after Jules-Antoine Lissajous (Also known as Bowditch Curves after the initial work of Nathaniel Bowditch), who devised a method to study compound vibrations. Originally employing pendulums, tuning forks and optical methods. Reflecting light from mirrors on two tuning forks vibrating at right angles will display Lisssjous figures as will other devices such as Harmonographs and Pantographs.

Different patterns will be produced by the variation in frequency and phase between the two input stimuli.

Lisaajous figures are used in many areas Acoustics, Electronics and Communication to name a few areas.


We can forego the mechanical methods and produce them using mathmatical calculation.

Assuming sinusoidal waveforms as they are applicable to both mechanical and electrical systems and simplify the mathematical and visual process.

If we use Excel as our display for our compound waveform.

Assume two sinusoudal waveforms of the same amplitude, phase and frequency one assigned to the x axis and one to the y axis these representing our two tuning forks.


X = cos(t) and Y = sin(t) as we can consider the period of a sinewave in relation to the circumference of a circle.

With one revolution equal to 2Pi radians or 360 degrees, sin(t) will range from -1 to +1.

Plotted on an X-Y chart will produce a straight line with an angle of 45 degrees.

If the phase difference is 180 degrees than the straight line displayed will be at 135 degrees.


If we change the phase of one of the waveforms by 90 degrees.

X = sin(t + 90 degree (or 270 degrees)) and Y = sin(t), if (sin(t+90 degrees) = cos(t) then X = cos(t)

Plotted on an X-Y chart will produce a circle.


If we vary the frequency of one waveform with respect to a fixed reference frequency the resulting Lissajous figure will display multiple curves. Each curve related to the ratio of the varying frequency to the reference.

Twice the frequency will display 2 loops.

Lissajous Numbers

Lissajous_numbers.png

Knowing that different Lissajous figures can be created by varying the input frequency with respect to a reference frequency. Its only a small step to realizing these figures in terms of numbers if we represent the number by the number of lobes in a Lissajous figure. By lobes this being the area bounded by the two peaks vertically aligned either side of the X-axis.

The numbers to be represented will be decimal values from 0 to 9.

From there we can create all the numbers required to indicate the time in 24H format

Numeric Layout

lissajous_time.png

The numeric layout is somewhat dictated by components being used on this project.

This being the resolution and physical size of the display. (320 x 240 at 2 inches).

The screen is organised as 4 equal sized quadrants.

The top row represents the hours reading from left to right, tens then units.

The bottom row represents the minutes reading from left to right, tens then units.

The example shown displays the time as 16:32.

Front Panel Layout

The physical layout is arranged in the following manner.

1: Display Area

Shows the time as Lissajous figures.

Seconds are indicated by a line that increases in length from left to right horizontally.

The buttons on the display PCB are programmed to function enabling time setting only if the Mode switch is set, negating accidental setting.

A - Hours, X - Minutes and B - Set

However, due to the small size of the buttons, larger easier controls were fitted.

Additionally, the display is fitted behind a clear Acrylic screen for protection making the buttons inaccessible.

2: Sounder

Indicates hour intervals.

3; Controls

A simple mode selection switch which will enable or disable time adjustment.

A rotary encoder with colour mode indication, blue - adjust mode selected, green - time set.

Time is adjusted by rotating the knob forward or backwards changing minutes and hours through the 24 cycle.

A simple momentary push button that will program the time set when pressed.

Everything is mounted to the front panel to keep it compact.

Display Cutout

DSCF7090.JPG
DSCF7091.JPG
DSCF7093.JPG
DSCF7094.JPG

The front panel is 160mm (H) x 100mm (W) x 5mm (D).

A cut out is made for the display 55mm (W) x 35mm (H).

The top of the display cutout is located 15mm from the top of the panel and 22.5mm in from the edge.

Drill a series of holes within the perimeter of the display cutout area, each hole large enough to accomodate a small hack saw blade.

With thw saw cut out the section in the display area.

Level the sides of the cutout with a file.

Sounder Cutout

DSCF7092.JPG

The sounder is situated behind a circular grille.

The grile requires a hole with a 43mm cutout.

Measure 85mm down from the top of the panel and 50mm in from the edge.

At the position with a hole saw cut out a 43mm hole.

Controls Cutout

DSCF7108_2.png

Measure 25mm up from the bottom of the panel and mark a horizontal line.

At 25mm from the edge along this line mark the position and make a 8mm hole.

At 50mm from the edge along this line mark the position and make a 9mm hole.

At 75mm from the edge along this line mark the position and make a 9mm hole.

Countersink the hole from the front of the panel to enable the locking nut to sit flush below the level of the front surface.

Display Frame

DSCF7098_2.png
DSCF7103_2.png

Brass highlights are placed around the display to frame it.

A rectangular section of brass with dimensions of 70mm (W) x 50mm (H) is cut.

Into this rectangle is cut an opening of 55mm (W) x 35mm (H).

The opening is created by drilling holes large enough to enable a saw to fit.

Once most of the centre has been sawn out the remaining material is filed away.

By extending lines horizontally and vertically from the inner and outer boundaries to create a square in each corner.

In these corner squares, two diagonal lines drawn from opposite corners cross it identify the centre of the square at which point a 2mm hole is drilled. These holes will be used to attach the brass frame to the front panel.

Display Protection

DSCF7105_2.png

The display has a protective cover in the form of a 3mm Acrylic sheet.

This sheet is a rectangular section with dimensions of 70mm (W) x 50mm (H).

The brass frame is placed over the protective cover and the corner holes in the brass frame are used as alignment markers were 2mm holes are drilled.

Control Highlights

DSCF7095_2.png
DSCF7096_2.png
DSCF7104_2.png

The controls are backed by a brass plate.

The dimensions are 90mm (W) x 35mm (H).

The rectangle has the corners clipped, this is achieved by measuring both horizontally and vertically from the corner by 5mm.

Between these points a line is drawn and the brass is cut along this line.

By extending lines horizontally and vertically from the apex of opposite sides a cross offset from each corner is created.

At this crossing point 2mm holes are drilled to fix the plate to the front panel.

The panel has three holes which align with the holes in the panel for the controls.

Drill two 8mm holes and one 7mm hole for the control spindles.

These holes allow the control spindles to protude but mask the spindle fixing bolts.

Pico Support Board

DSCF7107_2.png

A support board is placed between the front panel and the Pico Dual Expander.

The support board is attached to the front panel at the rear by four M2 bolts.

Then the Dual Expander is clamped to the support board by 4 reverse mounted M2 bolts.

The Dual Expander board supports the Pico and includes two expansion connectors called Decks

Deck 1 - is used to connect all the control elements.

Deck 2 - is used to connect to the Display.

Due to the positioning and orientation of the Dual Expander and the requirement to access the connections whilst at the same time mounted to the back of the front panel the display cannot be plugged directly into Deck 2.

Therefore this is to be separately wired to the Deck 2 connections.

However, the connections on the Dual Expander Decks are pins whilst the display connections are sockets.

In order to connect the two together, interposer boards are required.

Interposer Boards

DSCF7125.JPG

The interposer boards are made from stripboard in addition to SIL pins and sockets.

The stripboard dimensions are 20 holes (rows) x 8 holes (columns).

One board connects to the pins on the Dual Expander using SIL sockets which are connected to the two outer 20 holes.

SIL pins are inserted facing in the opposite direction to the sockets to create two columns of 20 pins each with a gap between, the tracks in the gap are cut for isolation.

The other board connects to the pins on the display using SIL pins which are connected to the two outer 20 holes.

SIL pins are inserted facing in the opposite direction to the pins to create two columns of 20 pins each with a gap between, the tracks in the gap are cut for isolation.

The interposers are connected by socket to socket jumper wires.

Schematic

lissajous_clk_sch.png

The schematic shows the electrical elements and their connections.

Coding

The code is written in MicroPython v1.18 using Thonny 3.3.13

This application in it's current incarnation requires the Pico Lipo 4MB as a minimum.

Panel Assembly

DSCF7135_2.png

Place the brass display frame over the display protector and align with the corner holes.

Align with the corner holes on the panel.

Insert two M2 bolts in the lower corners of the display frame and protector combination and secure.

Place the display into the cavity at the back of the panel and secure with the flat clamp held in place by two M2 bolts in the upper two corners.

Fit the Pico support board in place and secure with four M2 bolts.

Plug the Pico into the Dual Expander in the centre DIL socket.

Place the Dual expander on the Pico support aligned such that the USB-C socket is pointing downwards.

Fit the two flat clamps over the Dual expander and secure to the M2 bolts.


Solder a 5 pin right angle SIL to the rotary encoder and fit 5 socket to socket jumpers.

Feed the jumper wires between the DIL socket under the Pico.

Push the rotary encoder through the central hole for the panel controls and secure in place.

Connect SDA to GP2, SCL to GP3, 3-5V to VS and GND to 0V.


Insert the rotary switch and the push button switch in to the remaining holes and secure in place.

Fit the brass plate over the control spindles and secure in place with four M2 bolts.


To the push button solder two, pin to socket jumpers.

Connect one pin to GP5 and the other pin to VS

To the rotary switch solder two, pin to socket jumpers.

Connect the NO pin to GP4 and the COM pin to VS.


Attach the RTC, SDA to GP0, SCL to GP1, 3-5V to VS and GND to 0V.

Be sure to fit a backup battery.


Connect the Interposer with the socket to Deck 2 of the Dual Expander.

Connect the interposer with the pins to the display.

Connect between the two interposers using 16 socket to socket jumpers as per the schematic.

Enclosure

DSCF7353.JPG
DSCF7340.JPG
DSCF7350.JPG
DSCF7351.JPG

The enclosure is made from a piece of decking plank which is cut to create two equal size pieces of 120mm(W) x 180mm(L) x 24mm(D). I wanted to create a block box but did not have a solid block and therefore used two pieces sandwiched together.

The cavity is 134mm(H) x 80mm(W) and the full depth of the sandwich.

The two pieces are held together with clamps during the cutting process.

The inner was removed by cutting into the perimeter of the dimensions using a oscillating multitool.

The decking plank has a distincly deep grooved pattern but wanting more smooth lines, this required sanding the front and back of the enclosure such that the groove depressions were less than 1mm from a maximum of 4mm.

Once the inner has been removed the pieces are permanently held in place by M4 bolts these are held by four inset nuts fitted at the back of the enclosure.

Drill four 5mm holes 17mm in from the edge at the back and 6mm above the top edge of the cutout and 6mm below the bottom edge of the cutout.

Provision is made for a transparent acrylic window on the back and this requires two 4mm insert nuts fitting at the back on the central line and midway between the enclosure fixings.

A cut out is filed below the bottom centre Allen bolt to accomodate the USB lead.


The top and bottom of the enclosure is capped with black Acrylic sheets, these are both 140mm(L) x 65mm(W) X 5mm(H).

The base plate has four 4mm holes drilled, two in the centre of each end of the two halves of the sandwich.

Along a centre line on each half of the sandwich 39mm in from each side two 4mm holes are drill.

This is then repeated on the other half of the sandwich.

25mm M4 self tapping screws are used to hold the base in place.

Four non slip stick on feet are attached at the corners of the base plate for stability.


The top plate has four 4mm holes drilled, two in each corner of each end of the two halves of the sandwich.

Along a centre line on each half of the sandwich 20mm in from each side two 4mm holes are drill.

This is then repeated on the other half of the sandwich.

These holes are used as a template to mark the top of the enclosure and using a 5mm drill bit make the hole to accomodate the M4 insert nuts.

Fit the insert nuts into the holes and tighten with a 4mm Allen key.

Along the longitudinal centre line of the top plate drill two holes to accomodate the handle and fit and secure with screws.

The top plate is held in place with four 25mm M4 bolts, screwed into the insert nuts.

Front Panel Fitting

DSCF7346_2.png

The front panel is fitted to the enclosure by four 50mm M4 bolts.

The holes in the front panel are marked by aligning it to the enclosure and marking through the 4 holes from the back.

Once marked use a 4mm drill to make the holes in the front panel.

Troubleshooting

Trouble shooting may be required should it not work as expected.

However, before switch on double check all the connections are sound and go to the correct points.

Some of the jumper connections may have come loose, if so reseat or replace.

It's even possible to remove the pin from the sleeve and with pliers compress the pin body to improve the contact pressure but do so with care as the body can be over compressed preventing the pin sliding in or staying on.

With regard to soldering dry or weak joints (dull, or crazed apprearance), may cause opens.

Check for shorts, due to solder bridging between tracks and metal slithers from cut tracks or track not cut.

Ensure componenets are correctly orientated.

Not an exhausive list but some general points for investigation.

Operation

Power is supplied via USB and the RTC has a battery backup in the event of loss of power.


Setting the time

The large black rotary switch is used to enable or disable time setting.

Turn the switch to the left to enable time setting.

The rotary encoder turns blue (indicating time setting mode).

Turn the rotary encoder to increase or decrease the time values until the desired time is displayed.

Press the white push button and the rotary encoder will turn green (indicating the time value has been set).

Turn the switch to the right to disable time setting.

The seconds are indicated by a horizontal line in the centre of the display that increases in length from 0 to full width (60 seconds), of the display, which clears and restarts each minute.

Finally

Another project to add to the collection.

Hope you found it informative.