Add files to designer code + LL drivers
Hello,
I am trying to add serial communication to the designer generated gui code. I used the blank template from TouchGFX designer for STM32F469I-disco board. Gui works fine, but I cannot manage to add my own code to it. I guess I need to edit the target/gcc/Makefile and add the files to specific locations, but I cannot find any information to where/how.
Files:
serial.c/serial.h // serial implementation that uses LL drivers and FreeRTOS
/* Snippet from serial.h */
#include "FreeRTOS.h"
#include "task.h"
#include "queue.h"
#include "semphr.h"
#include "stm32f4xx.h"
#include "stm32f4xx_ll_rcc.h"
#include "stm32f4xx_ll_bus.h"
#include "stm32f4xx_ll_cortex.h"
#include "stm32f4xx_ll_dma.h"
#include "stm32f4xx_ll_gpio.h"
#include "stm32f4xx_ll_usart.h"
#include <string.h>FreeRTOS files are already included in the generated code by TouchGFX designer. I need to add LL drivers and serial.c/.h to the project.
- I already tried just copying files to target/ and including the serial.h to main.cpp but I got bunch of compile errors. It seems that every ll*.c file needs a make rule.
- I also tried to copy the used ll_*_.h&.c files to the STM32F4xx_HAL_Driver include and source directories. Then editted the Makefile under board_c_files to add the ll*.c files like others. It seems that defines for all registers from stm32f4xx.h and stm32f469.h do not get included, because i got bunch of error: undeclared that point to registers.
- I tried adding all files to target/serial and editting Makefile. Added target/serial to include_paths and source_paths but still with lots of compile errors.
Whole day i kept trying different things but to no success. I hope someone can help!
