Example Code for Using the External 3Pin Actuator
Last revision 2026/01/06
This article offers a detailed guide on using an external 3Pin actuator with a UNIHIKER M10, providing step-by-step instructions for hardware and software setup, along with sample Python code for controlling a 9g 180° Micro Servo, enabling the servo to rotate between specified angles at regular intervals.
Hardware Preparation
Software Preparation
According to the Getting Started section in the UNIHIKER official documentation, it is recommended for beginners to operate according to the instructions in the Mind+ section. [Click to view]
The main process is: download and install MInd+ on your PC, open Mind+, switch to Python mode and Code page, click on the icon in front of Terminal, open the Connect Remote Terminal menu, and then connect the UNIHIKER. After that, you can create a new py file in the File System, write code and run.

Wiring Diagram

Sample Code
# -*- coding: UTF-8 -*-
# MindPlus
# Python
import time
from pinpong.board import Board,Pin,Servo
from pinpong.extension.unihiker import *
Board().begin()
servo1 = Servo(Pin((Pin.P3)))
while True:
print("90")
servo1.write_angle(90)
time.sleep(1)
print("10")
servo1.write_angle(10)
time.sleep(1)
print("170")
servo1.write_angle(170)
time.sleep(1)
Result
The servo rotates between 90, 10, and 170 at intervals of one second.

Was this article helpful?
