Forum | Documentation | Website | Blog

Skip to content
Snippets Groups Projects
himanshuk.rst 25.04 KiB

Librobotcontrol support for newer boards

Introduction

Introducing librobotcontrol package support with newer boards.

Summary links

Status

This project is currently just a proposal.

Proposal

Completed all the requirements listed on the ideas page

About

Project

Project name: librobotcontrol support for newer boards .

Description

Librobotcontrol is package of C library which contains examples and testing programs for Robotic control projects used by robotic cape which is sold by beagleboard.org, BeaglBboneBlack(BBB) supports the librobotcontrol thanks to Deepak khatri who Previouly worked upon cape compatibility layer on BBB. robotic cape with BBB support the librobotcontrol packages. BeaglBboneBlack support robotic-cape cape with librobotcontrol package due to creation of device tree ovelayes which identify the robotics cape and symlink help to address the location of specific peripherals in data structure. as below is example for accesing GPIO's for blink robotics cape LED's. since robotic-cape has connected one of LED on pin no P8_3

Main goal of project is to update librobotcontrol package for beaglebone-AI(am5x), beaglebone-AI64(j721e) and beaeglV-fire(olarV-soc) boards. Primarily librobotcontrol support all the boards but not able to make roboitic cape as flexible as BBB board.

BeagleBone-AI support librobotcontrol package but its been draft. and there is not a stable overlays for robotic cape in AI image. So for using package, have to check the passed results for various drivers and use cape with AI. BeagleBone AI is based on the Texas Instruments AM5729 dual-core Cortex-A15 SoC with flexible BeagleBone Black header and mechanical compatibility. which supports the am5x device tree binary files. this .dtb file will include in binary file (.dts) files in AI which will help to call root nodes to creat device tree for cape. but as AI-support the cape, there is only need to cross verify the package and update accordingly.

BeagleBone-AI64

BeagleBone AI-64 uses TI J721E-family TDA4VM system-on-chip (SoC) which is part of the K3 Multicore SoC architecture. Each TI evm has an unique device tree binary file required by the kernel. As BeaglBboneBlack need (ti,am335x) similarly beaglebone-AI64 support (ti,j721e) device tree binary (.dtb). BeagleBone AI-64 also support librobotcontrol packages but there are less tutorial and not refine code for support librobotcontrol package with new boards. Need to refine the device trees overlays to use this librobotcontrol package with AI-64. As in librobotcontrol there is no robotic cape dtb support for beaglebone-AI64 we need to write the device tree ovelay with (ti,j721e) binary file (.dtb).

How it will be possible, see an example for blink LEDs via device tree ovelay which is for GPIO's. .. code

     &{/chosen} {
    overlays {
            BONE-LED_P8_03 = __TIMESTAMP__;
        };
};

&bone_led_P8_03 {
status = "okay";
// access: sys/class/leds/led_P8_03
label = "led_P8_03";
linux,default-trigger = "heartbeat";
default-state = "on";
};

Implementation of device tree

BeagleV-Fire

BeagleV®-Fire is a revolutionary SBC powered by the Microchip’s PolarFire® MPFS025T RISC-V System on Chip (SoC) with FPGA fabric. It has the same P8 & P9 cape header pins as BeagleBone Black allowing to stack BeagleBone cape on top to expand it’s capability. Built around the powerful and energy-efficient RISC-V instruction set architecture (ISA) along with its versatile FPGA fabric. BeagleV-Fire also support the robotic cape with librobotcontrol package and cape gateware for robotic cape is preinstalled in V-fire image here . but as BBB support the librobotcontrol with more functionality and flexible application, beagleV-fire is not capable for librobotcontrol package due to less number of device_tree fragment present in robotic-cape (.dts) file which is pre-installed in V-fire image. With help of customization for cape gateware in V-fire which Provide more flexibility to board with cape, librobotcontrol package will support V-fire with robotic cape.

In robotics_cape.dts file in cape gateware of beagleV-fire are used PWM and GPIO's, we need to write device tree sript for I2C, SPI and UART and also add simlink which will need to support librobotcontrol package.

Previous work:-

Previously Deepak khatri who worked upon the cape compatibility for beagleboards. use the robotic cape for various tasks. using pre-work upon robotic cape, i can take a deep dive to robotic cape compatibility with BeaglBboneBlack (BBB) and how its works. In previous gsocted with one of Bea-2022 participation kai yamada work upon same project which was about robotic-cape support with BeagleBone-AI (BB-AI). In both projects implementation was about the device tree overlayes for BBB and AI for specific pheripherals to enabling functionality of PWM, I2C and SPI and UART for robotic capes.

Software

  • Device tree's overlays for beagleboards will be used.The project requires the use of the device tree compiler (dtc) for compiling the device tree source (ex. *.dts, *.dtsi) files.
  • Primarily VScode and gitlab with web-IDE is use in this project for deep dive into code and firmware of librobotcontrol and rc (robot control library) examples.
  • C language.

Hardware

A list of hardware that you are going to use for this project.

Timeline

Timeline summary

Date Activity
February 26 Connect with possible mentors and request review on first draft
March 4 Complete prerequisites, verify value to community and request review on second draft
March 11 Finalized timeline and request review on final draft
March 21 Submit application
May 1 Start bonding <bonding>
May 27 Start coding and introductory video
June 3 Release introductory video and complete milestone #1<milestone1>`
June 10 Complete milestone #2
June 17 Complete milestone #3
June 24 Complete milestone #4
July 1 Complete milestone #5
July 8 Submit midterm evaluations
July 15 Complete milestone #6
July 22 Complete milestone #7
July 29 Complete milestone #8
August 5 Complete milestone #9
August 12 Complete milestone #10
August 19 Submit final project video, submit final work to GSoC site and complete final mentor evaluation

Timeline detailed

Community Bonding Period (May 1st - May 26th)

  • Get to know with community, Read resources for librobotcontrol and beagleboards, get up to speed to begin working on the projects.
  • At current period of time, all the required hardware will be available.
  • Setup all the beagleboard hardware (Flashing OS and test hello world).
  • Check all hardware with beagleboard like DC motors, Servo motors and available sensors.
  • Use robotic cape with beagleboard BeaglBboneBlack (BBB) and librobotcontrol.
  • Use robotic-cape with BeagleBone-AI.

Coding begins (May 27th)

  • Understand device tree overlays for BeaglBboneBlack (BBB) and AI written for robotic cape.
  • Start to write Device tree for GPIO's and PWM.

Milestone #1, Introductory YouTube video (June 3rd)

  • Include introductory video.
  • Prepare documentation for the process.

Milestone #2 (June 10th)

  • For RoboticsCape, Test a device tree overlay to allow AI-64 to light the power LEDs with GPIO support.
  • Test PWM devic tree overlay with robotics cape with help of Hardware specification and check with oscilloscope.
  • Get feeback from mentors.

Milestone #3 (June 17th)

  • Write I2C device tree for AI-64.
  • Test I2C with IMU and robotic cape.
  • Get feedback from mentor.

Milestone #4 (June 24th)

  • Creat merge request for I2C Device tree overlays.
  • Write SPI device tree overlay for AI-64.
  • Test with robotic cape.
  • get feedback from mentor.

Milestone #5 (July 1st)

  • Creat RoboticsCape.dts file for robotic cape which will support AI-64 using pre-work.
  • Test .dts file with robotic cape with AI-64.
  • Test example of librobotcontrol with AI-64.
  • get feedback from mentor.
  • Creat merge request for RoboticsCape.dts.

Submit midterm evaluations (July 8th)

Important

July 12 - 18:00 UTC: Midterm evaluation deadline (standard coding period)

Milestone #6 (July 15th)

  • Test RoboticsCape with cape gateware for beagleV-fire.
  • Understand the customization process for cape Gateware.

Milestone #7 (July 22nd)

  • Customized LED example for robotic-cape gateware.
  • Test GPIO's, Robotic cape with beaeglV-fire.
  • Creat merge request for LED blink with beaeglV-fire.

Milestone #8 (July 29th)

  • Examine SPI support for beagleV-fire with robotic-cape.
  • Create I2C device tree to test barometer on robotic cape.
  • Creat merge request for I2C support.
  • Discuss results and features with mentor.

Milestone #9 (Aug 5th)

  • Test all pre-work for librobotcontrol and robotic-cape with beaeglV-fire.
  • Upgrade robotic_cape.dts file gateware for beaeglV-fire using pre-work.
  • Creat Documentation and feeback from mentors.

Milestone #10 (Aug 12th)

  • Finalize the work on robotic-cape.dts for beaeglV-fire and test example of librobotcontrol.
  • Creat documentation for current process.
  • Fixing other bugs, typos, etc. found during documentation.

Final YouTube video (Aug 19th)

  • Submit final project video, submit final work to GSoC site

and complete final mentor evaluation.

Final Submission (Aug 24nd)

Important

August 19 - 26 - 18:00 UTC: Final week: GSoC contributors submit their final work product and their final mentor evaluation (standard coding period)

August 26 - September 2 - 18:00 UTC: Mentors submit final GSoC contributor evaluations (standard coding period)

Initial results (September 3)

Important

September 3 - November 4: GSoC contributors with extended timelines continue coding

November 4 - 18:00 UTC: Final date for all GSoC contributors to submit their final work product and final evaluation

November 11 - 18:00 UTC: Final date for mentors to submit evaluations for GSoC contributor projects with extended deadline

Experience and approch

Experience:
  • I’m well experienced with embedded system and C. I’ve in-hand experienced with embedded programming and hardware design for various boards and projects.
  • Here are my projects which demonstrate my proficiency in Embedded system and Robotics.
  1. Martian rover used in IRC (International rover challenge )

    Martian rover is a prototype of curosity the nasa mars rover which performed function like soil testing, sample collection and monitoring planet. project required embedded hardware and firmware design for motor control and sensors configuration with ROS.

  2. STM32 custom board

    STM32 was custom boad which is made in purpose to learn embedded programming and hardware design. it's a open source development project.

  3. Vaayu – AQI and various concentration calculation for gases present in air

    VAAYU is air quality monitoring system device which calibrate the different gases concentration and display with a GUI and TFT-display.

  4. TVC rocketry – Thrust vector control

    TVC rocketry is learning based model project about Thrust vector control rockets, which based on PID implementation and sensors configuration.

    More projects done by me can be found on my github.

  • I’ve designed various double and four layer board for clients and projects using Kicad , Eagle and Altium designer (Designs). And this shows that I’ve very good understanding for reading schematics and Circuit design for embedded development, which is required for This project.

Approach:

In my experience, projects often demand a comprehensive understanding of both software and hardware components Before changing the main packages, Hardware setup and debug will required more time than software. This involves meticulous reading of documentation and references, demanding patience and focus. I believe that this content can be completed without any problems.

Contingency

What will you do if you get stuck on your project and your mentor isn’t around?

Unexpected software and hardware problems are most common in any projects. In such cases,

  1. In the event of encountering compatibility issues between BeagleBoard and librobotcontrol, I'll to use the BeagleBone Black (BBB) platform for testing purposes, as BBB offers native support for the librobotcontrol package.
  2. If there is any hardware related issue to board,first ill review the datasheets and manule of hardware and if there is any issue related to circuitry I’ll use oscilloscope, multimeter and other testing devices for debugging.
  3. If the problem is about SOC, I’ll check the datasheets of perticular SOC.
  4. Here are a few references you can quickly glance at during debugging for guidance.

Benefit

If successfully completed, what will its impact be on the BeagleBoard.org community? Include quotes from BeagleBoard.org. community members who can be found on our Discord and BeagleBoard.org forum.

  • Librobotcontrol packages will support the beaglebone-AI, beaglebone-AI 64 and BeagleV-fire.
  • Various tutorials, Documentation will be added to the Robotic Capes to help the user understand how to use it using llibrobotcotrol packages.

Misc

Please complete the requirements listed in the General Requirements . Provide link to merge request.

  • All prerequisite tasks have been completed.
  • Source dive for Librobotcontrol packages and read all the documentation for packages
  • Check hardware specification, setup and device trees for BBB.
  • Here the 'Hello world' task Pull request : merge request

Suggestions