2018-06-10 23:29:03 +02:00
|
|
|
/*
|
|
|
|
* Copyright (C) 2016 Leon George
|
|
|
|
* Copyright (C) 2018 Anton Gerasimov
|
|
|
|
*
|
|
|
|
* This file is subject to the terms and conditions of the GNU Lesser
|
|
|
|
* General Public License v2.1. See the file LICENSE in the top level
|
|
|
|
* directory for more details.
|
|
|
|
*/
|
|
|
|
|
|
|
|
/**
|
2020-01-20 15:31:48 +01:00
|
|
|
* @ingroup cpu_cc26x2_cc13x2
|
2018-06-10 23:29:03 +02:00
|
|
|
* @{
|
|
|
|
*
|
|
|
|
* @file
|
|
|
|
* @brief implementation of the CPU initialization
|
|
|
|
*
|
|
|
|
* @author Leon M. George <leon@georgemail.eu>, Anton Gerasimov <tossel@gmail.com>
|
|
|
|
* @}
|
|
|
|
*/
|
|
|
|
|
|
|
|
#include "cpu.h"
|
2023-01-02 18:08:35 +01:00
|
|
|
#include "kernel_init.h"
|
2018-06-10 23:29:03 +02:00
|
|
|
#include "periph_conf.h"
|
|
|
|
#include "periph/init.h"
|
|
|
|
#include "stdio_base.h"
|
|
|
|
|
2020-01-20 15:31:48 +01:00
|
|
|
#include "cc26x2_cc13x2_prcm.h"
|
2018-06-10 23:29:03 +02:00
|
|
|
|
|
|
|
/**
|
|
|
|
* @brief Initialize the CPU, set IRQ priorities
|
|
|
|
*/
|
|
|
|
void cpu_init(void)
|
|
|
|
{
|
|
|
|
/* initialize the Cortex-M core */
|
|
|
|
cortexm_init();
|
|
|
|
|
2020-04-30 01:11:27 +02:00
|
|
|
/* trim device */
|
|
|
|
setup_trim_device();
|
|
|
|
|
2018-06-10 23:29:03 +02:00
|
|
|
/* initialize stdio prior to periph_init() to allow use of DEBUG() there */
|
2023-01-02 18:08:35 +01:00
|
|
|
early_init();
|
2018-06-10 23:29:03 +02:00
|
|
|
|
|
|
|
/* trigger static peripheral initialization */
|
|
|
|
periph_init();
|
|
|
|
}
|