On the Subject of Samuel Says

“Samuel? Are you there? SAMUEL!”

This module houses a device with a large color display above four colored buttons, with a smaller display and a gray button to the right.

Samuel Finley Breese Morse has been trapped in this device and needs your help to escape! Fortunately, he is also the creator of the device and knows how to get out. Unfortunately however, his only means of communication is through colored morse. Your job is to transmit different colored symbols to help him disarm the module.

Good luck! Press the gray button to start. From now on, unless stated otherwise, the gray button will mute/unmute the device. Pressing the small display will toggle colorblind mode. The buttons are always red, yellow, green, blue, left-to-right.

Stages 1-4

In these first four stages, take Samuel’s transmitted messages and modify them to produce one colored symbol (per stage), which you then transmit back to him. Remember the colors of these symbols; you’ll need them for the final stage.

Sequence Modification

Each stage, go through the colors in the displayed sequence, in the flashed order, and go to the corresponding table below. Find the first true condition in the table and look at the corresponding action.

Actions must only be applied once per stage; if this action has not been applied yet, apply it to the modified sequence, which starts off identical to the displayed sequence. Otherwise, move up through the table, wrapping back to the bottom row if needed, until you reach an action that has not yet been applied, and apply it.

Red
ConditionAction
The displayed sequence is .-. (✲) Swap dots with dashes.
The color red has appeared in every displayed sequence so far. Make everything red.
The number of dashes in the modified sequence so far is equal to the number of indicators. Shift to the right by the number of lit indicators, and to the left by the number of unlit indicators.
There is a module on the bomb with “red” in the name, either as a word or as part of one. Swap red with blue, and green with yellow.
No other conditions applied. Replace the color and symbol in position one with those which are in position three. If the sequence is four symbols long, replace position two with position four in the same way.

✲ There are no periods in each table’s first condition. A dot is the same length as the short pause between symbols.

Yellow
ConditionAction
The displayed sequence is -.-- (✲) Reverse the sequence.
The stage number is equal to the number of batteries. If the current modified sequence is four symbols long, remove position N, where N is 4 minus (the number of batteries, modulo 4).
Otherwise, insert a yellow dash at position M, where M is the sum of the serial number digits, modulo 10, then modulo 3, plus one. (✲✲)
Simon Shouts or Simon Sends are present. Make positions one and two yellow.
The displayed sequence has more than one yellow. Change all but position three to blue.
No other conditions applied. Shift the colors to the right twice, keeping the symbols as they are.
Green
ConditionAction
The displayed sequence is --. (✲) Make all dashes green, then change dots to dashes.
Green is in position two in the displayed sequence. Change the colors to red, blue, yellow, green, but stop early if you run out of symbols to change.
This condition has not yet been true. Change position one to green, and the rest to red.
The number of dots in the modified sequence so far is the same as the number of unique port types. Move all dots to the start of the sequence, keeping the colors as they are.
No other conditions applied. Remove position two and append a green dot.
Blue
ConditionAction
The displayed sequence is -... (✲) Reverse the symbols, keeping colors as they are.
There has been a blue in position three at any point during the modification process this stage, including in the displayed sequence. Shift everything to the right by one.
The displayed sequence does not form a valid morse letter. (✲✲✲) Take the sum of the serial number digits, modulo 26, add one, and convert the result into a letter (A1Z26). Find the first letter in the alphabet, starting from this letter and wrapping back to A from Z if needed, whose morse representation matches the length of the modified sequence. Set the sequence to this representation. (✲✲)
Every color appears at least once across the displayed sequence and current modified sequence. Leave the sequence as is.
No other conditions applied. Change the first two positions to blue, and the rest to red.

✲ There are no periods in each table’s first condition. A dot is the same length as the short pause between symbols.
✲✲ To modulo a number Y by a number X is to repeatedly add or subtract X from Y until the result is between 0 and (X-1), inclusive. ✲✲✲ See Appendix-MORSE-NATO for more information.

Determining Position

The correct position to submit is X, modulo(✲✲) the length of the modified sequence, plus one, where the value of X depends on the current stage:

  • In stage 1, X is the number of batteries.
  • In stage 2, X is the number of ports.
  • In stage 3, X is the number of indicators.
  • In stage 4, X is the number of modules on the bomb.

✲✲ To modulo a number Y by a number X is to repeatedly add or subtract X from Y until the result is between 0 and (X-1), inclusive.

Submission

To submit a colored symbol, press the button of the relevant color. To submit a dash, hold the button until the small display on the right shows a ; to submit a dot, release the button before this happens.

If the submission is correct, Samuel will accept the response and attempt to transmit a new sequence. However, the device is riddled with oddities, so a quirk may show up after each stage. Read the next subsection for more information.

If the submission is incorrect, Samuel will not accept the response, and the module will strike. The displayed sequence and correct response will remain the same.

Quirks

If a quirk appears after a correct submission, Samuel will exhibit some visual indicator of the quirk. Respond in the correct way to nullify the quirk and move on to the next stage. Remember which quirks show up, as you’ll need them for the final stage.

An incorrect response will cause a strike and reset input.

QuirkVisual IndicatorCorrect Response
Ghost A sequence of buttons is pressed by a ghost in the machine. Press the buttons in the same order as the ghost. If you have started to input a sequence, pressing the gray button will clear the sequence.
Stutter Each symbol flashes multiple times before moving to the next. Press the button with the color that flashes the most. If more than one color flashes the most, press a button with any such color.
QuirkVisual IndicatorCorrect Response
Unstable One position in the displayed sequence alternates between being a dot and being a dash. Press the button whose position, in reading order, matches that of the ‘unstable’ symbol in the sequence.
Overclocked There is no pause between repeats of the sequence. Repeatedly press the colored buttons until Samuel calms down. Stop once all the buttons light up.
Virus Every button becomes purple and the display does not flash. Press buttons according to the number of regular submissions so far:
Number of SubmissionsSequence (Reading Order)
11234
23412
32413
Discolored The small screen lights up to show a color. Press buttons with colors according to the color of the display:
Color of Display Sequence
Red Red Red Yellow Green
Yellow Green Green Blue Blue
Green Red Yellow Blue Green
Cyan Blue Yellow Yellow Green
Blue Green Blue Blue Red
Magenta Red Blue Red Blue
Stuck One of the buttons is pushed in. Touch the stuck button when the last seconds digit of the timer is N, where N is the number of solved modules, modulo 10. (✲✲)

✲✲ To modulo a number Y by a number X is to repeatedly add or subtract X from Y until the result is between 0 and (X-1), inclusive.

Stage 5

After four correct submissions, Samuel needs an entire word to be transmitted, so he can use it to finally escape the device and disarm the module. Note that, visually, there is no difference between this stage and the previous four.

Determining the Word

Take only the symbols in the displayed sequence, ignoring the colors. If this sequence does not form a valid morse letter, the correct word is SAMUEL.

Otherwise, modify the sequence based on the quirk(s) that appeared earlier:

  • If no quirks appeared, leave the sequence as is.
  • If only one quirk appeared, remove the first position.
  • If only two quirks appeared, and they were different, shift the sequence to the right by two.
  • If only two of the same quirk appeared, reverse the sequence.
  • If three different quirks appeared, remove the first three positions.
  • If three quirks appeared, and only two were the same, remove the third position.
  • If three of the same quirk appeared, remove the first two positions.

If the sequence is now empty, or does not form a valid morse letter, use MORSE as the word.

Otherwise, convert the sequence into a letter and take this letter’s spelling in the NATO Phonetic Alphabet to use as the word. (✲✲✲)

✲✲✲ See Appendix-MORSE-NATO for more information.

Submission

Convert the entire word into morse code, without any breaks between letters. Input these symbols into the module, using the color submitted in stage 1 for the first symbol, the color submitted in stage 2 for the second symbol, and so on. Wrap back around to stage 1 upon running out of stages.

For example, if the final word is QUEBEC, and the colors submitted in the previous stages were red, green, blue, blue, the correct response for this stage would be

--.- ..- . -... . -.-.
RGBB RGB B RGBB R GBBR

(note that the spaces are only for clarity, and should be ignored during input).

After submitting each complete letter, Samuel will display the letter on the small screen to confirm he has received it.

Correctly submitting the entire word will release Samuel from his prison and solve the module.

Upon submitting an incorrect symbol, the module will strike and the buttons will flash the expected color order one time. Input will be reset but the displayed sequence and answer will not change.

Appendix-MORSE-NATO

LetterPositionNATO SpellingMorse Respresentation
A1ALFA.-
B2BRAVO-...
C3CHARLIE-.-.
D4DELTA-..
E5ECHO.
F6FOXTROT..-.
G7GOLF--.
H8HOTEL....
I9INDIA..
J10JULIETT.---
K11KILO-.-
L12LIMA.-..
M13MIKE--
N14NOVEMBER-.
O15OSCAR---
P16PAPA.--.
Q17QUEBEC--.-
R18ROMEO.-.
S19SIERRA...
T20TANGO-
U21UNIFORM..-
V22VICTOR...-
W23WHISKEY.--
X24XRAY-..-
Y25YANKEE-.--
Z26ZULU--..