boards: Add Space Cubics OBC Module 1
This is a single board computer for spacecraft OBC (On-board Computer). It has a Xilinx FPGA with Cortex ARM M3 core with peripherals, UART, CAN and others. Signed-off-by: Yasushi SHOJI <yashi@spacecubics.com>
This commit is contained in:
parent
2e3aeaaac8
commit
91970adb75
|
@ -135,6 +135,7 @@
|
|||
/boards/arm/sam4s_xplained/ @fallrisk
|
||||
/boards/arm/sam_e70_xplained/ @nandojve
|
||||
/boards/arm/sam_v71_xult/ @nandojve
|
||||
/boards/arm/scobc_module1/ @yashi
|
||||
/boards/arm/v2m_beetle/ @fvincenzo
|
||||
/boards/arm/olimexino_stm32/ @ydamigos
|
||||
/boards/arm/sensortile_box/ @avisconti
|
||||
|
|
8
boards/arm/scobc_module1/Kconfig.board
Normal file
8
boards/arm/scobc_module1/Kconfig.board
Normal file
|
@ -0,0 +1,8 @@
|
|||
# Space Cubics OBC module 1 configuration
|
||||
|
||||
# Copyright (c) 2021 Space Cubics, LLC. <yashi@spacecubics.com>
|
||||
# SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
config BOARD_SCOBC_MODULE1
|
||||
bool "Space Cubics OBC Module 1"
|
||||
depends on SOC_SERIES_ARM_DESIGNSTART
|
24
boards/arm/scobc_module1/Kconfig.defconfig
Normal file
24
boards/arm/scobc_module1/Kconfig.defconfig
Normal file
|
@ -0,0 +1,24 @@
|
|||
# Space Cubics OBC module 1
|
||||
|
||||
# Copyright (c) 2021 Space Cubics <yashi@spacecubics.com>
|
||||
# SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
if BOARD_SCOBC_MODULE1
|
||||
|
||||
config BOARD
|
||||
default "scobc_module1"
|
||||
|
||||
config CPU_CORTEX_M_HAS_SYSTICK
|
||||
default y
|
||||
|
||||
config CPU_HAS_ARM_MPU
|
||||
default y
|
||||
|
||||
config NUM_IRQS
|
||||
default 7
|
||||
|
||||
config UART_XLNX_UARTLITE
|
||||
depends on SERIAL
|
||||
default y
|
||||
|
||||
endif # BOARD_SCOBC_SPEQ
|
7
boards/arm/scobc_module1/board.cmake
Normal file
7
boards/arm/scobc_module1/board.cmake
Normal file
|
@ -0,0 +1,7 @@
|
|||
# SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
if(CONFIG_BOARD_SCOBC_MODULE1)
|
||||
board_runner_args(openocd "--use-elf" "--config=${BOARD_DIR}/support/openocd-ftdi.cfg")
|
||||
|
||||
include(${ZEPHYR_BASE}/boards/common/openocd.board.cmake)
|
||||
endif()
|
119
boards/arm/scobc_module1/doc/index.rst
Normal file
119
boards/arm/scobc_module1/doc/index.rst
Normal file
|
@ -0,0 +1,119 @@
|
|||
.. _scobc_module1:
|
||||
|
||||
Space Cubics OBC module 1
|
||||
#########################
|
||||
|
||||
Overview
|
||||
********
|
||||
|
||||
`Space Cubics`_ OBC module 1 is a single board computer for spacecraft,
|
||||
especially for 3U CubeSats. The board is based on Xilinx Artix-7 FPGA and
|
||||
implements ARM Cortex M3 as the main CPU.
|
||||
|
||||
.. figure:: ./scobc.jpg
|
||||
:width: 442px
|
||||
:align: center
|
||||
:alt: Space Cubics OBC module 1
|
||||
|
||||
Space Cubics OBC module 1
|
||||
|
||||
It is designed to survive in the severe space environment, extreme temperature,
|
||||
vacuum, and space radiation.
|
||||
|
||||
As the name suggests, the board form factor is a module and requires a base I/O
|
||||
board connected at CON1, a board-to-board connector. This modularity allows
|
||||
CubeSat designers the freedom to connect and expand the capability required for
|
||||
their mission.
|
||||
|
||||
Hardware
|
||||
********
|
||||
|
||||
Supported Features
|
||||
==================
|
||||
|
||||
The Space Cubics OBC module 1 provides the following hardware features:
|
||||
|
||||
+-----------+------------+------------------------------------+
|
||||
| Interface | Controller | Driver/Component |
|
||||
+===========+============+====================================+
|
||||
| NVIC | on-chip | nested vector interrupt controller |
|
||||
+-----------+------------+------------------------------------+
|
||||
| SYSTICK | on-chip | systick |
|
||||
+-----------+------------+------------------------------------+
|
||||
| UART | on-chip | serial port-polling; |
|
||||
| | | serial port-interrupt |
|
||||
+-----------+------------+------------------------------------+
|
||||
|
||||
The default configuration for the board can be found in the defconfig file:
|
||||
:file:`boards/arm/scobc_module1/scobc_module1_defconfig`.
|
||||
|
||||
Other hardware features are not currently supported by the port.
|
||||
|
||||
System Clock
|
||||
============
|
||||
|
||||
The board has two 24 MHz external oscillators connected to the FPGA for
|
||||
redundancy. The FPGA will select an active oscillator as CPU system clock. The
|
||||
selected clock signal is then used by the CMT in the FPGA, and drives the CPU at
|
||||
48 MHz by default.
|
||||
|
||||
Serial Port
|
||||
===========
|
||||
|
||||
The default configuration contains one SC UART IP, which is register compatible
|
||||
with Xilinx UART Lite for basic TX and RX. This UART is configured as the
|
||||
default console and is accessible through the CON1 pin 43 and 45 for Rx and Tx,
|
||||
respectively.
|
||||
|
||||
Programming and Debugging
|
||||
*************************
|
||||
|
||||
Flashing
|
||||
========
|
||||
|
||||
Here is an example for building and flashing the \`hello\_world\`
|
||||
application for the board:
|
||||
|
||||
Here is an example for building and flashing the :ref:`hello_world` application
|
||||
for the default design:
|
||||
|
||||
.. zephyr-app-commands::
|
||||
:zephyr-app: samples/hello_world
|
||||
:board: scobc_module1
|
||||
:goals: flash
|
||||
|
||||
After flashing, you should see message similar to the following in the terminal:
|
||||
|
||||
.. code-block:: console
|
||||
|
||||
*** Booting Zephyr OS build zephyr-v2.7.99 ***
|
||||
Hello World! scobc_module1
|
||||
|
||||
Note, however, that the application was not persisted in flash memory by the
|
||||
above steps. It was merely written to internal RAM in the FPGA.
|
||||
|
||||
Debugging
|
||||
=========
|
||||
|
||||
Here is an example for the :ref:`hello_world` application.
|
||||
|
||||
.. zephyr-app-commands::
|
||||
:zephyr-app: samples/hello_world
|
||||
:board: scobc_module1
|
||||
:goals: debug
|
||||
|
||||
Step through the application in your debugger, and you should see a message
|
||||
similar to the following in the terminal:
|
||||
|
||||
.. code-block:: console
|
||||
|
||||
*** Booting Zephyr OS build zephyr-v2.7.99 ***
|
||||
Hello World! scobc_module1
|
||||
|
||||
References
|
||||
**********
|
||||
|
||||
.. target-notes::
|
||||
|
||||
.. _Space Cubics:
|
||||
https://spacecubics.com/
|
BIN
boards/arm/scobc_module1/doc/scobc.jpg
Normal file
BIN
boards/arm/scobc_module1/doc/scobc.jpg
Normal file
Binary file not shown.
After Width: | Height: | Size: 595 KiB |
11
boards/arm/scobc_module1/dts/bindings/sc,hrmem.yaml
Normal file
11
boards/arm/scobc_module1/dts/bindings/sc,hrmem.yaml
Normal file
|
@ -0,0 +1,11 @@
|
|||
# SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
description: Space Cubics HRMEM (High-reliability Memory)
|
||||
|
||||
compatible: "sc,hrmem"
|
||||
|
||||
include: base.yaml
|
||||
|
||||
properties:
|
||||
reg:
|
||||
required: true
|
56
boards/arm/scobc_module1/scobc_module1.dts
Normal file
56
boards/arm/scobc_module1/scobc_module1.dts
Normal file
|
@ -0,0 +1,56 @@
|
|||
/*
|
||||
* Copyright (c) 2021 Space Cubics, LLC. <yashi@spacecubics.com>
|
||||
*
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
/dts-v1/;
|
||||
#include <arm/armv7-m.dtsi>
|
||||
#include <mem.h>
|
||||
|
||||
/ {
|
||||
model = "Space Cubics OBC module 1";
|
||||
|
||||
chosen {
|
||||
zephyr,console = &uartlite0;
|
||||
zephyr,shell-uart = &uartlite0;
|
||||
zephyr,sram = &hrmem;
|
||||
};
|
||||
|
||||
cpus {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
cpu0: cpu@0 {
|
||||
device_type = "cpu";
|
||||
compatible = "arm,cortex-m3";
|
||||
reg = <0>;
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
|
||||
mpu: mpu@e000ed90 {
|
||||
compatible = "arm,armv7m-mpu";
|
||||
reg = <0xe000ed90 0x40>;
|
||||
arm,num-mpu-regions = <8>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
soc {
|
||||
hrmem: memory@0 {
|
||||
compatible = "sc,hrmem";
|
||||
reg = <0x00000000 DT_SIZE_K(128)>;
|
||||
};
|
||||
|
||||
uartlite0: uartlite@50010000 {
|
||||
compatible = "xlnx,xps-uartlite-1.00.a";
|
||||
interrupts = <0 0>;
|
||||
reg = <0x50010000 0x10000>;
|
||||
label = "UART_0";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&nvic {
|
||||
arm,num-irq-priority-bits = <3>;
|
||||
};
|
8
boards/arm/scobc_module1/scobc_module1.yaml
Normal file
8
boards/arm/scobc_module1/scobc_module1.yaml
Normal file
|
@ -0,0 +1,8 @@
|
|||
identifier: scobc_module1
|
||||
name: Space Cubics OBC module 1
|
||||
type: mcu
|
||||
arch: arm
|
||||
toolchain:
|
||||
- zephyr
|
||||
supported:
|
||||
- uart
|
18
boards/arm/scobc_module1/scobc_module1_defconfig
Normal file
18
boards/arm/scobc_module1/scobc_module1_defconfig
Normal file
|
@ -0,0 +1,18 @@
|
|||
# SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
CONFIG_CORTEX_M_SYSTICK=y
|
||||
CONFIG_SOC_SERIES_ARM_DESIGNSTART=y
|
||||
CONFIG_SOC_ARM_DESIGNSTART_FPGA_CORTEX_M3=y
|
||||
CONFIG_BOARD_SCOBC_MODULE1=y
|
||||
CONFIG_SYS_CLOCK_HW_CYCLES_PER_SEC=48000000
|
||||
CONFIG_ARM_MPU=n
|
||||
|
||||
CONFIG_SERIAL=y
|
||||
CONFIG_UART_INTERRUPT_DRIVEN=y
|
||||
CONFIG_CONSOLE=y
|
||||
CONFIG_UART_CONSOLE=y
|
||||
|
||||
CONFIG_XIP=n
|
||||
CONFIG_FLASH_SIZE=0
|
||||
CONFIG_FLASH_BASE_ADDRESS=0x0
|
||||
CONFIG_BOOTLOADER_SRAM_SIZE=0
|
12
boards/arm/scobc_module1/support/akizuki-m-02990.cfg
Normal file
12
boards/arm/scobc_module1/support/akizuki-m-02990.cfg
Normal file
|
@ -0,0 +1,12 @@
|
|||
#
|
||||
# Akizuki Denshi FT2232D Module (M-02990)
|
||||
#
|
||||
# https://akizukidenshi.com/catalog/g/gM-02990/
|
||||
#
|
||||
|
||||
adapter driver ftdi
|
||||
ftdi_device_desc "Dual RS232"
|
||||
ftdi_vid_pid 0x0403 0x6010
|
||||
|
||||
# Every pin set as high impedance except TCK, TDI, TDO and TMS
|
||||
ftdi_layout_init 0x0008 0x000b
|
2
boards/arm/scobc_module1/support/openocd-ft232r.cfg
Normal file
2
boards/arm/scobc_module1/support/openocd-ft232r.cfg
Normal file
|
@ -0,0 +1,2 @@
|
|||
source [find interface/ft232r.cfg]
|
||||
source [find scobc-module1.cfg]
|
3
boards/arm/scobc_module1/support/openocd-ftdi.cfg
Normal file
3
boards/arm/scobc_module1/support/openocd-ftdi.cfg
Normal file
|
@ -0,0 +1,3 @@
|
|||
source [find akizuki-m-02990.cfg]
|
||||
adapter speed 2000
|
||||
source [find scobc-module1.cfg]
|
21
boards/arm/scobc_module1/support/openocd.cfg
Normal file
21
boards/arm/scobc_module1/support/openocd.cfg
Normal file
|
@ -0,0 +1,21 @@
|
|||
source [find interface/cmsis-dap.cfg]
|
||||
transport select swd
|
||||
source [find target/swj-dp.tcl]
|
||||
|
||||
adapter speed 5000
|
||||
|
||||
set _CHIPNAME cortex_m3
|
||||
set _ENDIAN little
|
||||
set _WORKAREASIZE 0x4000
|
||||
set _CPUTAPID 0x412FC231
|
||||
|
||||
swj_newdap $_CHIPNAME cpu -expected-id $_CPUTAPID
|
||||
dap create $_CHIPNAME.dap -chain-position $_CHIPNAME.cpu
|
||||
|
||||
set _TARGETNAME $_CHIPNAME.cpu
|
||||
target create $_TARGETNAME cortex_m -dap $_CHIPNAME.dap
|
||||
$_TARGETNAME configure -work-area-phys 0x20000000 -work-area-size $_WORKAREASIZE -work-area-backup 0
|
||||
|
||||
if {![using_hla]} {
|
||||
cortex_m reset_config sysresetreq
|
||||
}
|
31
boards/arm/scobc_module1/support/scobc-module1.cfg
Normal file
31
boards/arm/scobc_module1/support/scobc-module1.cfg
Normal file
|
@ -0,0 +1,31 @@
|
|||
# Copyright (C) 2021 Space Cubics, LLC.
|
||||
# Yasushi SHOJI <yashi@spacecubics.com>
|
||||
|
||||
if { [info exists CHIPNAME] } {
|
||||
set _CHIPNAME $CHIPNAME
|
||||
} else {
|
||||
set _CHIPNAME cortex_m3
|
||||
}
|
||||
|
||||
if { [info exists CPUTAPID ] } {
|
||||
set _CPUTAPID $CPUTAPID
|
||||
} else {
|
||||
set _CPUTAPID 0x4ba00477
|
||||
}
|
||||
|
||||
if { [info exists WORKAREASIZE] } {
|
||||
set _WORKAREASIZE $WORKAREASIZE
|
||||
} else {
|
||||
set _WORKAREASIZE 0x4000
|
||||
}
|
||||
|
||||
jtag newtap $_CHIPNAME cpu -irlen 4 -ircapture 0x1 -irmask 0xf -expected-id $_CPUTAPID
|
||||
dap create $_CHIPNAME.dap -chain-position $_CHIPNAME.cpu
|
||||
|
||||
set _TARGETNAME $_CHIPNAME.cpu
|
||||
target create $_TARGETNAME cortex_m -dap $_CHIPNAME.dap
|
||||
$_TARGETNAME configure -work-area-phys 0x20000000 -work-area-size $_WORKAREASIZE -work-area-backup 0
|
||||
|
||||
if {![using_hla]} {
|
||||
cortex_m reset_config sysresetreq
|
||||
}
|
Loading…
Reference in a new issue