Skip to content

Commit f11f63d

Browse files
AWAKE signal turned on at system init for SDP-K1 board.
- Setting AWAKE signal high in the SystemInit() to ensure VIO supply to daughter boards through SDP and Arduino connectors.
1 parent 869e48d commit f11f63d

File tree

1 file changed

+28
-2
lines changed
  • targets/TARGET_STM/TARGET_STM32F4/TARGET_STM32F469xI/TARGET_SDP_K1

1 file changed

+28
-2
lines changed

targets/TARGET_STM/TARGET_STM32F4/TARGET_STM32F469xI/TARGET_SDP_K1/system_clock.c

Lines changed: 28 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/* mbed Microcontroller Library
2-
* Copyright (c) 2006-2019 ARM Limited
2+
* Copyright (c) 2006-2017 ARM Limited
33
* SPDX-License-Identifier: Apache-2.0
4-
4+
*
55
* Licensed under the Apache License, Version 2.0 (the "License");
66
* you may not use this file except in compliance with the License.
77
* You may obtain a copy of the License at
@@ -58,6 +58,7 @@ uint8_t SetSysClock_PLL_HSE(uint8_t bypass);
5858
uint8_t SetSysClock_PLL_HSI(void);
5959
#endif /* ((CLOCK_SOURCE) & USE_PLL_HSI) */
6060

61+
static void TurnOnAwakeSignal(void);
6162

6263
/**
6364
* @brief Setup the microcontroller system
@@ -102,6 +103,7 @@ void SystemInit(void)
102103
SCB->VTOR = NVIC_FLASH_VECTOR_ADDRESS; /* Vector Table Relocation in Internal FLASH */
103104
#endif
104105

106+
TurnOnAwakeSignal();
105107
}
106108

107109

@@ -274,3 +276,27 @@ uint8_t SetSysClock_PLL_HSI(void)
274276
return 1; // OK
275277
}
276278
#endif /* ((CLOCK_SOURCE) & USE_PLL_HSI) */
279+
280+
/**
281+
* @brief Sets F469 "Awake" signal (PK3 pin) to turn on daughterboard power supplies
282+
* @param None
283+
* @retval None
284+
*
285+
*/
286+
static void TurnOnAwakeSignal(void)
287+
{
288+
GPIO_InitTypeDef GPIO_InitStruct;
289+
290+
/* Enable peripheral clock */
291+
__HAL_RCC_GPIOK_CLK_ENABLE();
292+
293+
/* GPIO Configuration */
294+
GPIO_InitStruct.Pin = GPIO_PIN_3;
295+
GPIO_InitStruct.Mode = GPIO_MODE_OUTPUT_PP;
296+
GPIO_InitStruct.Pull = GPIO_NOPULL;
297+
GPIO_InitStruct.Speed = GPIO_SPEED_FREQ_LOW;
298+
HAL_GPIO_Init(GPIOK, &GPIO_InitStruct);
299+
300+
/* Enable AWAKE pin */
301+
HAL_GPIO_WritePin(GPIOK, GPIO_PIN_3, GPIO_PIN_SET);
302+
}

0 commit comments

Comments
 (0)