Annual: 2019

AP062 »
Bionic Leg
📁Machine Learning
👤Vivek Jangir S
 (CMR University, Bengaluru, Karnataka, India)
📅Oct 08, 2019
Regional Final



👀 2591   💬 2

AP062 » Bionic Leg

Description

Bionic Leg is a technological healthcare solution to tackle physical disability. The solution uses any one of the approachs i.e., ML or adaptive control systems. Real time response & adaptability to changes are considered to be the significant aspects/features of any healthcare solution which can be addressed by the FPGA.

Demo Video

  • URL: https://youtu.be/TmudYorPS1M

  • Project Proposal

    1. High-level Project Description

    Introduction

    Purpose:

    In order to reduce the cost and provide best performance and adaptability to the prosthetic legs, we collect data from physically abled humans and optimize the data to understand how the knee and ankle joints behave with respect to the hip joint. We take readings from the hip joint to predict the motion of the knee and the ankle joint to create a dataset that is used to make the leg predict what the user wants to do. This unlocks the capability of bionic leg to understand what the person is trying to do and learn newer movements. This dataset can be created for different tasks including walking, climbing stairs etc. We hope to use the FPGA’s speed to make our bionic leg respond in real time.

     

    Application Scope:

    Classical designs used to make disabled to walk through prosthetic leg have limited movements that the prosthetic leg can perform. The approach of using sensors to read signals from muscles cannot be applied where the leg is amputated from the thigh region,where the lower muscles are not available.

    Previous research shows the use of reading signals from muscles and brain to control the prosthetic leg. These methods requires use of complicated hardware which directly increases the cost and not making these prosthetic legs available for everyone.

    Our team proposed the idea of the use of reading the angles from the joints using potentiometers. The behaviour of the knee joint and ankle joint is studied with respect to the hip joint. This makes the leg able to perform the basic tasks in day to day life. This method uses low cost hardware and providing the best performance. We aim to make our prosthetic leg available to everyone at affordable prices and best performance.

     

    Applications:

    We are committed to make the physically disabled walk without any additional support. Our approach, which uses the well refined collected data using kalman filter adaptive noise smooting and arima model, helps it to learn any activity while the speed of FPGA enables quicker response time.

    Our Prototype Looks like:

     

    Target Users:

    The product is designed to enable physically disabled people to walk  and perform other daily activities such as climbing stairs, sitting, standing etc. We target people who have one leg amputated from their thigh region.

     

    Implementation

    Approach:        HIP ANGLE: Angle between the body axis and the thigh bone 

                        KNEE ANGLE:Angle between the body axis and the shin.

                       ANKLE ANGLE: Angle between the shin and the foot. 

    Input: Hip angle which is taken by moving the thigh bone with respect to the body axis.Hence the thigh bone must be moved by the user as shown in the video to change the position of the shin and foot respectively.

    Output: Knee angle and ankle angle

    We collected data for the hip, knee and the ankle joint for a walk cycle for a normal person in proper conditions. Then the behaviour and functioning of the knee and the ankle joint is studied with respect to the hip joint is understood and mapped. This data is refined and generalized, this generalized data is stored in our program. As our bionic leg moves it stores it previous moments in the history element. our bionic leg reads the angle from the hip and basedd on that the control logic then selects multiple data points from the data, further the control logis uses the history to select one data point fromt the rest. based on this data point the control logic moves the motors to move the knee and ankle joints to their respective positions. hence, executing the complete walk.

     

     

     

    Github Link:

    https://github.com/muralisvishnu/BionicLeg

    2. Block Diagram

     

    System Architecture

    3. Intel FPGA Virtues in Your Project

    1. Low Latency: Low latency is what you need if you are programming the autopilot of a jet fighter or a high-frequency algorithmic trading engine: the time between an input and its response as short as possible. This is where FPGAs are much better than CPUs (or GPUs, which have to communicate via the CPU).With an FPGA it is feasible to get a latency around or below 1 microsecond.For this real time response for in a walk cycle we need low latency fpgas to complete the walk cycle curve as smooth as possible.
    2. Connectivity: On an FPGA, you can hook up any data source, such as a network interface or sensor, directly to the pins of the chip. This in sharp contrast to GPUs and CPUs, where you have to connect your source via the standardized buses (such as USB or Uart) — and depend on the operating system to deliver the data to your application. A direct connection to the pins of the chip gives very high bandwidth (as well as low latency).

    3. Boosts performance: FPGA's speed help in boosting the performance by committing faster computations, thereby enabling real time response.

    4. Adaptability to changes: FPGAs are adaptable for changing workloads & multiple use cases dynamically with data processing (even with different types of data) across a variety of applications like climbing stairs, running, walking, sitting, standing, etc…

    5. Energy efficient system by the custom hardware for the depth estimation using an FPGA. ASICs are an even more energy efficient solution but require a very large upfront investment for the design and large number of chips produced to be cost effective. But back to FPGAs.

    6. Expands IO: Motors with many potentiometers were controlled by the fpga for the feedback and the movement of the joints. The fpga also sent serial input values to the neighbour computer for simulating  the movement of the leg. Hence, the fpga has a lot of scope for the number of input output devices that can be connected and used.for the project.

    4. Design Introduction

    Our project consists of two parts.

    The data was collected from the normal, healthy human beings using the potentiometers to measure the angles, hip angle, knee angle and the ankle angle, where hip angle is the angle between the thigh and the axis of the body.The knee angle is the angle between the shin and the axis of the body while the ankle angle is the angle between the foot and the shin.  

    With respect to the hip angle, the angles of the knee and the ankle are computed, for this, the dataset of a single walk cycle was computed using different trial and error methods to collect data and the noise was reduced using filters and smoothing techniques for example kalman filters and adaptive noise smoothing filters.. An arima model was Implemented to simulate the dataset according to the refined dataset created from walk cycles to give a lot of dataset and to put it into a model predictive control model to get the well refined data for getting an array of hip, ankle and knee angles for 100 data points which constitute a single walk cycle of a leg. The data was generalised using arima model so that the referenced data of the hip, knee and ankle is generalized over all kind of people.

    HIP ANGLE: Angle between the body axis and the thigh bone 

    KNEE ANGLE:Angle between the body axis and the shin.

    ANKLE ANGLE: Angle between the shin and the foot. 

    Input: Hip angle which is taken by moving the thigh bone with respect to the body axis.Hence the thigh bone must be moved by the user as shown in the video to change the position of the shin and foot respectively.

    Output: Knee angle and ankle angle

    Hardware Design Requirements:

    Sl.No.

    Component

    Description

    01

    Potentiometers

    To read the angle of joints.

    02

    OpenVINO Starter Kit (FPGA)

    To do the computations in real time.

    03

    Motors

    Used in the bionic leg for motion.

    04

    Frame

    For the legs to collect data and one frame for the bionic leg.

    05

    Batteries

    Power Source

    *Part 2 is explained under functional description as it includes aspects of fuctioning.

    5. Function Description

    HIP ANGLE: Angle between the body axis and the thigh bone 

    KNEE ANGLE:Angle between the body axis and the shin.

    ANKLE ANGLE: Angle between the shin and the foot. 

    Input: Hip angle which is taken by moving the thigh bone with respect to the body axis.Hence the thigh bone must be moved by the user as shown in the video to change the position of the shin and foot respectively.

    Output: Knee angle and ankle angle

    The dataset for the project was collected using potentiometers which calculate angles of the hip and the knee and the ankle.The data collected had a lot of noise which was reduced using kalman filters and the curves were smoothened using adaptive nooise smoothener.Data was generalised using arima which helped in increasing the variance of the dataset.

    The main function has hip, knee and ankle angles in an array of 100 datapoints which maps to each other. A history array has 5elements which memorises the last 5 elements of the hip angles which uses dynamic programming techniques to map to the ankle and knee angles using hip angle and its index on the array so that we can compute partition in which  the knee angle and ankle angle is present.

     Using the data points for the task of walking we write an algorithm that understands the behaviour and change of the hip to predict a set of data points that the leg might have to follow. For the given hip angle, the ankle and knee angles are predicted using the data collected and the final posture of the leg is determined. To reach the final outcome, the leg also stores its history i.e it stored its previous data or path that it followed. This history data is then used to get the final data point from the list of data points collected by processing the dataset. Once the data point is found, the knee and ankle angle data is read and applied to the motors. Each joint consists of potentiometers for feedback to make the leg precise.

    The algorithm has a well refined generalised data which it maps with each other to compute the output making it faster and variable to different people and their walk. Since the walk cycle can be generalised for all kinds of people using hence our dataset can be used to give a power efficient algorithm for the purpose.For any given input state the control logic generates output based on the data and the history element updating history in every cycle, feedback is used to precisely control the motors.

    6. Performance Parameters

    The output received from the bionic leg (i.e. the knee angle and the ankle angle for the corresponding hip angle) was tested and an animation(simulation) was made to show you how the walk cycle would be in the real world using the outputs from the bionic leg. The comparison study of the time series model of the hip angle, knee angle and the ankle angle was made between well esteemed resource and the time series model we obtained from the cleaned data we collected and implemented in our project and the results were very similar and the proofs are as follows:

    Joint Angle Resource Graph we Obtained

    Hip 

     

     

     

     

     

     

     

     

    Knee    

     

     

     

     

     

     

     

    Ankle     

     

     

     

     

     

     

     

    Walk Cycle Simulation was done on screen which changed according to the movement of the leg where the coloured leg traced the movement of the bionic leg real time.

    7. Design Architecture

    System Design Architecture

     

    OpenVINO FPGA

    Family : Cyclone V

    Devic  : 5CGXFC9D6F27C7

    Total registers : 2424

    Total pins  : 101

    Total virtual pins : 0

    Total block memory bits : 8,477,504

    Total DSP Blocks : 3

    Total HSSI RX PCSs : 0

    Total HSSI PMA RX Deserializers : 0

    Total HSSI TX PCSs : 0

    Total HSSI PMA TX Serializers : 0

    Total PLLs : 1

    Total DLLs : 0

    We used Intel's Quartus prime and platform designer development tools to develope a qsys system which contains the nios ii processor, this system consists of the following components: clk_50,PLL_sys,NIOS2_qsys,onchip_memory,sysid_qsys,adc_itc2308,PIO(motors),Uart(rs-232).

    The whole system operates on a 50MHz clock rate, faster version of the nios 2 processor is used. adc_itc2308 is used to get the input from the potentiometers and PIO controllers are used to control the motors.

     

    System Contents

    References

    1. Mathematical Modeling of Human Walking on the Basis of Optimization of Controlled Processes in Biodynamical Systems. Journal of Mathematical Sciences. V. E. Berbyuk, B. A. Lytvyn. May 2001, Volume 104, Issue 5, pp 1575–1586.

    2. Joint structure and function by Cynthia C. Norkin, Pamela K. Levangie.



    2 Comments

    Luis Aljure
    Very nice project Vivek you could help many people. Keep going. Good luck!!
    🕒 Jul 06, 2019 12:33 PM
    AP062🗸
    Thank you
    🕒 Oct 07, 2019 05:17 AM

    Please login to post a comment.