Commit 8ec75a77 authored by Tomasz Wlostowski's avatar Tomasz Wlostowski Committed by Alessandro Rubini

rt: started porting the main PLL (wip)

parent cff3483e
CROSS_COMPILE ?= /opt/gcc-lm32/bin/lm32-elf-
OBJS = main.o dev/uart.o dev/timer.o lib/mprintf.o dev/ad9516.o
OBJS = main.o dev/uart.o dev/timer.o lib/mprintf.o dev/ad9516.o dev/softpll_ng.o
CFLAGS_PLATFORM = -mmultiply-enabled -mbarrel-shift-enabled
LDFLAGS_PLATFORM = -mmultiply-enabled -mbarrel-shift-enabled -nostdlib -T target/lm32/ram.ld
......@@ -9,7 +9,7 @@ OBJS_PLATFORM=target/lm32/crt0.o target/lm32/irq.o
CC=$(CROSS_COMPILE)gcc
OBJCOPY=$(CROSS_COMPILE)objcopy
OBJDUMP=$(CROSS_COMPILE)objdump
CFLAGS= $(CFLAGS_PLATFORM) -ffunction-sections -fdata-sections -Os -Iinclude -include include/trace.h
CFLAGS= $(CFLAGS_PLATFORM) -ffunction-sections -fdata-sections -Os -Iinclude -include include/trace.h -Wall
LDFLAGS= $(LDFLAGS_PLATFORM) -ffunction-sections -fdata-sections -Os -Iinclude
SIZE = $(CROSS_COMPILE)size
OBJS += $(OBJS_PLATFORM)
......@@ -24,6 +24,9 @@ all: $(OBJS)
clean:
rm -f $(OBJS) $(OUTPUT).elf $(OUTPUT).bin $(OUTPUT).ram
scp: all
scp rt_cpu.bin root@pts-test03.cern.ch:/tftpboot/192.168.1.2/root
%.o: %.c
${CC} $(CFLAGS) $(LIB_DIR) -c $^ -o $@
......@@ -2,16 +2,18 @@
#include "uart.h"
#include "timer.h"
void _irq_entry() {};
//void _irq_entry() {};
main()
{
uart_init();
ad9516_init();
spll_test();
for(;;)
{
mprintf("Ping!\n");
mprintf("Ping [lock %d]!\n", spll_check_lock());
timer_delay(TICS_PER_SECOND);
}
}
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment