Skip to content

Commit

Permalink
재수정 라이파이
Browse files Browse the repository at this point in the history
  • Loading branch information
ksmabcd135 committed Apr 23, 2019
1 parent 4e54e79 commit 017fe20
Showing 1 changed file with 27 additions and 1 deletion.
28 changes: 27 additions & 1 deletion Src/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,10 @@

void SystemClock_Config(void);

//LI-FI data
uint8_t rx3_data;
uint8_t tx_data[5]="hello";

int main(void)
{
int tag;
Expand All @@ -63,9 +67,19 @@ int main(void)

integ_mac_init();


printf("$ ");
while(1) {


/////////////LI-FI//////////////////////////
//send "HELLO from huart5 to huart3"
/*
HAL_UART_Transmit(&huart5,tx_data,5,1000);
HAL_Delay(1000);
*/
//////////////Li-FI/////////////////////////

__disable_interrupt();
tag = task_delete(&task);
__enable_interrupt();
Expand All @@ -79,6 +93,18 @@ int main(void)
* @brief System Clock Configuration
* @retval None
*/

//LI-FI callback function
/*
void HAL_UART_RxCpltCallback(UART_HandleTypeDef *huart)
{
if(huart->Instance ==USART3)
{
HAL_UART_Receive_IT(&huart3,&rx3_data,5);
HAL_UART_Transmit(&huart3,&rx3_data,5,10);
}
}
*/
void SystemClock_Config(void)
{
RCC_OscInitTypeDef RCC_OscInitStruct = {0};
Expand Down

0 comments on commit 017fe20

Please sign in to comment.