Earthquake Simulation System with Pinoo

Purpose of the Project: To make a system that makes a sound from the buzzer by counting every ball entering the goal by using the Pinoo control card, tilt and impact sensor and buzzer module.

Duration: 2 lessons

Age Group: 7 years and over


• Learns to code Pinoo control card.

• Learns to use tilt and impact sensor.

• Learns to use buzzer.

• Improves the skill of setting up algorithms.

• Improves coding skill.


Materials to be used: Mblock 3 program, Pinoo control card, tilt and impact sensor, buzzer module, connection cables.



Materials Required for Design: Wooden boards, yellow mirror cardboard, red felt, silicone gun and silicone.





Project Preparation:


1. For our project, we first take our wooden sticks.



We connect our wooden plates with a silicon gun and we triangulate and glue our mirrored cardboard to give a roof appearance to the top.



We stick our red felt according to its size to give the back of our house a colorful look.



We fix our tilt and impact sensor and buzzer module on the roof of our house. We also place our Pinoo control card inside our house. After connecting with connection cables, we complete our design part.


 2.Adding Pinoo extension:

From the ‘’Extensions’’ tab, we click on the "Manage Extensions" option.

 In the window that opens, we type "Pinoo" into the search engine and simply say download to the result. It was installed on our computer.


3.Connecting the Pinoo sensor board to the computer:

In Mblock 3, we click on the "Connect" tab on the upper left.

We click on the "Serial Port" section from the window that opens and select the "COM6" option from the page that opens.


NOTE: Since the port entries of each computer are different, the numbers next to the COM text may change.

We click on the Cards tab.
We select the "Arduino Nano" card option used by the Pinoo sensor card from the window that opens.
We click on the ‘’Extensions’’ tab.
In the window that opens, we select the extension "Pinoo" of the sensor card we use.
We click on the ‘’Connect’’ tab.

We click on "Firmware Update" from the window that opens.


4. Coding part:


First, to check if our inclination and impact sensor is working, we place our tilt and impact sensor arrow code into our code under the code 'Clicking the Green Flag', so the values ​​we get are 0 and 1. (0 = slope or impact,

1 = slope or no blow)



When the green flag is clicked, we control our buzzer module by running it with a sound code under its code.



Hello, we read the slope and impact value with our code. Then, if the value we get is equal to 0, that is, if there is a slope or impact, my buzzer module will work for half a second and give us a warning.


We right click on the "Pinoo Program" command and select the "Upload to Arduino" option in the window that opens..



On the page that opens, we click the "Upload to Arduino" button selected in red.


Our codes are uploaded to our Pinoo sensor card. 

We click on the "Close" button after the "Download Finished" text appears. After the installation is finished, the battery compartment is inserted and the project is run.





5. Working Status of the Project:



When we shake our house, our buzzer module will beep and alert us.



int darbe_sensor = 2; // darbe sensorunu 2. pine atadık
int darbe_deger; // darbe deger adınnda değişken atadık

int buzzer = 3; // buzzerı 3. pine atadık

void setup() {
  pinMode(darbe_sensor, INPUT); // darbe sensoru giriş pinidir
  pinMode(buzzer, OUTPUT); // buzzer çıkış pinidir


void loop() {
  darbe_deger = digitalRead(darbe_sensor); // darbe sensorunden veri aldık

  if (darbe_deger == HIGH) { // eger darbe varsa
    // buzzer çalışır
    digitalWrite(buzzer, HIGH);
    digitalWrite(buzzer, LOW);
  } else { // aksi taktirde
    digitalWrite(buzzer, LOW); // buzzer susar