You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
22 lines
479 B
22 lines
479 B
#include <stdbool.h>
|
|
#include <stdint.h>
|
|
#include <stdio.h>
|
|
#include <string.h>
|
|
#include "main.h"
|
|
#include "usart.h"
|
|
|
|
#define READ_CMD 0x80
|
|
#define SPI_TIMEOUT_VALUE 1000
|
|
#define SPI_CS_Enable() HAL_GPIO_WritePin(SPI_SEL_GPIO_Port, SPI_SEL_Pin, GPIO_PIN_RESET)
|
|
#define SPI_CS_Disable() HAL_GPIO_WritePin(SPI_SEL_GPIO_Port, SPI_SEL_Pin, GPIO_PIN_SET)
|
|
|
|
void user_main()
|
|
{
|
|
uint8_t temp;
|
|
|
|
while (1)
|
|
{
|
|
// HAL_UART_Transmit(&huart1, &temp, 1, 100);
|
|
HAL_Delay(100);
|
|
}
|
|
}
|