Conveyor System With Pinoo
Purpose of the Project: To create a conveyor system with distance sensor, servo motor and dc motor using the Pinoo control card.
Materials Required for Design: Cardboard, colored cardboard, forex, scissors, silicon gun, paint, any material you want to decorate
- Cut a rectangular piece of 30x10 cm from forex.
- We mark and drill the areas where we will fix the motor in the right and left areas of the rectangle. (Let's forget to drill a hole in the motor cable.)
- We cut a 65 x 9 cm rectangular strip from the cardboard. The cut strip will be the belt of the conveyor. (The measurement we give here is based on the distance of the motors to each other. You can create a different size according to your own layout.)
- We glue the two ends of the strip together and pass through the tires.
- Cut a piece of forex measuring 7.5 x 6.5 cm. We open a distance sensor-sized window in the middle and place the sensor.
- We create a wall around the part that we fixed the sensor. We cut a 13 x 6 cm rectangle from forex to ensure the height of the band and fix it under the part where the sensor is.
- We fix the distance sensor stand we created to the motor wall.
- We fix the servo motor distance sensor 10 cm away from the place where we fixed it. You can change these dimensions according to your own location.
- We form 4x4 and 2x2 cm cubes from cardboard. These cubes will be our products.
- We decorate the conveyor as we wish.
- Let's make our connections. We fix our Pinoo board behind the motor wall. We connect the motor cable to the white inputs suitable for the motor, the distance sensor to the purple / green input number 6, and the servo motor to the 1 (purple) input with a connection cable.
- We have completed our connections, now let's move on to the coding part. We will use the mblock-3 application for this.
- Let's connect our Pinoo control card to the computer with the help of a connection cable and enter the Mblock3 application. Then let's introduce our Pinoo control card to the computer. To do this, we first click on the serial port option from the Connect tab. Then we select COM3. (The number may differ according to the computer and the port.)
- After making the serial port connection, let's select the card we will use from the Cards tab. We are working with Arduino Nano model.
- In order to add the Pinoo extension to our computer, we click on the Manage Extensions option from the Extensions tab. In the window that opens, we type "Pinoo" in the search engine and click download to the result. It has been installed on our computer.
- We come to the Extensions tab again and click on the Pinoo option. We will write our codes with the Pinoo extension.
- In the coding part; To start the application, we get the code when clicking the green flag from the Events menu.
- After clicking the green flag, we want the conveyor belt to run continuously. For this, we take the ‘’Pinoo Bot: Direction: Forward Speed: 0’’ code block from the Robots tab and change the Speed section to 150.
- In order to run the band and all other operations that we will add later, we take the code block from the Control tab continuously and insert the block related to the Pinoo Bot.
- At the beginning, we need to set the angle of the servo motor as 0 in order to allow the small products to move without obstacles along the belt. From the Robots tab, we get the ‘’Pinoo Servo Motor Run: Pin Pinoo1 Pain 0’’ code block.
- We will use the values measured by the distance sensor in order to separate the large products on the belt. We will get help from the dummy to learn the value read by the distance sensor. For this, we get the hello command from the View tab. Instead of the word ‘’Hello’’, we take the code block for the distance sensor in the Robots tab. We change the PIN input to Pinoo6 that we connect.
- Let's click on the green flag and move our hand closer to the sensor and observe the change of the values. Then, let's place the bigger box under the sensor and take note of the value read by the sensor. We will reference that it reads a value of around 6 here.
- If the condition is met, we want the servo motor to make a 70 degree angle. From the Robots tab, we get the ‘’Pinoo Servo Motor Run: Pin Pinoo1 Pain 0’’ code block. We change the angle value to 75.
- After the servo motor angle value is 75, we receive the wait 1 second command from the Control tab so that the motor can stay in this position for 2 seconds. We change the 1 second expression to 2 seconds.
- We place our condition statement inside the continuous repeat block.
- Right click on the code and click on Upload to Arduino. (We work with Arduino as a board.)
- We are waiting for the codes to be uploaded to the card. After the installation is complete, we close the window.
- If there is no problem, we disconnect our power cable from the computer. We power our Pinoo control board with the help of a 9v battery and a battery cap. We also turn on the on / off button next to the battery input.