UART Helper adding, compile issue

This commit is contained in:
paul nehlich 2024-10-01 11:26:02 +02:00
parent b5ce16e3f9
commit 1d438f46ba
3 changed files with 41 additions and 7 deletions

View File

@ -6,6 +6,7 @@
#include "FreeRTOS.h"
#include "semphr.h"
#include "task.h"
#include "uart_rust_helper.h"
void rust_main();
@ -32,7 +33,11 @@ void test_hardware() {
void done();
void init_task(void *) {
// printf("Starting Mission\n");
printf("Starting UART polled Test\n");
uart_polled_test();
printf("Starting Hardware Test\n");
test_hardware();

View File

@ -44,8 +44,14 @@
#include "xparameters.h"
#include "xstatus.h"
#include "xuartlite.h"
#include "xil_printf.h"
#include "xil_types.h"
#include "xil_assert.h"
#include "xstatus.h"
#include "xuartlite.h"
#include "xil_io.h"
#include "xil_printf.h"
#include "uart_rust_helper.h"
/************************** Constant Definitions *****************************/
/*
@ -74,11 +80,6 @@
/************************** Function Prototypes ******************************/
#ifndef SDT
int UartLitePolledExample(u16 DeviceId);
#else
int UartLitePolledExample(UINTPTR BaseAddress);
#endif
/************************** Variable Definitions *****************************/

View File

@ -0,0 +1,28 @@
#ifndef XUARTLITE_HELPER_H /* prevent circular inclusions */
#define XUARTLITE_HELPER_H /* by using protection macros */
#ifdef __cplusplus
extern "C" {
#endif
/***************************** Include Files ********************************/
#include "xil_types.h"
#include "xil_assert.h"
#include "xuartlite.h"
#include "xstatus.h"
int uart_polled_test(void);
#ifndef SDT
int UartLitePolledExample(u16 DeviceId);
#else
int UartLitePolledExample(UINTPTR BaseAddress);
#endif
#ifdef __cplusplus
}
#endif
#endif