SlideShare uma empresa Scribd logo
1 de 29
Baixar para ler offline
Embedded Linux BSP
Training (Intro)
Organised by YoctoTutor & supported by
RuggedBOARD
Agenda
• Introduction to EMBEDDED LINUX
• Embedded OS Components
• eLinux Boards / SBC’s
• Boot Loaders (U-BOOT, Barebox)
• Linux Kernel
• ROOTFS & Build Systems
• Embedded Programming on RB-A5D2x Linux
• Linux Internal
• Demos
• Open Discussion
Embedded Systems Classification
MCU Based
Very Low Power
Small Code (KB’s)
Baremetal
Small RTOS
MPU Based
High Speed (200MHz till 1GHz)
OS + Application Code
MPU+ Based
Special Co-Processors
Very High Computation Power
Special Hardware Accelerator
Engines like TPU, VPU, GPU’s
S1.0 S2.0 S3.0
Mostly uses Cortex-M4
having BLE comm and few
sensors need companion
mobile
Mostly uses Cortex-A7, 4G
comm friendly UI, make
calls, check emails etc …
Mostly uses Cortex-53, 4G
and advance AI/ML
capabilities to process the
data on-device and generate
analytics & feedback
RootFS
Toolchain
eLinux System ARCH
Linux OS Distributions
System Hardware
Processor Blueprint, defines IS & other hardware blocks of Processor
Processor design in VHDL / Verilog having ALU, Registors, TCU, Buses …
Product = SBC + Software + Housing/Mechanicals
Silicon with Processor & peripherals like GPIO, UART, I2C, SPI, USB,
Ethernet …
SOM = SOC+ RAM + Flash + PMIC, SBC = Board with SOM & interfacing
devices like LCD, Connectors, Sensors & Communication modules
SOC Vendors Platforms
TI AM335x, AM437x, AM572x
NXP imx6ULL, imx6(S/D/Q), imx8
Microchip SAML1x, SAMA5D2x
ST Microelectronics STM32MP15x
Renesas RZ/A1x, RZ/G1x, RZ/G2x
Rockchip RK3036, RK3288, RK3399
Qualcomm Snapdragon 200, 400, 800
Mediatek MT8312, MT8135, MT8176
Amlogic S805, S812, S912
Allwinner A2x, A3x, A6x
ARM SOC’s & Vendors
eLinux SBC
eLinux SBC
eLinux SBC
eLinux SBC
Toolchain
Components of Toolchain
Bins
Compiler
Assembler
Linker
Format Convertor
Libs
C Library
pTherad Lib
Other …
Tools
Debugging tools
Steps to Install Toolchain for RuggedBOARD link …
Bootloader
Boot Process
ON PC:
Power On-> BIOS ( POST, Bootstraploader) -> MBR -> Bootloader -> Kernel -> RFS
ON RuggedBOARD:
1. Power On SBC
2. SOC BootROM Code will exec
3. BootCFG Pins will define the bootdevice ( NAND, NOR, SDCARD ..... )
4. From Bootdevice first piece of code (PBL) loaded in SRAM and executed
5. PBL responsible for External RAM Init and loads the BL to External RAM and execute.
6. BL will load the kernel and executes
7. Kernel boots and mounts the RootFS and finally executes the init binary
8. Init will follow init rc scripts to start services and applications
U-boot Source
Browse Source: https://github.com/rugged-board/uboot-rba5d2x
Compiling U-Boot for RuggedBOARD
#Set the toolchain path first
$ . env_setup.sh
# Download uboot Source
$ git clone https://github.com/rugged-board/uboot-rba5d2x.git
$ cd uboot-rba5d2x
$ git checkout origin/uboot-rba5d2x
# Compile u-boot bootloader
make
# Configure u-boot bootloader for RB-A5D2x
$ make rugged_board_a5d2x_mmc1_defconfig # For SD Card
Or
$ make rugged_board_a5d2x_qspiflash_defconfig # For NOR Boot
Linux Kernel
Source: https://github.com/rugged-board/linux-rba5d2x
Linux Kernel Dir Structure:
linux/
arch/arm/
plat-<soc_family>
mach-<soc_family> --> sama5.c
kernel
boot/dts
tools --> mach-types
configs ==> <boardname_defconfig>
drivers/
gpio, usb, spi, i2c, mtd, mmc, net ....
Documentation/
kernel-parameters.txt
#Set the toolchain path first
$ . env_setup.sh
Kernel Source
#Linux Kernel Images = vmlinux, Image, zImage, uImage
# Configure kernel for RB-A5D2x
$ make dtbs
$ make
# Download Kernel Source from RB github
$ git clone https://github.com/rugged-board/linux-rba5d2x.git
$ cd linux-rba5d2x
$ git checkout origin/linux-rba5d2x
# Configure kernel for RB-A5D2x
$ make rb_a5d2x_defconfig
COMPILING kernel for RuggedBOARD:
Root Filesystem
Components of RFS are:
1. Unix Dir Structure
2. Device Nodes
3. Scripts
4. Binaries
5. Libraries
6. Config / data files
Build System Functions
Linux Build Systems
BuildSystemsList
Crosstool-ng
Scratchbox
OpenWRT
PTXdist
LTIB
Buildroot
Open Embedded
Yocto Project
Fetch Source
Extract
Patch
Configure
Compile
Package
Image Generation
COMPILING Yocto for RuggedBOARD:
Yocto Compilation
#Download source
$ mkdir yocto_rba5d2x
$ cd yocto_rba5d2x
$ mkdir sources
$ cd sources
$ git clone https://github.com/rugged-board/poky.git -b sumo-rba5d2x
$ git clone git://git.openembedded.org/meta-openembedded -b sumo
$ git clone https://github.com/rugged-board/meta-rba5d2x.git -b sumo-rba5d2x
#Continue next slide ……
#Install host packages
$ sudo apt-get install gawk wget git-core diffstat unzip texinfo gcc-multilib 
build-essential chrpath socat libsdl1.2-dev xterm
#Configure for RuggedBOARD-A5D2x
$ source sources/poky/oe-init-build-env
$ vi conf/local.conf
# Edit MACHINE ?= "rugged-board-a5d2x-sd1“
Yocto Compilation
#Compile
$ bitbake rb-sd-core-image-minimal # For SD Card Images
Or
$ bitbake rb-nor-core-image-minimal # For NOR Flash Images
#Images for SD Card
$ cd tmp/deploy/images/rugged-board-a5d2x-sd1/
#Follow Boot from SD Card Tutorial..
#Images for NOR
$ cd tmp/deploy/images/rugged-board-a5d2x/
#Follow NOR Flashing Tutorial..
eLinux Interface Programming
import mraa
import time
gpio_1 = mraa.Gpio(61)
gpio_1.dir(mraa.DIR_OUT)
while True:
gpio_1.write(1)
time.sleep(1)
gpio_1.write(0)
time.sleep(1)
Sensor Programming using UPM Library on Linux
Embedded Interface Programming using MRAA
Library on Linux
from upm import pyupm_mcp9808 as MCP9808
# Instantiate the Infrared-Thermopile Sensor on I2C on bus 1
mySensor = MCP9808.MCP9808(2,0x18)
print("Temperature : "+str(mySensor.getTemp()))
Linux Internals
1. Linux Shell commands
2. Linux Shell Scripting
3. Process ( fork, exec, clone )
4. Threads
5. IPC ( Inter Process Communication)
Pipe, FiFO, MsgQ, SharedMemory, Semaphores , Socket
6. Socket Programming
7. Concepts ( Scheduler, Memory Mgmt, FileSystem )
Demo
RuggedBOARD
Industrial Grade Hardware for IIoT
https://Community.ruggedboard.com
Boot Process
Flash Memory
Main Memory / DDR
SRAM in SOC
AT91 Bootstrap
U-Boot
Kernel
Mounts on
/
Kernel
U-Boot
AT91 Bootstrap
Device Tree Bin(DTB)Device Tree Bin(DTB)
Root FS
Next Sessions
1. U-Boot Porting using RuggedBOARD-A5D2x
2. Linux Kernel Porting using RuggedBOARD-A5D2x
a. Source Code walkthrough & Code flow
b. Kconfig Kernel Configuration System
c. Adding Custom driver
3. Yocto BSP using RuggedBOARD-A5D2x
4. How to design your own Single Board Computer using phyCORE-A5D2x. [HW Design]
5. Building Gateway Hardware and Open Source Linux Stacks for Gateway. [HW Design]
To get update’s follow RuggedBOARD on LinkedIn, Youtube, Twitter, Facebook &
Instagram links are on next slide …
Connect-us
Open Discussions
B Vasu Dev
ABOUT Vasu
Vasu has 15+ Years of industry experience in Embedded Technologies mainly on ARM & Linux, he
has worked at major MNC’s like LG, Wipro, MIC Electronics and is currently heading PHYTEC INDA,
a subsidiary of PHYTEC Messtechnik GmbH GERMANY as Managing Director. PHYTEC serves as
OEM for many electronic and embedded companies to develop and deploy their products at the
lowest possible time with high reliability and quality using ARM based SOMs (System On Modules )
& SBCs (Single Board Computers). The industry verticals he was engaged are Industrial
Automation, Mobility & Energy, Medical/Healthcare, Retail market.
Apart from his technical work, he is an active coach & guide for Embedded developers and actively
spend his time to train the developers on Embedded Linux, Yocto, IoT, Android System
Development. He is the master mind behind RuggedBOARD Open Source Hardware Platform. Vasu
as a mentor helped many start-ups to build their products and position them in market.
Managing Director
PHYTEC Embedded Pvt Ltd
vasu.b@phytec.in
+91-9535504414
Presenter Profile

Mais conteúdo relacionado

Mais procurados

Linux Kernel Module - For NLKB
Linux Kernel Module - For NLKBLinux Kernel Module - For NLKB
Linux Kernel Module - For NLKBshimosawa
 
Linux Porting
Linux PortingLinux Porting
Linux PortingChamp Yen
 
Arm device tree and linux device drivers
Arm device tree and linux device driversArm device tree and linux device drivers
Arm device tree and linux device driversHoucheng Lin
 
Vmlinux: anatomy of bzimage and how x86 64 processor is booted
Vmlinux: anatomy of bzimage and how x86 64 processor is bootedVmlinux: anatomy of bzimage and how x86 64 processor is booted
Vmlinux: anatomy of bzimage and how x86 64 processor is bootedAdrian Huang
 
linux device driver
linux device driverlinux device driver
linux device driverRahul Batra
 
Linux Kernel - Virtual File System
Linux Kernel - Virtual File SystemLinux Kernel - Virtual File System
Linux Kernel - Virtual File SystemAdrian Huang
 
Bootloaders (U-Boot)
Bootloaders (U-Boot) Bootloaders (U-Boot)
Bootloaders (U-Boot) Omkar Rane
 
Uboot startup sequence
Uboot startup sequenceUboot startup sequence
Uboot startup sequenceHoucheng Lin
 
U-Boot presentation 2013
U-Boot presentation  2013U-Boot presentation  2013
U-Boot presentation 2013Wave Digitech
 
Secure Boot on ARM systems – Building a complete Chain of Trust upon existing...
Secure Boot on ARM systems – Building a complete Chain of Trust upon existing...Secure Boot on ARM systems – Building a complete Chain of Trust upon existing...
Secure Boot on ARM systems – Building a complete Chain of Trust upon existing...Linaro
 
Anatomy of the loadable kernel module (lkm)
Anatomy of the loadable kernel module (lkm)Anatomy of the loadable kernel module (lkm)
Anatomy of the loadable kernel module (lkm)Adrian Huang
 
qemu + gdb: The efficient way to understand/debug Linux kernel code/data stru...
qemu + gdb: The efficient way to understand/debug Linux kernel code/data stru...qemu + gdb: The efficient way to understand/debug Linux kernel code/data stru...
qemu + gdb: The efficient way to understand/debug Linux kernel code/data stru...Adrian Huang
 
Browsing Linux Kernel Source
Browsing Linux Kernel SourceBrowsing Linux Kernel Source
Browsing Linux Kernel SourceMotaz Saad
 
LCU13: An Introduction to ARM Trusted Firmware
LCU13: An Introduction to ARM Trusted FirmwareLCU13: An Introduction to ARM Trusted Firmware
LCU13: An Introduction to ARM Trusted FirmwareLinaro
 
Linux Initialization Process (2)
Linux Initialization Process (2)Linux Initialization Process (2)
Linux Initialization Process (2)shimosawa
 
Linux kernel debugging
Linux kernel debuggingLinux kernel debugging
Linux kernel debuggingHao-Ran Liu
 

Mais procurados (20)

Linux Kernel Module - For NLKB
Linux Kernel Module - For NLKBLinux Kernel Module - For NLKB
Linux Kernel Module - For NLKB
 
Linux Porting
Linux PortingLinux Porting
Linux Porting
 
Arm device tree and linux device drivers
Arm device tree and linux device driversArm device tree and linux device drivers
Arm device tree and linux device drivers
 
Vmlinux: anatomy of bzimage and how x86 64 processor is booted
Vmlinux: anatomy of bzimage and how x86 64 processor is bootedVmlinux: anatomy of bzimage and how x86 64 processor is booted
Vmlinux: anatomy of bzimage and how x86 64 processor is booted
 
linux device driver
linux device driverlinux device driver
linux device driver
 
Linux Kernel - Virtual File System
Linux Kernel - Virtual File SystemLinux Kernel - Virtual File System
Linux Kernel - Virtual File System
 
Bootloaders (U-Boot)
Bootloaders (U-Boot) Bootloaders (U-Boot)
Bootloaders (U-Boot)
 
Basic Linux Internals
Basic Linux InternalsBasic Linux Internals
Basic Linux Internals
 
Uboot startup sequence
Uboot startup sequenceUboot startup sequence
Uboot startup sequence
 
U-Boot presentation 2013
U-Boot presentation  2013U-Boot presentation  2013
U-Boot presentation 2013
 
Secure Boot on ARM systems – Building a complete Chain of Trust upon existing...
Secure Boot on ARM systems – Building a complete Chain of Trust upon existing...Secure Boot on ARM systems – Building a complete Chain of Trust upon existing...
Secure Boot on ARM systems – Building a complete Chain of Trust upon existing...
 
Linux device drivers
Linux device drivers Linux device drivers
Linux device drivers
 
Anatomy of the loadable kernel module (lkm)
Anatomy of the loadable kernel module (lkm)Anatomy of the loadable kernel module (lkm)
Anatomy of the loadable kernel module (lkm)
 
Embedded Linux Kernel - Build your custom kernel
Embedded Linux Kernel - Build your custom kernelEmbedded Linux Kernel - Build your custom kernel
Embedded Linux Kernel - Build your custom kernel
 
qemu + gdb: The efficient way to understand/debug Linux kernel code/data stru...
qemu + gdb: The efficient way to understand/debug Linux kernel code/data stru...qemu + gdb: The efficient way to understand/debug Linux kernel code/data stru...
qemu + gdb: The efficient way to understand/debug Linux kernel code/data stru...
 
Browsing Linux Kernel Source
Browsing Linux Kernel SourceBrowsing Linux Kernel Source
Browsing Linux Kernel Source
 
LCU13: An Introduction to ARM Trusted Firmware
LCU13: An Introduction to ARM Trusted FirmwareLCU13: An Introduction to ARM Trusted Firmware
LCU13: An Introduction to ARM Trusted Firmware
 
Linux Initialization Process (2)
Linux Initialization Process (2)Linux Initialization Process (2)
Linux Initialization Process (2)
 
Linux kernel debugging
Linux kernel debuggingLinux kernel debugging
Linux kernel debugging
 
Embedded Linux on ARM
Embedded Linux on ARMEmbedded Linux on ARM
Embedded Linux on ARM
 

Semelhante a Embedded Linux BSP Training (Intro)

The Yocto Project
The Yocto ProjectThe Yocto Project
The Yocto Projectrossburton
 
An Overview of the IHK/McKernel Multi-kernel Operating System
An Overview of the IHK/McKernel Multi-kernel Operating SystemAn Overview of the IHK/McKernel Multi-kernel Operating System
An Overview of the IHK/McKernel Multi-kernel Operating SystemLinaro
 
A million ways to provision embedded linux devices
A million ways to provision embedded linux devicesA million ways to provision embedded linux devices
A million ways to provision embedded linux devicesMender.io
 
Tac Presentation October 72014- Raspberry PI
Tac Presentation October 72014- Raspberry PITac Presentation October 72014- Raspberry PI
Tac Presentation October 72014- Raspberry PICliff Samuels Jr.
 
Aftab_Alam_Resume2016
Aftab_Alam_Resume2016Aftab_Alam_Resume2016
Aftab_Alam_Resume2016AFTAB ALAM
 
An Introduction to the Yocto Embedded Framework 2018
An Introduction to the Yocto Embedded Framework 2018An Introduction to the Yocto Embedded Framework 2018
An Introduction to the Yocto Embedded Framework 2018ICS
 
An Introduction to RISC-V bootflow
An Introduction to RISC-V bootflowAn Introduction to RISC-V bootflow
An Introduction to RISC-V bootflowAtish Patra
 
ChromePad - Chromium OS for ThinkPad
ChromePad - Chromium OS for ThinkPadChromePad - Chromium OS for ThinkPad
ChromePad - Chromium OS for ThinkPadAndrewWright224
 
ChromePad - Chromium OS ThinkPad X220
ChromePad - Chromium OS ThinkPad X220ChromePad - Chromium OS ThinkPad X220
ChromePad - Chromium OS ThinkPad X220AndrewWright224
 
Getting started with LinuxBoot Firmware on AArch64 Server
Getting started with LinuxBoot Firmware on AArch64 Server Getting started with LinuxBoot Firmware on AArch64 Server
Getting started with LinuxBoot Firmware on AArch64 Server Naohiro Tamura
 
Developing Applications for Beagle Bone Black, Raspberry Pi and SoC Single Bo...
Developing Applications for Beagle Bone Black, Raspberry Pi and SoC Single Bo...Developing Applications for Beagle Bone Black, Raspberry Pi and SoC Single Bo...
Developing Applications for Beagle Bone Black, Raspberry Pi and SoC Single Bo...ryancox
 
FOSDEM_2019_Buildroot_RISCV.pdf
FOSDEM_2019_Buildroot_RISCV.pdfFOSDEM_2019_Buildroot_RISCV.pdf
FOSDEM_2019_Buildroot_RISCV.pdfssuser30e7d2
 
Bsp customization and porting of linux on arm cortex based i.mx6 processor wi...
Bsp customization and porting of linux on arm cortex based i.mx6 processor wi...Bsp customization and porting of linux on arm cortex based i.mx6 processor wi...
Bsp customization and porting of linux on arm cortex based i.mx6 processor wi...eSAT Publishing House
 
First Steps Developing Embedded Applications using Heterogeneous Multi-core P...
First Steps Developing Embedded Applications using Heterogeneous Multi-core P...First Steps Developing Embedded Applications using Heterogeneous Multi-core P...
First Steps Developing Embedded Applications using Heterogeneous Multi-core P...Toradex
 
Red hat enterprise_linux-5.5-release_notes-en-us
Red hat enterprise_linux-5.5-release_notes-en-usRed hat enterprise_linux-5.5-release_notes-en-us
Red hat enterprise_linux-5.5-release_notes-en-usDuong Hieu
 

Semelhante a Embedded Linux BSP Training (Intro) (20)

Building Embedded Linux UDOONEO
Building Embedded Linux UDOONEOBuilding Embedded Linux UDOONEO
Building Embedded Linux UDOONEO
 
The Yocto Project
The Yocto ProjectThe Yocto Project
The Yocto Project
 
An Overview of the IHK/McKernel Multi-kernel Operating System
An Overview of the IHK/McKernel Multi-kernel Operating SystemAn Overview of the IHK/McKernel Multi-kernel Operating System
An Overview of the IHK/McKernel Multi-kernel Operating System
 
A million ways to provision embedded linux devices
A million ways to provision embedded linux devicesA million ways to provision embedded linux devices
A million ways to provision embedded linux devices
 
Tac Presentation October 72014- Raspberry PI
Tac Presentation October 72014- Raspberry PITac Presentation October 72014- Raspberry PI
Tac Presentation October 72014- Raspberry PI
 
Aftab_Alam_Resume2016
Aftab_Alam_Resume2016Aftab_Alam_Resume2016
Aftab_Alam_Resume2016
 
An Introduction to the Yocto Embedded Framework 2018
An Introduction to the Yocto Embedded Framework 2018An Introduction to the Yocto Embedded Framework 2018
An Introduction to the Yocto Embedded Framework 2018
 
Building
BuildingBuilding
Building
 
An Introduction to RISC-V bootflow
An Introduction to RISC-V bootflowAn Introduction to RISC-V bootflow
An Introduction to RISC-V bootflow
 
ChromePad - Chromium OS for ThinkPad
ChromePad - Chromium OS for ThinkPadChromePad - Chromium OS for ThinkPad
ChromePad - Chromium OS for ThinkPad
 
ChromePad - Chromium OS ThinkPad X220
ChromePad - Chromium OS ThinkPad X220ChromePad - Chromium OS ThinkPad X220
ChromePad - Chromium OS ThinkPad X220
 
Getting started with LinuxBoot Firmware on AArch64 Server
Getting started with LinuxBoot Firmware on AArch64 Server Getting started with LinuxBoot Firmware on AArch64 Server
Getting started with LinuxBoot Firmware on AArch64 Server
 
Developing Applications for Beagle Bone Black, Raspberry Pi and SoC Single Bo...
Developing Applications for Beagle Bone Black, Raspberry Pi and SoC Single Bo...Developing Applications for Beagle Bone Black, Raspberry Pi and SoC Single Bo...
Developing Applications for Beagle Bone Black, Raspberry Pi and SoC Single Bo...
 
Beagleboard xm-setup
Beagleboard xm-setupBeagleboard xm-setup
Beagleboard xm-setup
 
FOSDEM_2019_Buildroot_RISCV.pdf
FOSDEM_2019_Buildroot_RISCV.pdfFOSDEM_2019_Buildroot_RISCV.pdf
FOSDEM_2019_Buildroot_RISCV.pdf
 
Introduction and course Details of Embedded Linux Platform Developer Training
Introduction and course Details of Embedded Linux Platform Developer TrainingIntroduction and course Details of Embedded Linux Platform Developer Training
Introduction and course Details of Embedded Linux Platform Developer Training
 
Bsp customization and porting of linux on arm cortex based i.mx6 processor wi...
Bsp customization and porting of linux on arm cortex based i.mx6 processor wi...Bsp customization and porting of linux on arm cortex based i.mx6 processor wi...
Bsp customization and porting of linux on arm cortex based i.mx6 processor wi...
 
First Steps Developing Embedded Applications using Heterogeneous Multi-core P...
First Steps Developing Embedded Applications using Heterogeneous Multi-core P...First Steps Developing Embedded Applications using Heterogeneous Multi-core P...
First Steps Developing Embedded Applications using Heterogeneous Multi-core P...
 
Slimline Open Firmware
Slimline Open FirmwareSlimline Open Firmware
Slimline Open Firmware
 
Red hat enterprise_linux-5.5-release_notes-en-us
Red hat enterprise_linux-5.5-release_notes-en-usRed hat enterprise_linux-5.5-release_notes-en-us
Red hat enterprise_linux-5.5-release_notes-en-us
 

Último

Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Alan Dix
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityPrincipled Technologies
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdfhans926745
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfEnterprise Knowledge
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...gurkirankumar98700
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024Scott Keck-Warren
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slidevu2urc
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking MenDelhi Call girls
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘RTylerCroy
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024The Digital Insurer
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxOnBoard
 

Último (20)

Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptx
 

Embedded Linux BSP Training (Intro)

  • 1. Embedded Linux BSP Training (Intro) Organised by YoctoTutor & supported by RuggedBOARD
  • 2. Agenda • Introduction to EMBEDDED LINUX • Embedded OS Components • eLinux Boards / SBC’s • Boot Loaders (U-BOOT, Barebox) • Linux Kernel • ROOTFS & Build Systems • Embedded Programming on RB-A5D2x Linux • Linux Internal • Demos • Open Discussion
  • 3. Embedded Systems Classification MCU Based Very Low Power Small Code (KB’s) Baremetal Small RTOS MPU Based High Speed (200MHz till 1GHz) OS + Application Code MPU+ Based Special Co-Processors Very High Computation Power Special Hardware Accelerator Engines like TPU, VPU, GPU’s S1.0 S2.0 S3.0 Mostly uses Cortex-M4 having BLE comm and few sensors need companion mobile Mostly uses Cortex-A7, 4G comm friendly UI, make calls, check emails etc … Mostly uses Cortex-53, 4G and advance AI/ML capabilities to process the data on-device and generate analytics & feedback
  • 6. System Hardware Processor Blueprint, defines IS & other hardware blocks of Processor Processor design in VHDL / Verilog having ALU, Registors, TCU, Buses … Product = SBC + Software + Housing/Mechanicals Silicon with Processor & peripherals like GPIO, UART, I2C, SPI, USB, Ethernet … SOM = SOC+ RAM + Flash + PMIC, SBC = Board with SOM & interfacing devices like LCD, Connectors, Sensors & Communication modules
  • 7. SOC Vendors Platforms TI AM335x, AM437x, AM572x NXP imx6ULL, imx6(S/D/Q), imx8 Microchip SAML1x, SAMA5D2x ST Microelectronics STM32MP15x Renesas RZ/A1x, RZ/G1x, RZ/G2x Rockchip RK3036, RK3288, RK3399 Qualcomm Snapdragon 200, 400, 800 Mediatek MT8312, MT8135, MT8176 Amlogic S805, S812, S912 Allwinner A2x, A3x, A6x ARM SOC’s & Vendors
  • 12. Toolchain Components of Toolchain Bins Compiler Assembler Linker Format Convertor Libs C Library pTherad Lib Other … Tools Debugging tools Steps to Install Toolchain for RuggedBOARD link …
  • 13. Bootloader Boot Process ON PC: Power On-> BIOS ( POST, Bootstraploader) -> MBR -> Bootloader -> Kernel -> RFS ON RuggedBOARD: 1. Power On SBC 2. SOC BootROM Code will exec 3. BootCFG Pins will define the bootdevice ( NAND, NOR, SDCARD ..... ) 4. From Bootdevice first piece of code (PBL) loaded in SRAM and executed 5. PBL responsible for External RAM Init and loads the BL to External RAM and execute. 6. BL will load the kernel and executes 7. Kernel boots and mounts the RootFS and finally executes the init binary 8. Init will follow init rc scripts to start services and applications
  • 14. U-boot Source Browse Source: https://github.com/rugged-board/uboot-rba5d2x Compiling U-Boot for RuggedBOARD #Set the toolchain path first $ . env_setup.sh # Download uboot Source $ git clone https://github.com/rugged-board/uboot-rba5d2x.git $ cd uboot-rba5d2x $ git checkout origin/uboot-rba5d2x # Compile u-boot bootloader make # Configure u-boot bootloader for RB-A5D2x $ make rugged_board_a5d2x_mmc1_defconfig # For SD Card Or $ make rugged_board_a5d2x_qspiflash_defconfig # For NOR Boot
  • 15. Linux Kernel Source: https://github.com/rugged-board/linux-rba5d2x Linux Kernel Dir Structure: linux/ arch/arm/ plat-<soc_family> mach-<soc_family> --> sama5.c kernel boot/dts tools --> mach-types configs ==> <boardname_defconfig> drivers/ gpio, usb, spi, i2c, mtd, mmc, net .... Documentation/ kernel-parameters.txt
  • 16. #Set the toolchain path first $ . env_setup.sh Kernel Source #Linux Kernel Images = vmlinux, Image, zImage, uImage # Configure kernel for RB-A5D2x $ make dtbs $ make # Download Kernel Source from RB github $ git clone https://github.com/rugged-board/linux-rba5d2x.git $ cd linux-rba5d2x $ git checkout origin/linux-rba5d2x # Configure kernel for RB-A5D2x $ make rb_a5d2x_defconfig COMPILING kernel for RuggedBOARD:
  • 17. Root Filesystem Components of RFS are: 1. Unix Dir Structure 2. Device Nodes 3. Scripts 4. Binaries 5. Libraries 6. Config / data files
  • 18. Build System Functions Linux Build Systems BuildSystemsList Crosstool-ng Scratchbox OpenWRT PTXdist LTIB Buildroot Open Embedded Yocto Project Fetch Source Extract Patch Configure Compile Package Image Generation
  • 19. COMPILING Yocto for RuggedBOARD: Yocto Compilation #Download source $ mkdir yocto_rba5d2x $ cd yocto_rba5d2x $ mkdir sources $ cd sources $ git clone https://github.com/rugged-board/poky.git -b sumo-rba5d2x $ git clone git://git.openembedded.org/meta-openembedded -b sumo $ git clone https://github.com/rugged-board/meta-rba5d2x.git -b sumo-rba5d2x #Continue next slide …… #Install host packages $ sudo apt-get install gawk wget git-core diffstat unzip texinfo gcc-multilib build-essential chrpath socat libsdl1.2-dev xterm
  • 20. #Configure for RuggedBOARD-A5D2x $ source sources/poky/oe-init-build-env $ vi conf/local.conf # Edit MACHINE ?= "rugged-board-a5d2x-sd1“ Yocto Compilation #Compile $ bitbake rb-sd-core-image-minimal # For SD Card Images Or $ bitbake rb-nor-core-image-minimal # For NOR Flash Images #Images for SD Card $ cd tmp/deploy/images/rugged-board-a5d2x-sd1/ #Follow Boot from SD Card Tutorial.. #Images for NOR $ cd tmp/deploy/images/rugged-board-a5d2x/ #Follow NOR Flashing Tutorial..
  • 21. eLinux Interface Programming import mraa import time gpio_1 = mraa.Gpio(61) gpio_1.dir(mraa.DIR_OUT) while True: gpio_1.write(1) time.sleep(1) gpio_1.write(0) time.sleep(1) Sensor Programming using UPM Library on Linux Embedded Interface Programming using MRAA Library on Linux from upm import pyupm_mcp9808 as MCP9808 # Instantiate the Infrared-Thermopile Sensor on I2C on bus 1 mySensor = MCP9808.MCP9808(2,0x18) print("Temperature : "+str(mySensor.getTemp()))
  • 22. Linux Internals 1. Linux Shell commands 2. Linux Shell Scripting 3. Process ( fork, exec, clone ) 4. Threads 5. IPC ( Inter Process Communication) Pipe, FiFO, MsgQ, SharedMemory, Semaphores , Socket 6. Socket Programming 7. Concepts ( Scheduler, Memory Mgmt, FileSystem )
  • 23. Demo
  • 24. RuggedBOARD Industrial Grade Hardware for IIoT https://Community.ruggedboard.com
  • 25. Boot Process Flash Memory Main Memory / DDR SRAM in SOC AT91 Bootstrap U-Boot Kernel Mounts on / Kernel U-Boot AT91 Bootstrap Device Tree Bin(DTB)Device Tree Bin(DTB) Root FS
  • 26. Next Sessions 1. U-Boot Porting using RuggedBOARD-A5D2x 2. Linux Kernel Porting using RuggedBOARD-A5D2x a. Source Code walkthrough & Code flow b. Kconfig Kernel Configuration System c. Adding Custom driver 3. Yocto BSP using RuggedBOARD-A5D2x 4. How to design your own Single Board Computer using phyCORE-A5D2x. [HW Design] 5. Building Gateway Hardware and Open Source Linux Stacks for Gateway. [HW Design] To get update’s follow RuggedBOARD on LinkedIn, Youtube, Twitter, Facebook & Instagram links are on next slide …
  • 29. B Vasu Dev ABOUT Vasu Vasu has 15+ Years of industry experience in Embedded Technologies mainly on ARM & Linux, he has worked at major MNC’s like LG, Wipro, MIC Electronics and is currently heading PHYTEC INDA, a subsidiary of PHYTEC Messtechnik GmbH GERMANY as Managing Director. PHYTEC serves as OEM for many electronic and embedded companies to develop and deploy their products at the lowest possible time with high reliability and quality using ARM based SOMs (System On Modules ) & SBCs (Single Board Computers). The industry verticals he was engaged are Industrial Automation, Mobility & Energy, Medical/Healthcare, Retail market. Apart from his technical work, he is an active coach & guide for Embedded developers and actively spend his time to train the developers on Embedded Linux, Yocto, IoT, Android System Development. He is the master mind behind RuggedBOARD Open Source Hardware Platform. Vasu as a mentor helped many start-ups to build their products and position them in market. Managing Director PHYTEC Embedded Pvt Ltd vasu.b@phytec.in +91-9535504414 Presenter Profile