Ultrasonic Sensor Sweeper with Servo and Arduino Code

This guide uses the HC-SR04 Ultrasonic Distance Measuring Sensor mounted on a 9g type servo motor. The guide also features the servo and sensor bracket kit that is available to buy. Also, I include the Arduino code that will demonstrate the sensor sweep functionality. To follow this guide you can use any servo and sensor bracket you have to make use of the Arduino code below.

Continue reading “Ultrasonic Sensor Sweeper with Servo and Arduino Code”

28BYJ-48 Stepper Motor With Driver Code For Arduino

Here, we look at the 28BYJ-48 stepper motor with the ULN2003 driver. We get familiar with the specifications and the wire connections for driving the stepper motor from an Arduino microcontroller. Also, I include Arduino code to drive the 28BYJ-48 stepper motor without installing any additional libraries. Continue reading “28BYJ-48 Stepper Motor With Driver Code For Arduino”

Arduino Port Access & Bitwise Op. using Simple Robot Controller

In this article, we look at how to access an Arduino port to read or manipulate a group of pins in C code. We use bitwise operators to read, set and invert bits in variables and device registers. To help with this feature, we will use a simple robot controller to demonstrate how we might use port manipulation. I include, for example, Arduino test code and illustrations of bitwise operations. Continue reading “Arduino Port Access & Bitwise Op. using Simple Robot Controller”

Simulate Animated OLED/LCD Display On PC With PIL and OpenCV

Using PIL and OpenCV, this guide will show you how to simulate a small full-colour display attached to the Raspberry Pi on a PC. The virtual display will then allow you to create animated or interactive content initially on the PC. Then, with a little code modification, port the Python code to the Raspberry Pi. I also include example test code with this guide. Continue reading “Simulate Animated OLED/LCD Display On PC With PIL and OpenCV”

Using I2C Serial Bus to Connect Raspberry Pi to Arduino

At some point, I’ll be looking to extend my Raspberry Pi robot, and one of the ways to do that is to use I2C (Inter-Integrated Circuit) serial devices. So, in this feature, I look at how to access an Arduino board from the Raspberry Pi using this serial bus. I also include both Raspberry Pi and Arduino code to demonstrate the use of the serial interface. Continue reading “Using I2C Serial Bus to Connect Raspberry Pi to Arduino”

Create OLED or LCD Display Content with Pillow – Graphics and Fonts

Featuring the SSD1331 display and the Python Pillow library, I create and test content on the PC before porting to the Raspberry Pi with the attached OLED screen. Also, I include Truetype FreeFont and graphic images as part of the setup and demonstration.  Additionally, I include plenty of example Python code. Continue reading “Create OLED or LCD Display Content with Pillow – Graphics and Fonts”

OLED Display Library Setup for the Raspberry Pi featuring SSD1331

Thanks to an impressive Python library, we can connect various types of OLED displays to the Raspberry Pi such as the SSD1331 colour display. So to get this vivid, high-contrast 16-bit colour display up and running, I take a look at how to set up this library from  Luma.OLED. Additionally, I also show how to install and run the many examples available. Continue reading “OLED Display Library Setup for the Raspberry Pi featuring SSD1331”

Ultrasonic HC-SR04 Sensor Python Library for Raspberry Pi GPIO

This guide takes you through the steps to install and set up the new HC-SR04 distance measuring sensor Python Library. First, we connect the ultrasonic module to the Raspberry Pi GPIO pins. Then, we use pip to install the Python module. Followed by, a walkthrough of the ultrasonic Python module features. Continue reading “Ultrasonic HC-SR04 Sensor Python Library for Raspberry Pi GPIO”

Python and OpenCV Setup on Windows 10 with Geany Text Editor

Ideally, to save the Raspberry Pi SD Card, we can debug the bulk of the Python code on our much faster laptop or PC instead. Therefore I go through the install process of the Python programming language, and I also include installing OpenCV. Additionally, I recommend the Geany text editor which I recently discovered. Continue reading “Python and OpenCV Setup on Windows 10 with Geany Text Editor”

Build a Robot Battery Pack with Li-ion 18650 Cells

In this post, I will be creating a two-cell 18650 Li-ion battery pack to power my robot projects. I show a step by step build process following a brief description of the items I use. If you own a balance charger already, you may also want to use the battery pack box to balance charge pairs of cells for other use. Continue reading “Build a Robot Battery Pack with Li-ion 18650 Cells”