Posiadam już szczątkowe programy typu komunikacja po serialu z użyciem usb otg, kręcenie krokowcami.
Teraz trochę pobawiłem się klipperem i zrozumiałem jego działanie więc postanowiłem ruszyć dalej z tym.
Pinologię, zegary i całą resztę generuję w STM32CubeMX i jeśli mam generowanie do makefile to plik wygląda tak:
Kod: Zaznacz cały
################################################################################
# Automatically-generated file. Do not edit!
################################################################################
-include ../makefile.init
RM := rm -rf
# All of the sources participating in the build are defined here
-include sources.mk
-include startup/subdir.mk
-include Src/subdir.mk
-include Middlewares/ST/STM32_USB_Device_Library/Core/Src/subdir.mk
-include Middlewares/ST/STM32_USB_Device_Library/Class/CDC/Src/subdir.mk
-include Drivers/STM32H7xx_HAL_Driver/Src/subdir.mk
-include subdir.mk
-include objects.mk
ifneq ($(MAKECMDGOALS),clean)
ifneq ($(strip $(S_UPPER_DEPS)),)
-include $(S_UPPER_DEPS)
endif
ifneq ($(strip $(C_DEPS)),)
-include $(C_DEPS)
endif
endif
-include ../makefile.defs
# Add inputs and outputs from these tool invocations to the build variables
# All Target
all: klipper-client.elf
# Tool invocations
klipper-client.elf: $(OBJS) $(USER_OBJS) ../STM32H743ZITx_FLASH.ld
@echo 'Building target: $@'
@echo 'Invoking: MCU GCC Linker'
arm-none-eabi-gcc -mcpu=cortex-m7 -mthumb -mfloat-abi=hard -mfpu=fpv5-d16 -specs=nosys.specs -specs=nano.specs -T"../STM32H743ZITx_FLASH.ld" -Wl,-Map=output.map -Wl,--gc-sections -o "klipper-client.elf" @"objects.list" $(USER_OBJS) $(LIBS) -lm
@echo 'Finished building target: $@'
@echo ' '
$(MAKE) --no-print-directory post-build
# Other Targets
clean:
-$(RM) *
-@echo ' '
post-build:
-@echo 'Generating hex and Printing size information:'
arm-none-eabi-objcopy -O ihex "klipper-client.elf" "klipper-client.hex"
arm-none-eabi-size "klipper-client.elf"
-@echo ' '
.PHONY: all clean dependents
.SECONDARY: post-build
-include ../makefile.targets
Wszystkie pliki *.mk sprawdzałem i każdy ma klauzulę że generowany automatycznie i żeby nie edytować.
Projekt będzie jeszcze modyfikowany w CubeMX więc zapewne ponadpisuje mi te pliki.