#include <common.h>
#include <command.h>
-#include <s3c2400.h>
+#include <asm/arch/s3c24x0_cpu.h>
#include <rtc.h>
/*
extern int i2c_read (uchar, uint, int , uchar* , int);
extern void tsc2000_reg_init (void);
extern s32 tsc2000_contact_temp (void);
-extern void spi_init(void);
+extern void tsc2000_spi_init(void);
/* function declarations */
int do_dip (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[]);
led_init ();
global_vars_init ();
test_function_table_init ();
- spi_init ();
+ tsc2000_spi_init ();
if (global_vars_write_to_eeprom () != 0) {
printf ("%s: error writing global_vars to eeprom\n",
return 1;
}
- spi_init ();
+ tsc2000_spi_init ();
contact_temp = tsc2000_contact_temp();
printf ("%d degree C * 100\n", contact_temp) ;
{
int j = 1000; /* timeout value for wait loop in us */
int result;
- S3C2400_ADC *padc;
+ struct s3c2400_adc *padc;
- padc = S3C2400_GetBase_ADC();
+ padc = s3c2400_get_base_adc();
channel &= 0x7;
adc_init ();
static void adc_init (void)
{
- S3C2400_ADC *padc;
+ struct s3c2400_adc *padc;
- padc = S3C2400_GetBase_ADC();
+ padc = s3c2400_get_base_adc();
padc->ADCCON &= ~(0xff << 6); /* clear prescaler bits */
padc->ADCCON |= ((65 << 6) | ADC_PRSCEN); /* set prescaler */
static void led_set (unsigned int state)
{
- S3C24X0_GPIO * const gpio = S3C24X0_GetBase_GPIO();
+ struct s3c24x0_gpio * const gpio = s3c24x0_get_base_gpio();
led_init ();
static void led_init (void)
{
- S3C24X0_GPIO * const gpio = S3C24X0_GetBase_GPIO();
+ struct s3c24x0_gpio * const gpio = s3c24x0_get_base_gpio();
/* configure GPA12 as output and set to High -> LED off */
gpio->PACON &= ~(1 << 12);
delay = simple_strtoul(argv[1], NULL, 10);
}
- spi_init ();
+ tsc2000_spi_init ();
while (1) {
#if defined(CONFIG_CMD_DATE)