* clear library variants: there is single library for a family (F4) now
This commit is contained in:
parent
ba399f3912
commit
5a7e565ed4
4
Makefile
4
Makefile
|
@ -1,8 +1,8 @@
|
|||
.PHONY: all
|
||||
|
||||
CHIP = 407z 429z
|
||||
CHIP = f4
|
||||
|
||||
LIBRARY_TARGET = $(CHIP:%=stm32f%_library)
|
||||
LIBRARY_TARGET = $(CHIP:%=stm32%_library)
|
||||
|
||||
all: $(LIBRARY_TARGET)
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
with STM32.GPIO; use STM32.GPIO;
|
||||
with STM32.GPIO.Units; use STM32.GPIO.Units;
|
||||
with STM32.GPIO; use STM32.GPIO;
|
||||
with Chip.Units; use Chip.Units;
|
||||
|
||||
package Board is
|
||||
pragma Preelaborate;
|
||||
|
|
|
@ -0,0 +1,3 @@
|
|||
with STM32.F407;
|
||||
|
||||
package Chip renames STM32.F407;
|
|
@ -1,4 +1,4 @@
|
|||
with "../../stm32f407z_library.gpr";
|
||||
with "../../stm32f4_library.gpr";
|
||||
|
||||
project LED_Flasher is
|
||||
for Languages use("Ada");
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
with "../../stm32f429z_library.gpr";
|
||||
with "../../stm32f4_library.gpr";
|
||||
|
||||
project LED_Flasher_429disco is
|
||||
for Languages use("Ada");
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
with "../../stm32f429z_library.gpr";
|
||||
with "../../stm32f4_library.gpr";
|
||||
|
||||
project UART_429disco is
|
||||
for Languages use("Ada");
|
||||
|
|
|
@ -0,0 +1,70 @@
|
|||
with System;
|
||||
with STM32.Address_Map;
|
||||
with STM32.GPIO;
|
||||
with STM32.RCC;
|
||||
with STM32.PWR;
|
||||
with STM32.SYSCFG;
|
||||
with STM32.USART;
|
||||
|
||||
package STM32.F407.Units is
|
||||
pragma Preelaborate;
|
||||
|
||||
GPIOA: STM32.GPIO.GPIO_Registers
|
||||
with Volatile, Import, Address => System'To_Address(Address_Map.GPIOA);
|
||||
|
||||
GPIOB: STM32.GPIO.GPIO_Registers
|
||||
with Volatile, Import, Address => System'To_Address(Address_Map.GPIOB);
|
||||
|
||||
GPIOC: STM32.GPIO.GPIO_Registers
|
||||
with Volatile, Import, Address => System'To_Address(Address_Map.GPIOC);
|
||||
|
||||
GPIOD: STM32.GPIO.GPIO_Registers
|
||||
with Volatile, Import, Address => System'To_Address(Address_Map.GPIOD);
|
||||
|
||||
GPIOE: STM32.GPIO.GPIO_Registers
|
||||
with Volatile, Import, Address => System'To_Address(Address_Map.GPIOE);
|
||||
|
||||
GPIOF: STM32.GPIO.GPIO_Registers
|
||||
with Volatile, Import, Address => System'To_Address(Address_Map.GPIOF);
|
||||
|
||||
GPIOG: STM32.GPIO.GPIO_Registers
|
||||
with Volatile, Import, Address => System'To_Address(Address_Map.GPIOG);
|
||||
|
||||
GPIOH: STM32.GPIO.GPIO_Registers
|
||||
with Volatile, Import, Address => System'To_Address(Address_Map.GPIOH);
|
||||
|
||||
GPIOI: STM32.GPIO.GPIO_Registers
|
||||
with Volatile, Import, Address => System'To_Address(Address_Map.GPIOI);
|
||||
|
||||
---
|
||||
|
||||
RCC : STM32.RCC.RCC_Registers
|
||||
with Volatile, Import, Address => System'To_Address (STM32.Address_Map.RCC);
|
||||
|
||||
PWR : STM32.PWR.PWR_Registers
|
||||
with Volatile, Import, Address => System'To_Address(STM32.Address_Map.PWR);
|
||||
|
||||
SYSCFG : STM32.SYSCFG.SYSCFG_Registers
|
||||
with Volatile, Import, Address => System'To_Address (STM32.Address_Map.SYSCFG);
|
||||
|
||||
---
|
||||
|
||||
USART1: STM32.USART.USART_Registers
|
||||
with Volatile, Import, Address => System'To_Address(Address_Map.USART1);
|
||||
|
||||
USART2: STM32.USART.USART_Registers
|
||||
with Volatile, Import, Address => System'To_Address(Address_Map.USART2);
|
||||
|
||||
USART3: STM32.USART.USART_Registers
|
||||
with Volatile, Import, Address => System'To_Address(Address_Map.USART3);
|
||||
|
||||
UART4: STM32.USART.USART_Registers
|
||||
with Volatile, Import, Address => System'To_Address(Address_Map.UART4);
|
||||
|
||||
UART5: STM32.USART.USART_Registers
|
||||
with Volatile, Import, Address => System'To_Address(Address_Map.UART5);
|
||||
|
||||
USART6: STM32.USART.USART_Registers
|
||||
with Volatile, Import, Address => System'To_Address(Address_Map.USART6);
|
||||
|
||||
end STM32.F407.Units;
|
|
@ -0,0 +1,4 @@
|
|||
package STM32.F407 is
|
||||
pragma Pure;
|
||||
|
||||
end STM32.F407;
|
|
@ -1,17 +0,0 @@
|
|||
project STM32_Library is
|
||||
for Source_Dirs use ("source");
|
||||
for Object_Dir use "objects";
|
||||
for Library_Dir use "library";
|
||||
for Library_Name use "stm32";
|
||||
for Library_Kind use "static";
|
||||
--for Library_Interface use ("STM32", "STM32.STM32F407Z");
|
||||
for Target use "arm-eabi";
|
||||
for Runtime("ada") use "zfp-stm32f4";
|
||||
package Builder is
|
||||
for Default_Switches("Ada") use (
|
||||
"-gnato",
|
||||
"-O2",
|
||||
"-gnatW8"
|
||||
);
|
||||
end Builder;
|
||||
end STM32_Library;
|
|
@ -1,16 +0,0 @@
|
|||
project STM32F407Z_Library is
|
||||
for Source_Dirs use ("source", "source/f4", "source/f4/07z");
|
||||
for Object_Dir use "objects/f407z";
|
||||
for Library_Dir use "library/f407z";
|
||||
for Library_Name use "stm32f407z";
|
||||
for Library_Kind use "static";
|
||||
for Target use "arm-elf";
|
||||
for Runtime("ada") use "zfp-stm32f4";
|
||||
package Builder is
|
||||
for Default_Switches("Ada") use (
|
||||
"-gnato",
|
||||
"-O2",
|
||||
"-gnatW8"
|
||||
);
|
||||
end Builder;
|
||||
end STM32F407Z_Library;
|
|
@ -1,17 +0,0 @@
|
|||
project STM32F429Z_Library is
|
||||
for Source_Dirs use ("source", "source/f4", "source/f4/29z");
|
||||
for Object_Dir use "objects/f429z";
|
||||
for Library_Dir use "library/f429z";
|
||||
for Library_Name use "stm32f429z";
|
||||
for Library_Kind use "static";
|
||||
--for Library_Interface use ("STM32", "STM32.STM32F429Z");
|
||||
for Target use "arm-elf";
|
||||
for Runtime("ada") use "zfp-stm32f4";
|
||||
package Builder is
|
||||
for Default_Switches("Ada") use (
|
||||
"-gnato",
|
||||
"-O2",
|
||||
"-gnatW8"
|
||||
);
|
||||
end Builder;
|
||||
end STM32F429Z_Library;
|
|
@ -0,0 +1,16 @@
|
|||
project STM32F4_Library is
|
||||
for Source_Dirs use ("source", "source/f4");
|
||||
for Object_Dir use "objects/f4";
|
||||
for Library_Dir use "library/f4";
|
||||
for Library_Name use "stm32f4";
|
||||
for Library_Kind use "static";
|
||||
for Target use "arm-elf";
|
||||
for Runtime("ada") use "zfp-stm32f4";
|
||||
package Builder is
|
||||
for Default_Switches("Ada") use (
|
||||
"-gnato",
|
||||
"-O2",
|
||||
"-gnatW8"
|
||||
);
|
||||
end Builder;
|
||||
end STM32F4_Library;
|
Loading…
Reference in New Issue