I had a challenge at work with my team involving u-boot, and we noticed that it was somewhat difficult to find clear and concise information on how to work with this bootloader. So we decided to gather many sources and our hard-gained knowledge and write down a practical U-Boot tutorial that we hope will help other developers getting started with it.
In this document you will learn about the following topics and more:
- Setting up a U-Boot development environment with ECLIPSE,
- Setting-up QEMU to execute projects without a having a target HW platform;
- U-Boot Structure (directory hierarchy, configuration options, compiling U-Boot image);
- U-Boot customization (U-Boot drivers, U-Boot commands, U-Boot driver calls);
- Running U-Boot am335x target on QEMU;
- Installing qemu-linaro;
- Creating a Bootable microSD Card;
- Running U-Boot am335x target on hardware;
- Integrating standalone applications;
- Exporting U-Boot functions for standalone applications.
We used the BeagleBone Green board as HW target.
The document can be downloaded from:
Practical Aspects in U-Boot Programming
Feel free to provide any feedback or fix suggestions. Enjoy.
Tuesday, October 3, 2017
Sunday, January 16, 2011
KaT: a simple way to have software projects organized
I like to maintain software projects backed up and organized in my local computer. Well, who doesn't? Anyway, i have my own way of doing it and the less intrusive in my workflow, the better.
I like to have a repository folder with a sub-folder for every project. These sub-folders keep zip backups of all the project files at important development stages and also a nice version tracker text file containing a description for all versions i submit.
Lately i got tired of adding the zips by hand, editing the version tracker file, creating folders and files for the new projecs... and decided to do a simple software application to do this work for me. It is called KaT (KeepAndTrack). I added a project page on sourceForge for it, thinking that maybe other people could find it handy, here's the link:
KaT Project Page
It is open-source, so the source is included (yay!). Don't expect much of the GUI, i'm a low-level programmer and doing GUI's is not my specialty. Anyway, i tried to avoid the boring and unfriendly command line interaction by replacing it with nice text input boxes and icons.
Labels:
developers,
keepandtrack,
software,
version control
Monday, November 22, 2010
MATLAB autocode generation from simulink models and integration in RTEMS
I have added a modest contribution to the RTEMS Wiki regarding autocode generation from Simulink models using Real-Time Workbench and consequent integration in RTEMS OS. This software can be then targeted for embedded soft-processor architectures such as the LEON-3. Here's the link to the page:
RTEMS: MATLABCodeGeneration
The overall objective is to be able to integrate simulink models in Real-Time Testbenches involving components such as dSPACE systems, Processor and/or Hardware in the Loop.
RTEMS: MATLABCodeGeneration
The overall objective is to be able to integrate simulink models in Real-Time Testbenches involving components such as dSPACE systems, Processor and/or Hardware in the Loop.
Labels:
Autocode Generation,
MATLAB,
Real-Time,
Real-Time Workshop
Friday, August 27, 2010
Using PLB PCIe bridge core with microblaze
Do you want to exchange data between your Xilinx board and your PC via PCI express interface?
So.. Having trouble configuring the Xilinx PCIe bridge core on your microblaze (or powerpc) embedded architecture? Assuming your Xilinx board is the endpoint: the board is not being detected on your windows pc? Does using 1 lane (x1) design in a 8 lane (x8) PCI express header board strange to you?
All these and more are answered here:
Configuring Xilinx PCIe Bridge core
For the PCI bridge core (not PCI express), to be used with a standard PCI header endpoint Xilinx board, the configuration is more tricky. However, the address translation principles are the same.
Best,
JM
So.. Having trouble configuring the Xilinx PCIe bridge core on your microblaze (or powerpc) embedded architecture? Assuming your Xilinx board is the endpoint: the board is not being detected on your windows pc? Does using 1 lane (x1) design in a 8 lane (x8) PCI express header board strange to you?
All these and more are answered here:
Configuring Xilinx PCIe Bridge core
For the PCI bridge core (not PCI express), to be used with a standard PCI header endpoint Xilinx board, the configuration is more tricky. However, the address translation principles are the same.
Best,
JM
Labels:
microblaze,
PCI express,
PLB PCIe Bridge core,
Xilinx
Wednesday, May 12, 2010
For loop with SPARC assembly
For those who don't want to waste to many time searching on how to do a simple for loop in asm to be processed by, say, a LEON, here's your answer.
The next code does the following:
- Initialize registers
- Iteratively shift left one bit in a register
- add one LSbit to the shifted register
- loop while i less than 10
References:
SPARC Assembly Language Summary, Princeton University
SPARC Assembly/Control Structures, Wikibooks
Monday, March 22, 2010
Implementing a Linux RTAI Based Real-Time Motion Controller for Differential Mobile Robots
In my M.Sc. Thesis I implemented a real-time motion controller for differential mobile robots, generic enough to be implemented in any differential mobile robotic platform.
It was a very enthusiastic project. I had the chance to learn about several topics and implement an intelligent RTAI based control system running on a very small embedded linux distribution. The system is installed on a 128MB Compact Flash and flushed into the PC104 RAM at boot time. Then, a Spartan3 FPGA implemented the PWM generator signals that drive the motors based on the outputs given by the controller running on the PC104.
This system sends packets through TCP/IP to a visualizer module running on another PC for validation of the controller accuracy, given the target trajectory of the robot.
Among the publications i made regarding this subject, i want to share the most extensive one which will hopefully be of use to you. It is a book chapter recently published on the book CONTEMPORARY ROBOTICS - Challenges and Solutions entitled Generic Real-Time Motion Controller for Differential Mobile Robots. Here's the link to the full article:
Generic Real-Time Motion Controller for Differential Mobile Robots Chapter
In simple terms, the control system allows the robot to autonomously reach one or multiple target 2D (x,y) position point(s) based velocity vectors. The user simply has to set the desired positions for the robot to reach, or send velocity value/angle values for it to run with the desired velocity in a desired direction. It also implements an obstacle overcome algorithm to allow the robot to climb small deffects (ramps) on the flor that can block its way.
Best,
JM
It was a very enthusiastic project. I had the chance to learn about several topics and implement an intelligent RTAI based control system running on a very small embedded linux distribution. The system is installed on a 128MB Compact Flash and flushed into the PC104 RAM at boot time. Then, a Spartan3 FPGA implemented the PWM generator signals that drive the motors based on the outputs given by the controller running on the PC104.
This system sends packets through TCP/IP to a visualizer module running on another PC for validation of the controller accuracy, given the target trajectory of the robot.
Among the publications i made regarding this subject, i want to share the most extensive one which will hopefully be of use to you. It is a book chapter recently published on the book CONTEMPORARY ROBOTICS - Challenges and Solutions entitled Generic Real-Time Motion Controller for Differential Mobile Robots. Here's the link to the full article:
Generic Real-Time Motion Controller for Differential Mobile Robots Chapter
In simple terms, the control system allows the robot to autonomously reach one or multiple target 2D (x,y) position point(s) based velocity vectors. The user simply has to set the desired positions for the robot to reach, or send velocity value/angle values for it to run with the desired velocity in a desired direction. It also implements an obstacle overcome algorithm to allow the robot to climb small deffects (ramps) on the flor that can block its way.
Best,
JM
Labels:
differential robots,
digital control,
Real-Time,
RTAI
Friday, January 15, 2010
Auto-Completion problem in Eclipse while programming in C/C++ solved
Eclipse supports auto-completion for both typedef structs and structs without type definition declarations, in contrary to the information that might be found on the web.
To have Auto-completion for structs using "->" or "." just do the following using the Eclipse IDE:
1) Window -> Preferences -> C/C++ -> Editor -> Content Assistant
2) Mark all except "Present proposals in alphabetic order" if not necessary.
3) All the headers you create with struct declarations must be known by the IDE. Therefore all the folders containing the headers must be added to the project:
3.1) Project -> Properties -> C/C++ General -> Paths and Symbols
3.2) In the "Includes" Separator, add all the folders containing the headers (except the root folder of the project). This is, if you have the following folder structure
/root
- /Headers
- reference.h
- /FunctionDeclarations
- main.c
the folder "Headers/" must be added with the "Add" option in the Paths and Symbols.
Simple as that.
To have Auto-completion for structs using "->" or "." just do the following using the Eclipse IDE:
1) Window -> Preferences -> C/C++ -> Editor -> Content Assistant
2) Mark all except "Present proposals in alphabetic order" if not necessary.
3) All the headers you create with struct declarations must be known by the IDE. Therefore all the folders containing the headers must be added to the project:
3.1) Project -> Properties -> C/C++ General -> Paths and Symbols
3.2) In the "Includes" Separator, add all the folders containing the headers (except the root folder of the project). This is, if you have the following folder structure
/root
- /Headers
- reference.h
- /FunctionDeclarations
- main.c
the folder "Headers/" must be added with the "Add" option in the Paths and Symbols.
Simple as that.
Subscribe to:
Posts (Atom)