top of page

Medicine chest

Purpose of the Project: To make a system that gives warnings during drug hours and automatically opens the cover of the relevant drug by using Pinoo Control Card, servo motor, buzzer module and LCD display module.

Duration:  2 lessons

Pinoo Set:  Full Set, Maker Set

Age group:  7 years and older

Achievements:

  • Learns to code Pinoo control board.

  • Learns to use LCD screen.

  • Learns to use the buzzer module.

  • Learns to use servo motor.

  • Develops algorithmic skills.

  • Coding skills develop.

 

 

Materials to be used:  Mblock 3 program, pinoo control card, servo motor, buzzer module, LCD display module, connection cables.

 

 


Materials Required for Design:  3D printouts, caulking gun and caulk.

 

 

 

Project Construction:

 

For our project, we will first integrate our servo motor.

 

 

 

 

 

 

 

 

 

 

 

 

 


We fix our servo motor to the body of our medicine box, which we designed, with a silicone gun.

 

 

Then, after adjusting the angle of our drug servo motor, we fix the cover and the servo motor brush with the help of a silicone gun.

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 


Then, we fix our LCD screen module and our ramp, where we will place our buzzer module, to each other with the medicine box.

 

 

We fix our LCD screen module to our ramp with a silicone gun as in the picture.

 

 

After fixing our buzzer module to the bottom of our LCD display module, we make the pinoo control card connections. We connect our LCD display module to port 10, our buzzer module to port number 2 and our servo motor to port number 1. This is how we finish our design part.

 

Adding Pinoo extension:

 

 

 

 

 

From the Extensions tab, click "Manage Extensions". In the window that opens, we write “Pinoo” in the search engine and it is enough to say download to the result. Installed on our computer.

 

Connecting the Pinoo control board to the computer:

 

 

 

 

In Mblock 3, we click on the "Connect" tab in the upper left. In the window that opens, we click on the "Serial Port" section and select the "COM6" option from the page that opens.

NOTE: As each computer has different port entries, the numbers next to COM may change.

 

Click on the Cards tab. From the window that opens, we select the "Arduino Nano" card option used by the pinoo control card.

 

 

 

Click on the Extensions tab. In the window that opens, we select "Pinoo", the extension of the control card we use.

 

 

 

 

Click on the Connect tab. Click "Firmware Update" from the window that opens.

 

Coding part:

 

 

 

 

 

First, we place our lcd screen identification code under the 'Pinoo Program' code to check whether our lcd screen module is working. Then we place our 'Pinoo LCD Print' code and say upload it to the arduino. After the download is finished, 'Hello World!' We see the text. In this way, we check the working status of our LCD screen.

 

 

 

We check our Buzzer module by running the code below with the code that makes a sound when the green flag is clicked.

 

 

To keep our time data, we create a variable from the Data&Block section and call our variable 'sure'.

 

 

 

At the beginning of our codes, we set our duration variable to 0. Then we introduce our LCD display module. Then, at the beginning of the program, we added our write code to write the text 'Medicine Box' on our LCD screen module and changed the column part to 3 so that it would write in the middle of our screen. We made this article stay on the screen for 5 seconds.

 

 

Then we had our duration variable incremented by 1 continuously.

 

 

 

We are checking our duration variable using the if condition block. If our duration variable is equal to 10, we delete the texts written on our LCD screen module. Then we print the text 'Time.08:00' and give a warning for 1 second with our buzzer module and deactivate our buzzer module. After it became inactive, we waited 1 second for the codes we created to work properly, and we cleaned our screen again and waited for 1 second again. Here, our aim for 1 second is to make our text '08:00' flash. We continue our coding by adding our code to write the text we want to flash. After adding the code for our '08:00' text, we add our buzzer sound code because we want it to give an audible warning again. In fact, we add the same code that we added to our if block above because we want it to repeat on the bottom.

 

 

 

'Take medicine number 1'. Since we cannot fit the text on a single line, we print the word 'take it' on the screen with the command to write on the 2nd line. Again with the buzzer module, we give a sound warning and add the angle code to our servo motor so that the lid of the medicine box is at the 1st place and we wait for 5 seconds, we clean our screen. We print the text 'Medicine Box' on our screen until the next medicine hour.

 

(FULL CODE PAGE)

 

  (ZOOMIZED PART 1)

 

 

 

(ZOOMED VERSION PART 2)

 

 

(ZOOMIZED PART 3)

 

We add our other if block to warn at the other hour. If our duration variable is equal to 20 (we made it to see the duration values here in a short time, different values can be entered.) We added our code. 1. There are 3 differences from our codes in your block. First, we changed the text 'Time.08:00' to 'Time.13:00'. Secondly, we changed the text 'take medicine number 1' to 'take medicine number 2'. Third, we changed our servo motor angle to 100 degrees.

 

 

 

In the same way, if our duration variable is equal to 30, we code the condition block for the evening medicine of the day. There are 4 differences this time from other condition blocks. We change the 3 changes in the same way. Our 4th change is to reset our time changer because the day is over. In this way, we have finished our coding.

 

 

 

Right-click on the “Pinoo Program” command and select the “Install to Arduino” option in the window that opens.

 

 

 


On the page that opens, we click on the "Upload to Arduino" button, which is selected in red. Our codes are uploaded to our pinoo control card. After the “Installation Finished” message comes, click the “Close” button. After the installation is finished, the battery holder is inserted and the project is run.

 

 

Working Status of the Project:

 

 

 

With the application we have made, we have created a system that will alert us to take the necessary drugs when the time comes, and which can return to that compartment for whichever drug needs to be taken.

IMG_4395.JPEG
IMG_4394.JPEG
IMG_4396.JPEG
IMG_4397.JPEG
IMG_4398.JPEG
IMG_4399.JPEG
IMG_4400.JPEG
pinoo_uzanti_480x480.jpg
1_a8314da2-edff-4525-979d-b2d3ff93364b_large.png
seri_port_480x480.jpg
KART_480x480.jpg
pinooo_480x480 (2).jpg
aygit_yazilim_480x480.jpg
2.JPG
3.jpg
4.jpg
1.JPG
5.JPG
7.JPG
8.JPG
9.JPG
10.JPG
11.JPG
2_cfd94931-534e-40ab-93cc-2817fc0a5c62_480x480.jpg
3_c171a551-90ad-458a-9dce-acfc3919c525_480x480.jpg
12_72dcae95-73a7-4c3e-a43b-fac4aa5f539b_480x480.jpg
13.jpg
14.jpg
IMG_4403.JPEG
bottom of page