Install the ARM cross compiler toolchain on your Linux PC
This article illustrates how to install on a Linux PC the complete toolchain
to cross compile the Linux Kernel, device drivers and applications
for the Acme Systems Linux board.
This procedure has been tested on Debian "Bookworm" 12.
Install the Cross Compilers, utilities, etc.
Install the GCC, G++ cross compilers and support programs by typing:
sudo apt update
sudo apt install libc6-armel-cross libc6-dev-armel-cross binutils-arm-linux-gnueabi libncurses5-dev build-essential bison flex libssl-dev bc
If you are using an Acqua or RoadRunner board:
sudo apt install gcc-arm-linux-gnueabihf g++-arm-linux-gnueabihf
If you are using an Arietta, Aria or FOX G20 board:
sudo apt install gcc-arm-linux-gnueabi g++-arm-linux-gnueabi
Now you are ready to cross-compile on your PC all the source available for the Acme Boards based on Microchip MPUs.
Try the cross C compiler
Let's try to cross compile a Hello World example in C and running it on
an Acme board.
This is the example:
#include "stdio.h"
int main(void) {
printf("Hello world !\n");
return 0;
}
Compile it by typing, if you are using an Arietta, Aria or FOX G20 board:
arm-linux-gnueabi-gcc hello.c -o hello
or, if you are using an Acqua or RoadRunner board:
arm-linux-gnueabihf-gcc hello.c -o hello
As you can see we are using the ARM version of gcc just installed on
your PC. It will generate an executable file for your Linux board.
Copy the executable file on the board via ssh:
scp hello root@[your_board_ip]:/root
Then open a command session on your board and run the example:
~# ./hello
Hello world !
Try the cross C++ compiler
Let's try to cross compile a Hello World example in C++ and running it on
an Acme board.
This is the example:
#include "iostream"
using namespace std;
int main(int argc, char *argv[]) {
cout << "Hello world !" << endl;
return 0;
}
Compile it typing, if you are using an Arietta, Aria or FOX G20 board:
arm-linux-gnueabi-g++ hello.cc -o hello
or, if you are using an Acqua or RoadRunner board:
arm-linux-gnueabihf-g++ hello.cc -o hello
As you can see we are using the ARM version of gcc just installed on
your PC. It will generate an executable file for your Linux board.
Copy the executable file on the board via ssh:
scp hello root@[your_board_ip]:/root
Then open a command session on your board and run the example:
~# ./hello
Hello world !
Related products
Info
Doc
Buy
- CPU Microchip SAMA5D27
- Cortex A5 @ 500 MHz
- Very low power consumption:
396mW in full speed mode
198mW at Linux prompt
17mW in standby mode
10mW in suspend to RAM mode
- Armhf architecture
- DDR3L RAM 256 MB
- QuadSPI 0/16/64/128MB
- Size: 40x30 mm
- Plug-in module
- 200 pins 0.4 mm pitch
- TFT parallel interface
- Boot from internal Quad SPI or external uSD/eMMC
- Linux Kernel 5.15 LTS
- Debian, Buildroot and Yocto
- Open source drivers
Info
Doc
Buy
Single Board Computer based on RoadRunner Linux SOM (Included)
- Classic "Credit Card" form factor
- Two USB Host 2.0 ports (one configurable as USB client on the USB-C connector)
- One 10/100 Mbit/s Lan port
- 2 Acme Sensor ports
- Double placements for 2.54mm pitch 20x2 pinstrips (not soldered) for GPIOS, SPI, I2C, Serial etc ports
- Credit Card footprint
Info
Buy
- All the circuitries you need to test the RoadRunner SOM
- USB host, USB device, Ethernet port, MicroSD socket
- Test points for power consumption measurements
- All the Roadrunner signals exposed on 2.54mm pitch pins
- On-board supercap for RTC and backup memory circuit