source: rtems/c/src/lib/libbsp/arm/gp32/include/bsp.h @ b8051837

4.115
Last change on this file since b8051837 was b8051837, checked in by Joel Sherrill <joel.sherrill@…>, on 01/08/13 at 16:13:46

arm/gp32: Correct compilation error in BSP Idle Thread

Split BSP Idle Thread into separate file to follow convention
used on other BSPs.

Slight reformatting of file header comment block.

  • Property mode set to 100644
File size: 1.7 KB
Line 
1/**
2 *  @file
3 *
4 *  This include file contains definitions related to the GP32 BSP.
5 */
6
7/*
8 *  Copyright (c) Canon Research France SA.]
9 *  Emmanuel Raguet, mailto:raguet@crf.canon.fr
10 *
11 *  The license and distribution terms for this file may be
12 *  found in the file LICENSE in this distribution or at
13 *  http://www.rtems.com/license/LICENSE.
14 */
15
16#ifndef _BSP_H
17#define _BSP_H
18
19#ifdef __cplusplus
20extern "C" {
21#endif
22
23#include <bspopts.h>
24#include <bsp/default-initial-extension.h>
25
26#include <rtems.h>
27#include <rtems/iosupp.h>
28#include <rtems/console.h>
29#include <rtems/clockdrv.h>
30#include <s3c24xx.h>
31
32#define BSP_FEATURE_IRQ_EXTENSION
33
34#define gp32_initButtons() {rPBCON=0x0;}
35#define gp32_getButtons() \
36    ( (((~rPEDAT >> 6) & 0x3 )<<8) | (((~rPBDAT >> 8) & 0xFF)<<0) )
37
38/*functions to get the differents s3c2400 clks*/
39uint32_t get_FCLK(void);
40uint32_t get_HCLK(void);
41uint32_t get_PCLK(void);
42uint32_t get_UCLK(void);
43
44
45void gp32_setPalette( unsigned char pos, uint16_t color);
46
47/* What is the input clock freq in hertz? */
48#define BSP_OSC_FREQ  12000000    /* 12 MHz oscillator */
49#define M_MDIV 81       /* FCLK=133Mhz */
50#define M_PDIV 2
51#define M_SDIV 1
52#define M_CLKDIVN 2     /* HCLK=FCLK/2, PCLK=FCLK/2 */
53
54#define REFEN   0x1     /* enable refresh */
55#define TREFMD  0x0     /* CBR(CAS before RAS)/auto refresh */
56#define Trp     0x0     /* 2 clk */
57#define Trc     0x3     /* 7 clk */
58#define Tchr    0x2     /* 3 clk */
59
60
61/*
62 *  This BSP provides its own IDLE thread to override the RTEMS one.
63 *  So we prototype it and define the constant confdefs.h expects
64 *  to configure a BSP specific one.
65 */
66void *bsp_idle_thread(uintptr_t ignored);
67
68#define BSP_IDLE_TASK_BODY bsp_idle_thread
69
70#ifdef __cplusplus
71}
72#endif
73
74#endif /* _BSP_H */
75
Note: See TracBrowser for help on using the repository browser.