Skip to content

[NUCLEO_F401RE] Fix compilation error with error.h include file #220

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Mar 19, 2014
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,6 @@
*/

#include "stm32f4xx_hal.h"
#include "error.h" /* [ADDED FOR MBED] */

/**
* @}
Expand Down Expand Up @@ -292,7 +291,11 @@ void SystemClock_Config(void)
RCC_OscInitStruct.PLL.PLLQ = 7;
if (HAL_RCC_OscConfig(&RCC_OscInitStruct) != HAL_OK)
{
error("System clock initialization failed.");
// System clock initialization failed
while(1)
{
// [TODO] Put something here to tell the user that a problem occured...
}
}

/* Select PLL as system clock source and configure the HCLK, PCLK1 and PCLK2 clocks dividers */
Expand All @@ -303,7 +306,11 @@ void SystemClock_Config(void)
RCC_ClkInitStruct.APB2CLKDivider = RCC_HCLK_DIV1; // 84 MHz (SPI1 clock...)
if (HAL_RCC_ClockConfig(&RCC_ClkInitStruct, FLASH_LATENCY_2) != HAL_OK)
{
error("System clock initialization failed.");
// System clock initialization failed
while(1)
{
// [TODO] Put something here to tell the user that a problem occured...
}
}

/* Update the SystemCoreClock variable
Expand Down
1 change: 1 addition & 0 deletions workspace_tools/build_release.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@
('NUCLEO_L152RE', ('ARM', 'uARM')),
('NUCLEO_F401RE', ('ARM', 'uARM')),
('NUCLEO_F030R8', ('ARM', 'uARM')),
('NUCLEO_F302R8', ('ARM', 'uARM')),

('NRF51822', ('ARM', )),
)
Expand Down
2 changes: 2 additions & 0 deletions workspace_tools/export/uvision4.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ class Uvision4(Exporter):
'NUCLEO_L152RE',
'NUCLEO_F030R8',
'NUCLEO_F401RE',
'NUCLEO_F302R8',
'UBLOX_C027',
'LPC1549',
'LPC11U35_501',
Expand All @@ -52,6 +53,7 @@ class Uvision4(Exporter):
'NUCLEO_L152RE',
'NUCLEO_F030R8',
'NUCLEO_F401RE',
'NUCLEO_F302R8',
'LPC1549',
'LPC11U35_501',
]
Expand Down
2 changes: 1 addition & 1 deletion workspace_tools/export_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ def test_export(toolchain, target, expected_error=None):

for toolchain, target in [
('uvision', 'LPC1768'), ('uvision', 'LPC11U24'), ('uvision', 'KL25Z'), ('uvision', 'LPC1347'), ('uvision', 'LPC1114'), ('uvision', 'LPC4088'),
('uvision', 'NUCLEO_F103RB'), ('uvision', 'NUCLEO_L152RE'), ('uvision', 'NUCLEO_F401RE'), ('uvision', 'NUCLEO_F030R8'),
('uvision', 'NUCLEO_F103RB'), ('uvision', 'NUCLEO_L152RE'), ('uvision', 'NUCLEO_F401RE'), ('uvision', 'NUCLEO_F030R8'), ('uvision', 'NUCLEO_F302R8'),

('codered', 'LPC1768'), ('codered', 'LPC4088'),('codered', 'LPC1114'),
('codered', 'LPC11U35_401'),
Expand Down
15 changes: 15 additions & 0 deletions workspace_tools/targets.py
Original file line number Diff line number Diff line change
Expand Up @@ -329,6 +329,20 @@ def __init__(self):
self.supported_toolchains = ["ARM", "uARM"]


class NUCLEO_F302R8(Target):
ONLINE_TOOLCHAIN = "uARM"
OUTPUT_NAMING = "8.3"

def __init__(self):
Target.__init__(self)

self.core = "Cortex-M3"

self.extra_labels = ['STM', 'STM32F3', 'STM32F302R8']

self.supported_toolchains = ["ARM", "uARM"]


class LPC1347(Target):
def __init__(self):
Target.__init__(self)
Expand Down Expand Up @@ -474,6 +488,7 @@ def __init__(self):
NUCLEO_L152RE(),
NUCLEO_F401RE(),
NUCLEO_F030R8(),
NUCLEO_F302R8(),
LPC1347(),
LPC1114(),
LPC11C24(),
Expand Down