SBC8600B User Manual


Add to my manuals
127 Pages

advertisement

SBC8600B User Manual | Manualzz

Embest Technology Co., Ltd 73

Booting from dvsdk ... reading uImage

3175384 bytes read

## Booting kernel from Legacy Image at 80007fc0 ...

Image Name: Linux-3.2.0

Image Type: ARM Linux Kernel Image (uncompressed)

Data Size: 3175320 Bytes = 3 MiB

Load Address: 80008000

Entry Point: 80008000

Verifying Checksum ... OK

XIP Kernel Image ... OK

OK

Starting kernel ...

…… //Omitted part

Arago Project http://arago-project.org am335x-evm ttyO0

Arago 2011.09 am335x-evm ttyO0 am335x-evm login: root //Type root to log in

4) TISDK file system is featured with some applications running on QT which allow users find and run example programs easily through a friendly graphic interface.

5) U-boot configuration

The system image supports 4.3-inch display by default. If you are working with a display of other size, you need to modify the parameters in UBOOT. Please refer to 3.8.1 Selecting Display Mode for details.

3.9 The Development of Applications

This section mainly introduces the development of application programs, and illustrates the general process of application programs development through examples.

Development example of LED application program

1) Composing Source Code

Copyright © 2012 Embest Technology SBC8600B User Manual

Embest Technology Co., Ltd 74

The following sentences are led_acc.c source code: control the three LEDs on the development board to flash in a way of accumulator.

}

#include <stdio.h>

#include <unistd.h>

#include <sys/types.h>

#include <sys/ipc.h>

#include <sys/ioctl.h>

#include <fcntl.h>

#define LED1 "/sys/class/leds/sys_led/brightness"

#define LED2 "/sys/class/leds/user_led/brightness" int main(int argc, char *argv[])

{ int f_led1, f_led2; unsigned char i = 0; unsigned char dat1, dat2; if((f_led1 = open(LED1, O_RDWR)) < 0){ printf("error in open %s",LED1); return -1;

}

} if((f_led2 = open(LED2, O_RDWR)) < 0){ printf("error in open %s",LED2); return -1;

} for(;;){ i++; dat1 = i&0x1 ? '1':'0'; dat2 = (i&0x2)>>1 ? '1':'0'; write(f_led1, &dat1, sizeof(dat1)); write(f_led2, &dat2, sizeof(dat2)); usleep(300000);

2) Cross compiling

arm-none-linux-gnueabi-gcc led_acc.c -o led_acc

3) Downloading and running

Copyright © 2012 Embest Technology SBC8600B User Manual

Embest Technology Co., Ltd 75

Downloading to the development board system through TF card, USB flash disk or network and enter the directory where the led_acc file is saved, and then execute the following instructions to run led_acc in the background.

./led_acc &

Copyright © 2012 Embest Technology SBC8600B User Manual

advertisement

Was this manual useful for you? Yes No
Thank you for your participation!

* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project

Related manuals