Project Home
Project Home
Wiki
Wiki
Project Information
Project Info
wiki3125: AtmelAT91SAM9RL64EKEvaluationBoard (Version 15)


Release Notes for the QNX Neutrino 6.4.0 BSP for Atmel AT91SAM9Rl64-EK Board#

System requirements#

Target system#

  • QNX Neutrino RTOS 6.4.0
  • Board: Atmel at91sam9rl64-EK Evaluation Board
  • Data-Flash: AT45DB642D (64 MB)
  • SDRAM: 16-bit Micron MT48LC16M16A2 (64 MB) SDRAM
  • NAND Flash: Micron MT29F2G08AAC (256 MB) NAND Flash

Host development system#

  • QNX Momentics 6.4.0, one of the following host systems:
    • QNX Neutrino 6.4.0
    • Microsoft Windows Vista, XP SP2 or SP3, 2000 SP4
    • Windows Machine have installed SAM-BA application provided from Atmel.
    • Linux Red Hat 8 or 9, Linux Red Hat Enterprise Workstation 3 or 4, Red Hat Fedora Core 3 or 4, or SUSE 10
  • Terminal emulation program (Qtalk, Momentics IDE Terminal, tip, HyperTerminal, etc.)
  • Windows Machine required SAM-BA appication to download the image on Data-Flash.
  • RS-232 serial port
  • NULL-modem serial cable
  • To connect the Board with Windows Machine USB cable is provided.

Getting Started#

Step 1: Connect your hardware#

Connect the DEBUG port of the AT91SAM9RL64 board to the first serial port of your windows machine. Install the SAM-BA application provided from Atmel. Connect the board with Windows Machine using USB Cable.

Step 2: Build the BSP#

You can build an OS image from the source code or the binary components contained in a BSP package. For instructions about building an OS image, please refer to the chapter Working with a BSP in the Building Embedded Systems manual. After Building the BSP you will find three bin files in images directory. *ifs-at91sam9rl64.bin *ipl-at91sam9rl64.bin *ipl-ifs-at91sam9rl64.bin
mkflashimage script will create a combined IPL/OS image called ipl-ifs-at91sam9rl64.bin
The mkflashimage script:

#!/bin/sh
# script to build a binary IPL and boot image for ATMEL AT91SAM9XX Evaluation Kit board
# NOTE the image (ipl-ifs-at91sam9xx.bin) must be built as binary, i.e. [virtual=armle,binary] in the buildfile 
set -v

#	Convert IPL into BINARY format
${QNX_HOST}/usr/bin/ntoarm-objcopy --input-format=elf32-littlearm --output-format=binary -R.data ../install/armle/boot/sys/ipl-at91sam9xx-at91sam9rl64 ipl-tmp-at91sam9rl64.bin

#	Pad BINARY IPL
mkrec -s16k -ffull -r ipl-tmp-at91sam9rl64.bin > ipl-at91sam9rl64.bin

#	Combine the BINARY IPL with the BINARY OS Image
cat ./ipl-at91sam9rl64.bin ./ifs-at91sam9rl64.bin > ipl-ifs-at91sam9rl64.bin

#	Cleaning up temporary files
rm -f *tmp*

Step 3A: Loading the Bootable IFS image.#

The Atmel AT91SAM9RL64 board supports booting from a native QNX bootable IPL/OS image in flash. IFS image needs to be downloaded at the Data-Flash present on the SPI Bus.
  • Make sure that IFS image is not downloading in SD card.
  • NAND FLash Jumper must be off.
  • In SAM-BA Application select the Data-Flash AT45DB/DCB tab. Execute the Enable Data-flash on CS0 script.

Step 3A: Generate a bootable flash image#

Step 4B: Download the Bootable OS image in Data-FLash#

  • In your Windows host machine installed SAM-BA application will help you to write the IPL and IFS on Data-Flash.
  • Connect the board's serial of DBGU with your windows host machine's COM Port.
  • You can use Term Tera VT100 which also offers the ability to connect to SSH2 hosts.
  • You need to Make sure that there is no SD card and Nand Flash Jumper J12 must be off and then reset the Board.
  • Now you will see >Rom BOOT prompt.

Step 4B1: Download the Bootable IFS image onto Data-Flash at location 0x4000#

  • Make Sure that IPL is already downloaded on the Data-Flash.
  • From the SAM-BA application, Select the communication mode(usb/serial) and set the board to AT91SAM9RL64-EK, Press ok.
  • Select the Data-Flash AT45DB/DCB tab from the SAM-BA application window, . Execute the Enable Data-flash on CS0 script.
  • Select the ifs-at91sam9rl64.bin file to be sent to the target.
  • Specify the address of the data-flash where image neesds to be download, and then press Send File. It will take a few seconds up to a minute.
  • Sanpshot is as follows:
AtmelAT91SAM9RL64EKEvaluationBoard/ifs-img.JPG
  • Now on your terminal you will see output as follows:

>RomBOOT
>
QNX/Neutrino IPL for ATMEL AT91SAM9xx Board :
Commands:
  d: download image to SDRAM using DBGU (serial) port
  f: scan Dataflash for image
ipl> Scanning Dataflash...

 Scanning Dataflash for image @ offset 0x00004000
Image Loaded       @ 0x20100000
Jumping to startup @ 0x20101CA0
GPIO init : DBGU, USART, Audio(AC97), NAND, LCD,
CPU0: Dcache: 128x32 WB
CPU0: Icache: 128x32
CPU0: 41069265: arm926 rev 5 200MHz
elf_map: 1M va=fe000000 pa=20100000 sz=00100000
elf_map: 1M va=fe000000 pa=20100000 sz=00100000
Header size=0x0000009c, Total Size=0x00000508, #Cpu=1, Type=4
Section:system_private offset:0x000001f0 size:0x00000068
  syspage ptr user:fc404000 kernel:fc404000
  cpupage ptr user:fc404808 kernel:fc404808 spacing:84
  kdebug info:00000000 callback:00000000
  boot pgms: idx=0
    0) base paddr:20110000 start addr:fe03d838
  ramsize:00000000 pagesize:00001000
Section:qtime offset:0x00000148 size:0x00000060
  boot:00000000 CPS:00000000005f5e10 rate/scale:160000/-12 intr:1
Section:callout offset:0x000000a0 size:0x00000048
  reboot:fc404680 power:fc40469c
  timer_load:fc4046b0 reload:fc4046d8 value:fc404704
  0) display:fc404724 poll:fc404748 break:fc40476c
  1) display:00000000 poll:00000000 break:00000000
Section:cpuinfo offset:0x000001a8 size:0x00000020
  0) cpu:41069265 flags:40000000 speed:000000c8 cache i/d:1/0 name:53
Section:cacheattr offset:0x000004c8 size:0x00000040
  0) flags:32 size:0020 #lines:0080 control:fc404508 next:255
  1) flags:11 size:0020 #lines:0080 control:fc40455c next:255
Section:meminfo offset:0x00000508 size:0x00000000
Section:asinfo offset:0x00000328 size:0x00000160
  0000) 0000000000000000-00000000ffffffff o:ffff a:0010 p:100 c:00000000 n:21
  0020) 0000000020000000-0000000023ffffff o:0000 a:0017 p:100 c:00000000 n:28
  0040) 0000000000000000-00000000ffffffff o:ffff a:0010 p:100 c:00000000 n:21
  0060) 0000000020000000-0000000023ffffff o:0040 a:0007 p:100 c:00000000 n:32
  0080) 000000002010e108-00000000205a729b o:0000 a:0005 p:100 c:00000000 n:60
  00a0) 0000000020100000-000000002010e107 o:0000 a:0007 p:100 c:00000000 n:68
  00c0) 000000002010e108-00000000205a729b o:0000 a:0007 p:100 c:00000000 n:76
  00e0) 0000000020000000-0000000020007fff o:0020 a:0007 p:100 c:00000000 n:84
  0100) 000000002001085c-00000000200fffff o:0020 a:0007 p:100 c:00000000 n:84
  0120) 00000000205a729c-0000000023dcffff o:0020 a:0007 p:100 c:00000000 n:84
  0140) 0000000023fd0000-0000000023ffffff o:0020 a:0007 p:100 c:00000000 n:84
Section:hwinfo offset:0x000002e0 size:0x00000048
  0) size:3 tag:3 isize:3, iname:0, owner:65535, kids:1
  12) size:3 tag:17 isize:3, iname:9, owner:0, kids:1
  24) size:3 tag:3 isize:3, iname:37, owner:12, kids:1
  36) size:4 tag:46 isize:4, iname:41, owner:24, kids:0
     00 00 00 00
Section:typed_strings offset:0x00000258 size:0x00000028
  off:0 type:5 string:'AT91SAM9RL64'
  off:20 type:2 string:'localhost'
Section:strings offset:0x00000280 size:0x00000060
  [0]'hw' [3]'Group' [9]'unknown' [17]'Bus' [21]'memory' [28]'ram' [32]'1to1'
  [37]'rtc' [41]'NONE' [46]'Device' [53]'arm926' [60]'imagefs' [68]'startup'
  [76]'bootram' [84]'sysram'
Section:intrinfo offset:0x00000488 size:0x00000040
  0) vector_base:00000000, #vectors:32, cascade_vector:7fffffff
     cpu_intr_base:00000000, cpu_intr_stride:0, flags:0000
      id => flags:8000, size:002c, rtn:fc4045c8
     eoi => flags:9000, size:0028, rtn:fc4045f4
     mask:fc40461c, unmask:fc404640, config:00000000
Section:smp offset:0x00000508 size:0x00000000
Section:pminfo offset:0x00000508 size:0x00000000
Section:mdriver offset:0x00000508 size:0x00000000
Section:boxinfo offset:0x000001c8 size:0x00000028
  hw_flags:00000000
Section:cpu offset:0x00000128 size:0x00000020
  page_flush:fc40458c page_flush_deferred:fc4045c4
  upte_ro:00000aae upte_rw:00000ffe
  kpte_ro:0000000e kpte_rw:0000055e
  mask_nc:0000000c
  mmu_cr1:00051078 set:0000317f clr:00000000 -> 0005317f

System page at phys:20010000 user:fc404000 kern:fc404000
Starting next program at vfe03d838
cpu_startnext: cpu0 -> fe03d838
Welcome to QNX Neutrino 6.4 on the Atmel AT91SAM9RL64 Board

You can test the OS simply by executing any shell builtin command or any command residing within the OS image (e.g. ls). 

Step 4B2: Download the IPL onto the Data-Flash at location 0x0:#

  • From the SAM-BA application, Select the communication mode(usb/serial) and set the board to AT91SAM9RL64-EK, Press ok.
  • Select the Data-Flash AT45DB/DCB tab from the SAM-BA application window, . Execute the Enable Data-flash on CS0 script.
  • Select the ipl-at91sam9rl64.bin file to be sent to the target, and then press Send File. It will take a few seconds up to a minute.
  • Sanpshot is as follows:
AtmelAT91SAM9RL64EKEvaluationBoard/ipl-img.JPG
  • Now You need to write the IFS image on the Data-Flash. For that you need to perform Step 4B1.

Step 4B3: Download the combined image of IPL and IFS onto Data-Flash at location 0x0#

  • From the SAM-BA application, Select the communication mode(usb/serial) and set the board to AT91SAM9RL64-EK, Press ok.
  • Select the Data-Flash AT45DB/DCB tab from the SAM-BA application window, . Execute the Enable Data-flash on CS0 script.
  • Select the ipl-ifs-at91sam9rl64.bin file to be sent to the target, and then press Send File. It will take a few seconds up to a minute.
  • Sanpshot is as follows:
AtmelAT91SAM9RL64EKEvaluationBoard/ipl-ifs-img.JPG
  • Now on your terminal you will see output as follows:

>RomBOOT
>
QNX/Neutrino IPL for ATMEL AT91SAM9xx Board :
Commands:
  d: download image to SDRAM using DBGU (serial) port
  f: scan Dataflash for image
ipl> Scanning Dataflash...

 Scanning Dataflash for image @ offset 0x00004000
Image Loaded       @ 0x20100000
Jumping to startup @ 0x20101CA0
GPIO init : DBGU, USART, Audio(AC97), NAND, LCD,
CPU0: Dcache: 128x32 WB
CPU0: Icache: 128x32
CPU0: 41069265: arm926 rev 5 200MHz
elf_map: 1M va=fe000000 pa=20100000 sz=00100000
elf_map: 1M va=fe000000 pa=20100000 sz=00100000
Header size=0x0000009c, Total Size=0x00000508, #Cpu=1, Type=4
Section:system_private offset:0x000001f0 size:0x00000068
  syspage ptr user:fc404000 kernel:fc404000
  cpupage ptr user:fc404808 kernel:fc404808 spacing:84
  kdebug info:00000000 callback:00000000
  boot pgms: idx=0
    0) base paddr:20110000 start addr:fe03d838
  ramsize:00000000 pagesize:00001000
Section:qtime offset:0x00000148 size:0x00000060
  boot:00000000 CPS:00000000005f5e10 rate/scale:160000/-12 intr:1
Section:callout offset:0x000000a0 size:0x00000048
  reboot:fc404680 power:fc40469c
  timer_load:fc4046b0 reload:fc4046d8 value:fc404704
  0) display:fc404724 poll:fc404748 break:fc40476c
  1) display:00000000 poll:00000000 break:00000000
Section:cpuinfo offset:0x000001a8 size:0x00000020
  0) cpu:41069265 flags:40000000 speed:000000c8 cache i/d:1/0 name:53
Section:cacheattr offset:0x000004c8 size:0x00000040
  0) flags:32 size:0020 #lines:0080 control:fc404508 next:255
  1) flags:11 size:0020 #lines:0080 control:fc40455c next:255
Section:meminfo offset:0x00000508 size:0x00000000
Section:asinfo offset:0x00000328 size:0x00000160
  0000) 0000000000000000-00000000ffffffff o:ffff a:0010 p:100 c:00000000 n:21
  0020) 0000000020000000-0000000023ffffff o:0000 a:0017 p:100 c:00000000 n:28
  0040) 0000000000000000-00000000ffffffff o:ffff a:0010 p:100 c:00000000 n:21
  0060) 0000000020000000-0000000023ffffff o:0040 a:0007 p:100 c:00000000 n:32
  0080) 000000002010e108-00000000205a729b o:0000 a:0005 p:100 c:00000000 n:60
  00a0) 0000000020100000-000000002010e107 o:0000 a:0007 p:100 c:00000000 n:68
  00c0) 000000002010e108-00000000205a729b o:0000 a:0007 p:100 c:00000000 n:76
  00e0) 0000000020000000-0000000020007fff o:0020 a:0007 p:100 c:00000000 n:84
  0100) 000000002001085c-00000000200fffff o:0020 a:0007 p:100 c:00000000 n:84
  0120) 00000000205a729c-0000000023dcffff o:0020 a:0007 p:100 c:00000000 n:84
  0140) 0000000023fd0000-0000000023ffffff o:0020 a:0007 p:100 c:00000000 n:84
Section:hwinfo offset:0x000002e0 size:0x00000048
  0) size:3 tag:3 isize:3, iname:0, owner:65535, kids:1
  12) size:3 tag:17 isize:3, iname:9, owner:0, kids:1
  24) size:3 tag:3 isize:3, iname:37, owner:12, kids:1
  36) size:4 tag:46 isize:4, iname:41, owner:24, kids:0
     00 00 00 00
Section:typed_strings offset:0x00000258 size:0x00000028
  off:0 type:5 string:'AT91SAM9RL64'
  off:20 type:2 string:'localhost'
Section:strings offset:0x00000280 size:0x00000060
  [0]'hw' [3]'Group' [9]'unknown' [17]'Bus' [21]'memory' [28]'ram' [32]'1to1'
  [37]'rtc' [41]'NONE' [46]'Device' [53]'arm926' [60]'imagefs' [68]'startup'
  [76]'bootram' [84]'sysram'
Section:intrinfo offset:0x00000488 size:0x00000040
  0) vector_base:00000000, #vectors:32, cascade_vector:7fffffff
     cpu_intr_base:00000000, cpu_intr_stride:0, flags:0000
      id => flags:8000, size:002c, rtn:fc4045c8
     eoi => flags:9000, size:0028, rtn:fc4045f4
     mask:fc40461c, unmask:fc404640, config:00000000
Section:smp offset:0x00000508 size:0x00000000
Section:pminfo offset:0x00000508 size:0x00000000
Section:mdriver offset:0x00000508 size:0x00000000
Section:boxinfo offset:0x000001c8 size:0x00000028
  hw_flags:00000000
Section:cpu offset:0x00000128 size:0x00000020
  page_flush:fc40458c page_flush_deferred:fc4045c4
  upte_ro:00000aae upte_rw:00000ffe
  kpte_ro:0000000e kpte_rw:0000055e
  mask_nc:0000000c
  mmu_cr1:00051078 set:0000317f clr:00000000 -> 0005317f

System page at phys:20010000 user:fc404000 kern:fc404000
Starting next program at vfe03d838
cpu_startnext: cpu0 -> fe03d838
Welcome to QNX Neutrino 6.4 on the Atmel AT91SAM9RL64 Board

You can test the OS simply by executing any shell builtin command or any command residing within the OS image (e.g. ls). 

Summary of driver commands#

The driver command lines below are specific to the Atmel AT91SAM9RL64 board. See the online docs for each driver for additional command-line options and other details.

Note: Some of the following drivers are commented out in the default buildfile. To use the drivers in the target hardware, you'll need to uncomment them in your buildfile, rebuild the image, and load the image into the board.

Startup:#

Command:
    startup-at91sam9xx-at91sam9rl64 -r 0x23dd0000,0x200000,1 -vvvvvvv

Serial:#

Command:
    devc-serusart -F -S -u2 -b115200 -c100000000 0xfffb0000^2,6 
Required binaries:
  • devc-serusart
Command:
    devc-seratdbgu -e -F -S -b115200 -c100000000 0xfffff200,1 
Required binaries:
  • devc-seratdbgu

SPI:#

Command:
    spi-master -d at91sam9xxspi base=0xfffcc000,irq=13 &
Required binaries:
  • spi-master
  • spi-at91sam9xxspi.so

ETFS NAND flash#

Command:
    fs-etfs-at91sam9xx -D addr=0x40000000 -m /fs/etfs
Required binaries:
  • fs-etfs-at91sam9xx
  • etfsctl
Note: For more information about these commands, see the Neutrino Utilities Reference.

Graphics#

Command:
    io-display -dvid=0x0,did=0x0 
Note: To run io-graphics use the following commands:
Photon &
io-graphics
Required binaries:
  • devg-atmel91xx.so
  • libphrender.so
  • libdisputil.so
  • libffb.so
  • libimg.so.1
  • libgf.so.1
Required configuration files:
  • /usr/photon/config/atmel91xx.conf=${PWD}/../src/hardware/devg/atmel91xx/atmel91xx.conf
  • /etc/system/config/display.conf=${PWD}/../src/hardware/devg/atmel91xx/display.conf

About graphics#

This driver currently supports the AT91SAM9RL64 integrated LCD controller . It was developed on the Atmel AT91SAM9RL64 Evaluation Board. This is the GF graphics driver is loaded by io-display.

LCD Displays#

  • By default the driver sets up the Hitachi TX09D71VM1CCA TFT with the AT91SAM9RL64 reference board.
You can use the driver configuration file atmel91xx.conf to other displays.

HW Format QNX Format Notes
8-bit 8-bit 8 bits-per-pixel palette-based
16-bit 15-bit QNX framework format is ARGB1555, but MSB is not actually used because the hardware uses only 15 bits
24-bit 32-bit actually unpacked 24-bit, meaning the upper 8 bits are not used

Reserving Memory / Memory Restrictions#

The Atmel AT91SMA9RL64 is a UMA system (Unified Memory Architecture). This means there is no dedicated video memory in the system. Surfaces displayed by the LCD controller, and rendered by the CPU, reside in system memory
  • To ensure there is enough memory available for graphics, we recommend that memory be reserved at startup by using the -r option to startup.
For example to reserve 2 MB of memory:

startup-at91sam9xx-at91sam9rl64 -r 0x23dd0000,0x200000,1 -vvvvvvv

where 0x23dd0000 is the physical base address of memory, and 0x200000 is the size of memory reserved in bytes.

  • When the graphics driver is started, this physical address and the size of memory are passed to the devg-atmel91xx.so through the following options in the driver configuration file atmel91xx.conf:

vidbase=0x23dd0000,vidsize=0x200000

For a complete list of options available to the driver please see the atmel91xx.conf file.

Attachments:
Image samba-ipl-ifs-img.JPG [AtmelAT91SAM9RL64EKEvaluationBoard/samba-ipl-ifs-img.JPG]
Image samba-ipl-img.JPG [AtmelAT91SAM9RL64EKEvaluationBoard/samba-ipl-img.JPG]
Image samba-ifs-img.JPG [AtmelAT91SAM9RL64EKEvaluationBoard/samba-ifs-img.JPG]
Image ipl-ifs-img.JPG [AtmelAT91SAM9RL64EKEvaluationBoard/ipl-ifs-img.JPG]
Image ipl-img.JPG [AtmelAT91SAM9RL64EKEvaluationBoard/ipl-img.JPG]
Image ifs-img.JPG [AtmelAT91SAM9RL64EKEvaluationBoard/ifs-img.JPG]
Image img2.JPG [AtmelAT91SAM9RL64EKEvaluationBoard/img2.JPG]
Image img1.JPG [AtmelAT91SAM9RL64EKEvaluationBoard/img1.JPG]
Bitmap img1.bmp [AtmelAT91SAM9RL64EKEvaluationBoard/img1.bmp]