Starting with SAMA5D3 Xplained

Moderator: nferre

gdillen
Posts: 7
Joined: Thu Mar 13, 2014 8:56 pm

Starting with SAMA5D3 Xplained

Tue Mar 18, 2014 11:07 pm

Yesterday I received my SAMA5D3 Xplained. So I can start experimenting with it. I'm a confused as how to start development for this device. When I connected the device to my Mac the blue led goes on/off and I can login to the device. So, obviously there is a Linux installed on it. However to develop for it should I install another Linux (I read about people installing another Linux on the device), or is the installed Linux sufficient for development? How can I install e.g. a C compiler, Python, ... on the device, since I suppose the system has just a bare minimum installed?

Many thanks.
cmcraeslo
Posts: 9
Joined: Wed Mar 19, 2014 11:16 pm

Re: Starting with SAMA5D3 Xplained

Wed Mar 19, 2014 11:21 pm

Hello,

I too am interested in how to start developing for this board. I have the board connected and would like to start buiding apps for the system. However, there are no cc/gcc tools on the board - where and how should we get them?

Or was it meant to cross-compile on other system and then just run it?
CptTitanic
Posts: 871
Joined: Sat Oct 30, 2010 6:04 pm

Re: Starting with SAMA5D3 Xplained

Sat Mar 22, 2014 12:56 am

How it works on other SAM9 platforms is you build your kernel/filesystem with buildroot, or whatever, on your host linix box and that generates the cross compiling tools, which can be used on the host to build apps.

The alternative is that you go into the menuconfig process and select that the dev tools are placed in the file system of the target. This can make the file system image quite large, I think one particular build with C, C++ and JamVM got to be 55MB or so. Remember to select some editors too.

With the tools on the target you can edit-compile-link-run right there. With the tools on the host you can edit-compile-link, and then use something like TFTP and a server to pull them from the development machine.

Other method would be via GDB, where you can supposedly inject-run-debug stuff from the host side, but it's not a method I've investigated.

Will get an SAMA5D3 Xplained and experiment with it shortly.
User avatar
koan
Contact:
Location: Bergamo, Italia
Posts: 209
Joined: Wed May 12, 2004 6:59 pm

Re: Starting with SAMA5D3 Xplained

Sat Mar 22, 2014 9:07 am

We at KOAN are testing it this week.
Basically you need a Yocto build environment plus meta-atmel
https://github.com/linux4sam/meta-atmel

Build Configuration:
BB_VERSION = "1.20.0"
BUILD_SYS = "x86_64-linux"
NATIVELSBSTRING = "Ubuntu-12.04"
TARGET_SYS = "arm-poky-linux-gnueabi"
MACHINE = "sama5d3xek"
DISTRO = "poky"
DISTRO_VERSION = "1.5.1"
TUNE_FEATURES = "armv7a vfp thumb callconvention-hard cortexa5"
TARGET_FPU = "vfp"
meta
meta-yocto
meta-yocto-bsp = "dora:d63a5f557d5fa4cb6637bf75f1b9d21a5c109b55"
meta-oe
meta-networking = "dora:40e0f371f3eb1628655c484feac0cebf810737b4"
meta-atmel = "master:db3fae9bc539ace7ecbda6ae94547136b5577883"
...
NOTE: Tasks Summary: Attempted 3486 tasks of which 1356 didn't need to be rerun and all succeeded.
Marco Cavallini
Koan s.a.s. - Bergamo - ITALIA
Embedded and Real-Time Software Engineering
- Atmel Third Party Consultant
Tel. +39-(0)35-255.235 - Fax +39-178-223.9748
http://www.KoanSoftware.com | http://www.KaeilOS.com
marine.aubry1@gmail.com
Posts: 1
Joined: Tue Apr 22, 2014 11:44 am

Re: Starting with SAMA5D3 Xplained

Tue Apr 22, 2014 11:52 am

Hello,

I want to develop applications for the SAMA5D3 Xplained board too, and I have no idea how to configure Buildroot in order to generate the cross compiling tools. I'm working with Fedora on VirtualBox, and I need to start developing applications managing the ethernet ports of the SAMA5D3 board asap. I have never used cross-compiling before but have developped on a Raspberry Pi using Raspbian which is quite different from cross-compiling. That's why I need a little help there using Buildroot and starting the developpement process.

Thank you in advance (and excuse my english, I'm french :wink: )
marineandme
Posts: 5
Joined: Tue Apr 22, 2014 11:45 am

Re: Starting with SAMA5D3 Xplained

Wed Apr 23, 2014 11:15 am

Edit : I've tried using Eclipse to cross-compile a simple hello world c++ file, but I seem not to have the right configuration everytime because when I try to execute the .elf file on the SAMA5D3 Xplained, I always get the same "Illegal Instruction" error. If anyone has information about that ... 

Many thanks ... again.
bseljak
Posts: 28
Joined: Thu Apr 03, 2014 1:28 am

Re: Starting with SAMA5D3 Xplained

Thu Apr 24, 2014 1:51 pm

Hi!
You could use Embeded Debian system on SAMA5D3 Xplained board as descripet here: 
http://sborut.wordpress.com/2014/04/08/ ... -xplained/

Then you could use...

Code: Select all

sudo apt-get install build-essential
...to install gcc compilers and tools to SAMA5D3 Xplained.

After installation you have "RASPBRERRY PI" like system without  GUI and you could compile on SAMA5D3 Xplained.

Here is simple manual USING THE GCC C COMPILER on raspberry or just use google...

Bye
marineandme
Posts: 5
Joined: Tue Apr 22, 2014 11:45 am

Re: Starting with SAMA5D3 Xplained

Thu Apr 24, 2014 4:50 pm

Thank you very much, we're going to try that way on one of our SAMA5D3 Xplained (we have two of them).

We'd still like to do the cross-compiling thing on the other board though, so if anyone has more information ...

Have a nice day !
bseljak
Posts: 28
Joined: Thu Apr 03, 2014 1:28 am

Re: Starting with SAMA5D3 Xplained

Thu Apr 24, 2014 9:18 pm

Hi! 

With the system mentioned in my previous post, I use Lubuntu (Light Ubuntu) host in Virtualbox.

You could simple install crosscompiler tools:

Code: Select all

sudo apt-get update
sudo apt-get upgrade
sudo apt-get install emdebian-archive-keyring
sudo apt-get install libc6-armel-cross libc6-dev-armel-cross
sudo apt-get install binutils-arm-linux-gnueabi
sudo apt-get install gcc-arm-linux-gnueabihf
sudo apt-get install g++-arm-linux-gnueabihf
sudo apt-get install u-boot-tools
sudo apt-get install libncurses5-dev
Then compile for arm target by arm-linux-gnueabi-gcc instead gcc

Borut 

Return to “SAMA5-based”

Who is online

Users browsing this forum: No registered users and 1 guest