There are six different blocks:
- Hours, numbers 1 to 4 ( Dutch: een twee drie vier)
- Hours, numbers 5 to 8 ( Dutch: vijf zes zeven acht)
- Hours, numbers 9 to 12 ( Dutch: negen tien elf twaalf)
- Hour or Half-hour (Dutch: uur half)
- Before or After (Dutch: voor over)
- 5-minutes, 10-minutes, quarter (Dutch: vijf, tien, kwart)
The red arrows shows some places where there are holes in the bricks. The forklift has two infrared LEDs and two detectors to check presence of the holes (at both sides of the brick). Only the lower hole can be detected, the upper hole is used for the other side of the brick.
In the close-up you see the forklift with its infrared detection system:
(The resistors have only a mechanical function, they guide and hold the block to the correct position on the fork.)
When a block is in the lift, it provides a two-bit code with its holes. Only 3 combinations are used for most blocks. The code were both holes are open is used to detect that no block is present on the fork.
The two-bit code can be different for the four sides of the block.
The holes encode the identity of each block (after all sides are examined), and also encode the reference position for each block. With the correct software, the clock will always know which block it handles and which side is shown at the front. Here is the used code:
char word_code[]= { 0, 2, 0, 0, 0, // brick 1 2 3 4 1, 0, 2, 0, // brick 5 6 7 8 0, 1, 0, 0, // brick 9 10 11 12 1, 0, 0, 2, // kwart tien vijf blank4 1, 2, 0, 0, // over2 voor over voor2 3, 0, 0, 0, // half blank6 uur blank6a 3, 3, 3, 3 };// empty position
The final picture shows the strip that has holes to encode the vertical position of the lift.
For each row on the rack, there are two holes:
- One for moving just above the storage positions, when a brick must be placed,
- One for moving just below the storage positions, when the brick has been placed and the fork must move back.
- You can also see the infrared detector. The infrared LED is at the other side of the strip.
Discussions
Become a Hackaday.io Member
Create an account to leave a comment. Already have an account? Log In.