Many individuals with mobility impairments who rely on motorized wheelchairs for independent movement encounter discomfort and back pain, especially when navigating uneven and bumpy terrains. Paul (on the discord page), for instance, notes that while he primarily uses his wheelchair on sidewalks that are generally in reasonable condition, the typical road or sidewalk is not as flat as someone walking might assume. He emphasizes the need for innovation in wheelchair suspension, suggesting that even well-designed wheelchairs struggle with uneven surfaces. Drew shares a similar sentiment (on the discord page), highlighting that his "off-road" power chair, equipped with larger motors and tires, still faces challenges with 2" lips and bumps. He prefers riding in the street due to its smoother surface compared to sidewalks, which often have noticeable bumps between sections. These user opinions underscore the nuanced nature of the issue, indicating that even seemingly smooth surfaces can pose challenges, necessitating a solution that goes beyond conventional wheelchair design.
SolutionTo address the challenges faced by users of motorized wheelchairs, our solution introduces a smart speed control mechanism. This innovative system utilizes advanced sensor technologies, including an Inertial Measurement Unit (IMU) for terrain detection and ultrasonic sensors for obstacle avoidance. At the core of the system is the Swan MCU, serving as the central control unit. A simple button controller provides an intuitive interface for effortless navigation, enabling users to select from three speed settings: slow, medium, and fast. A proactive warning system alerts users to uneven pathways, enabling them to make informed decisions about their route. This holistic approach not only minimizes discomfort and back pain but also enhances user safety, promoting a more confident and comfortable mobility experience for individuals with disabilities.
How It WorksThe system operates by continuously monitoring the wheelchair's surroundings through integrated sensors. The IMU sensor detects variations in terrain, signaling the Swan MCU to autonomously adjust the wheelchair's speed based on the detected road conditions. Ultrasonic sensors contribute to obstacle detection, preventing collisions and enhancing overall safety. The simple button controller provides users with a direct and easy-to-use interface for controlling the wheelchair's speed. Additionally, a proactive warning system utilizes real-time data to alert users to bumpy roads ahead, empowering them to choose smoother paths. This integrated and user-centric approach revolutionizes the motorized wheelchair experience, offering a solution that prioritizes comfort, safety, and ease of use for individuals with mobility impairments.
Step by Steps1. Setup Swan using Arduino IDE2. Testing MPU6050 Sensor3. Testing DC Motor and DRV88334. Creating PCB using EAGLE5. Create a motorized wheelchair prototype using SolidWorks6. Assembly and Programming Wheelchair (+partial test)7. Battery Test using StepDown Converter8. Collecting Data9. Creating Machine Learning Model10. Model Implementation on The Device11. Testing The Device
1. Setup Swan using Arduino IDESwan is a budget-friendly microcontroller based on STM32L4, designed to speed up the creation and use of battery-powered IoT solutions. It's great for projects needing ample memory and expandability without breaking the bank, like edge inferencing and remote monitoring. Swan is Feather-compatible, making it versatile for early testing or large-scale projects. Developers can pair Swan with Adafruit's sensors and FeatherWing-compatible carriers. For cost-effective deployment, Swan can be soldered directly to a parent PCB, utilizing its full I/O capabilities. Swan offers three power options β USB, battery, or line power β and has a software-switchable 2 Amp regulator for external sensor power. In low-power mode, Swan draws only 8uA while keeping all its memory, perfect for battery-operated devices. It supports C/C++, Arduino, and CircuitPython, and includes a CORTEX Debug connector for advanced development in Visual Studio Code, IAR, and STM32CubeIDE.
To begin utilizing the Swan board with Arduino IDE, the first step is to prepare and install the necessary drivers. Start by adding the following URL to the Additional Boards URL in Preferences:
https://github.com/stm32duino/BoardManagerFiles/raw/main/package_stmicroelectronics_index.json
Once this is done, navigate to Tools > Board, choose "STM32 Boards groups, " and then select "Blues Wireless boards." Afterward, under Tools > Board Part Number, opt for "Swan R5."
For programming the Swan without using the STLink-V3Mini, go to Tools > Upload method, and choose "STM32CubeProgrammer (DFU)." Connect the Swan to your computer via a USB cable, plugging it into the Micro USB port. To enter the bootloader mode on the Swan, press and hold the BOOT button, press and release RESET, and then release BOOT. It's crucial to follow this sequence every time firmware needs to be uploaded to the Swan.
With these preparations complete, proceed to the next step by following the instructions to Blink the Onboard LED. This ensures that the Swan board is ready for further development and testing with the Arduino IDE.
2. Testing MPU6050 SensorThe MPU6050 is a popular inertial measurement unit (IMU) that combines a gyroscope and accelerometer in a single integrated circuit. Developed by InvenSense (now part of TDK), the MPU6050 is widely used in electronic projects, robotics, and motion sensing applications. The gyroscope measures angular velocity, providing information about the rate of rotation in three dimensions, while the accelerometer measures acceleration in those same three dimensions. By combining data from both sensors, the MPU6050 can provide accurate information about the device's orientation and motion. The sensor is known for its compact size, low power consumption, and reliable performance. It communicates with microcontrollers through I2C (Inter-Integrated Circuit) or other communication protocols, making it easy to integrate into various electronic systems for tasks such as orientation tracking, gesture recognition, and stabilization in applications like drones or motion-controlled devices. Overall, the MPU6050 is a versatile and widely adopted sensor for projects requiring precise motion sensing capabilities.
To access data from the MPU6050 sensor, we can utilize the I2C pins on the Swan board. Connect the sensor to the Swan following the provided configuration. Next, download the library for the sensor from the following link. Insert it into the Arduino IDE by clicking on Sketch > Include Library > Add.ZIP Library, and select the downloaded file. Then, open the provided example. We will attempt to upload the MPU6050_accel_simple.ino. Before uploading the file, make sure to follow the instructions outlined in step 1. Once the upload is complete, we will obtain results as shown in the image below. This process allows for seamless integration and utilization of data from the MPU6050 sensor in your Swan-based projects, providing valuable information on orientation and motion for various applications.
The DRV8833 is a motor driver integrated circuit designed for controlling the speed and direction of two brushed DC motors. Manufactured by Texas Instruments, the DRV8833 is a dual H-bridge motor driver that can drive two motors bidirectionally or one stepper motor. It operates efficiently with a wide range of input voltages, making it suitable for various applications. The device incorporates protection features such as overcurrent protection and thermal shutdown, ensuring the durability and safety of connected motors. Its compact design and versatility make the DRV8833 an ideal choice for robotics, mechatronics, and other projects requiring precise motor control.
#define AIN1 5
#define AIN2 6
#define BIN1 9
#define BIN2 10
void setup() {
Serial.begin(9600);
pinMode(AIN1,OUTPUT);
pinMode(AIN2,OUTPUT);
pinMode(BIN1,OUTPUT);
pinMode(BIN2,OUTPUT);
}
void loop() {
digitalWrite(AIN1,HIGH);
digitalWrite(AIN2,LOW);
digitalWrite(BIN1,HIGH);
digitalWrite(BIN2,LOW);
delay(1000);
digitalWrite(AIN1,LOW);
digitalWrite(AIN2,LOW);
digitalWrite(BIN1,LOW);
digitalWrite(BIN2,LOW);
delay(1000);
digitalWrite(AIN1,LOW);
digitalWrite(AIN2,HIGH);
digitalWrite(BIN1,LOW);
digitalWrite(BIN2,HIGH);
delay(1000);
digitalWrite(AIN1,LOW);
digitalWrite(AIN2,LOW);
digitalWrite(BIN1,LOW);
digitalWrite(BIN2,LOW);
delay(1000);
}
In this project, the DRV8833 will be utilized to control the forward, backward, left, and right movements of the prototype wheelchair's DC motors. The provided circuit illustrates the correct connections between Swan (presumably a microcontroller or control system) and the DRV8833 module. The wiring should be done accordingly for proper functionality. To implement this motor control, the code should be uploaded to Swan. The code is designed to coordinate the simultaneous control of two DC motors. Initially, the motors rotate in a clockwise direction, followed by a 1-second pause. Subsequently, they rotate in a counter-clockwise direction, with another 1-second pause. This cycle repeats to facilitate the intended movements of the wheelchair prototype.
In this project, the decision to create a printed circuit board (PCB) serves two primary purposes: simplification and aesthetic enhancement. By utilizing a PCB, the number of cables used will be reduced, leading to a more streamlined and organized setup. Additionally, the incorporation of a PCB adds an aesthetic appeal to the project. The design process of the PCB will be carried out using the Eagle application. The PCB's main function will be to establish connections between Swan Boards, the DRV8833 driver module, and the MPU-6050 sensor.
The initial step involves creating a schematic design of the components to be used. Due to the absence of a library containing Swan's schematic and board designs, a common pin header is used to create the necessary pads. PCB dots can be employed as a helpful tool for this purpose. By calculating the desired length and width, users can manually create them within the Eagle application. Despite this workaround, it's important to note that the conceptual integrity remains intact.
Several inputs and outputs are designated for use on the PCB. Four output pins are allocated for DC motors, while input pins include a power supply pin connected to the entire circuit and an input for a remote control. Notably, due to the limitation of available pins, analog input pins are repurposed for the remote control input. While this may seem unconventional, the underlying concept remains unchanged.
Once the schematic design process is complete, the subsequent step involves generating the board file. During this phase, components are arranged meticulously to form a shield-like structure. Tracks or pathways are then created, connecting one component to another. The resulting board layout can be observed in the accompanying image below, showcasing the organized and interconnected components of the PCB.
To create this motorized wheelchair, we will start by making a prototype for the sake of simplicity and efficiency. The prototype will be crafted using the SolidWorks application for the 3D modeling process, and subsequently, it will be laser-cut from acrylic sheets. The prototyping process will be done part by part, ensuring attention to detail for each component. The prototype aims to closely resemble the actual motorized wheelchair, albeit with slight adjustments to accommodate the use of a DC motor for propulsion. At the bottom of the user's seat, a storage slot will be incorporated to house components such as the microcontroller, driver, sensors, and the battery. Additionally, the front part will feature two swivel wheels, allowing the user greater flexibility in adjusting the wheelchair's direction of movement.
Following the creation of individual parts, the next step involves generating an assembly file that integrates all the components. Assembly files serve to provide a holistic view of the entire tool once all the individual parts are combined. This process is essential for verifying that the size and alignment of each section are accurate when assembled into a single unit. The merging process is facilitated using the mates feature, which allows for the precise attachment of one part to another. This ensures that the assembled motorized wheelchair functions seamlessly as a unified whole, taking into account the correct positioning and interaction of each part for optimal performance.
6. Assembly and Programming Wheelchair (+partial test)We have completed all the steps in the creation of this project. In this section, we will combine the acrylic pieces that were cut in the previous step into a single unit for the prototype of this electric wheelchair. The acrylic pieces are joined using a glue gun. The assembly of the prototype is straightforward because it has been thoroughly evaluated in the previous section to avoid errors.
Next, the PCB will be installed on this SmoothRide prototype. The PCB consists of two parts. The first part includes Swan Boards, MPU-6050 Sensor, and DRV 8833 Driver. The second PCB contains push buttons that will be used to control the direction of motor movement. Additionally, there is a stepdown converter that will connect the main board to the battery. All these components will be mounted on the bottom part of the motor, as shown in the above picture. Once all the components are in place, the first test will be conducted to ensure that the prototype device operates as intended. The testing involves forward, backward, right turn, and left turn maneuvers. The test results can be seen in the video below.
7. Battery Test using StepDown ConverterNext, testing will be conducted on the battery. The use of the battery is essential to closely resemble a real motorized wheelchair. The selected battery is a 12V output lithium-polymer (LiPo) battery. In this section, we will utilize a StepDown module to reduce the battery voltage to 5V. The output voltage from the StepDown module will be connected to the VIN and GND pins of the Swan Boards. It can be observed that the LED lights will illuminate upon connecting the battery to the StepDown module.
Once all components are prepared, encompassing both the circuit connections and the data reading procedures, the subsequent step involves the data collection process. In this project, data collection is facilitated through a data forwarder directed towards Edge Impulse.
For guidance on the necessary installations, please refer to the following links (1) (2). The installation requires several applications:
- Node.js version 12 or higher
- Arduino IDE
- Edge Impulse CLI, installable through the command prompt or terminal with the command (for Windows):
npm install -g edge-impulse-cli
Several considerations should be taken into account during the installation:
- Ensure the installation of additional tools when installing NodeJS (not selected by default).
- The Arduino IDE version must be a minimum of 1.15. Further details can be found on this link.
Once all the applications are successfully installed, the subsequent procedure involves incorporating a program for the Serial monitor. This program will be utilized to transmit data through a data forwarder.
The subsequent step involves launching the Edge Impulse CLI through the Node.js command prompt using the following command:
edge-impulse-data-forwarder
Proceed to log in with the Edge Impulse account, select the port associated with Swan Boards, choose the relevant project on Edge Impulse, and assign distinctive names to each data feature. With these configurations, the device is now prepared to initiate data collection. Verification of the device's connection to Edge Impulse can be confirmed.
In this particular project, the classification task entails categorizing data into two distinct classes. The first class pertains to roads in good condition, denoting minimal damage. Data collection for this class is conducted on even surfaces, such as well-maintained cemented roads without significant holes or irregularities. The second class focuses on damaged roads, specifically those characterized by rough and uneven terrain. These conditions pose potential risks for electric wheelchair users, potentially causing prolonged back pain. Data for this class is collected from asphalt or standard roads with uneven surfaces.
The initial step in constructing a machine learning model involves Impulse Design. This phase commences by generating an impulse designated for utilization. Users are required to choose both the processing block and learning block to be employed in this stage.
The project utilizes raw data to be further processed to generate classifications for the bumpy and normal classes. It is observed that in the bumpy class, the graph exhibits more undulations compared to the normal class. Subsequently, we can generate features using the features provided by Edge Impulse.
It is evident from the analysis that the outcomes of the classification process are notably promising and effective. The system has demonstrated a commendable level of accuracy in distinguishing between different classes. This robust performance is indicative of the system's proficiency in accurately categorizing data into distinct classifications.
The final step involves integrating the model we've created into Swan Boards. Edge Impulse is equipped with features to seamlessly convert machine learning models for diverse devices and programming languages. Within the Deployment tab, you can choose the specific type of device or programming language you intend to use. Following that, all you need to do is patiently wait for the process to conclude, after which you can effortlessly download the finalized model.
What's fascinating is its usage mirrors that of the standard Arduino library, making it directly importable into Arduino by clicking on Sketch > Include Library > Add.ZIP Library. Subsequently, you can promptly incorporate it into your project.
10. Testing The DevicePlease watch the video.
ClosingSmoothRide represents a form of innovation that I can create for people with disabilities. Even though it is still in the form of the first prototype of a motorized wheelchair, I hope to inspire the birth of many practical and impactful creations. Moving forward, I plan not only to keep this project as a prototype but also to materialize it in reality. There are several improvements that I intend to make in the future:
1. Simplification of the Controller. I aim to simplify the controller, considering that the use of cables may not be the most optimal solution. Another option could be Bluetooth, but I am contemplating what would happen if the device encounters an error. Should the wheelchair user be stuck in one place unable to move? I welcome suggestions if you have a better idea.
2. Integration of GPS for Safety. I want to add GPS capability to send the wheelchair user's location to their guardian. This feature would provide immediate assistance in case of any unforeseen events. This idea is possible because there are Blues Wireless products, especially the Notecarrier F, which can accommodate Swan GPS and Notecard simultaneously. I'm a bit puzzled about combining the devices provided by the "Apply for Hardware" section in this contest, so I believe this is the most feasible step for me to take in the future.
3. Creation of a Real Motorized Wheelchair. This endeavor requires substantial resources and a combination of various fields of expertise to make it not just a project but genuinely beneficial to others. Numerous aspects need attention, starting from constructing a framework that is genuinely secure, ergonomic design, selecting suitable materials, choosing the right motor and driver, comfortable suspension, and many more. I believe collaboration and, of course, sponsorship (please πππππ) might be essential for this ambitious undertaking.
SEE YOU ON THE NEXT PROJECT! :)
Comments