MODI + many 2x1 Lego blocks, long 4x20 bottom block(one or two), two wheels, and some addition Lego blocks.
1. Input - Ultrasonis module; Ultrasonic sensor is used for measuring how far the object is placed in front of it and expected application is the digital height meter, water level checker and proximity detector which is installed most of car to avoid any collision.
2. Process - Read the distance from Ultrasonic sensor and amke a series of conditional "if" to generate a sound( Do, Re Mi, Pa...) according to the distance reading.
3. Output - Speaker module; Play the sound of Do, Re Mi.. according to the distance of sensing object and work like a music box.
This project a quit simple but show the typical concept of what is the input for the system and what is the output of it. To make a different distance object as a input, 2x1 lego block would be located in a row and Ultrasonic module read each distances on the two wheel rover and play the sound using Speaker Module.
Original plan to play the sound of music box on "Mr. Sunshine" but the Ultrasonic sensor's reading was not so accurate as expected.