Skip to content
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

[WIP Do not merge] NXP i.MXRT port of PX4 FMUv5 #11351

Closed
wants to merge 12 commits into from
Closed
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
1 change: 1 addition & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -253,6 +253,7 @@ px4fmu_firmware: \

misc_qgc_extra_firmware: \
check_nxp_fmuk66-v3_default \
check_nxp_fmurt1062-v1_default \
check_intel_aerofc-v1_default \
check_auav_x21_default \
check_bitcraze_crazyflie_default \
Expand Down
2 changes: 1 addition & 1 deletion boards/nxp/fmuk66-v3/src/board_config.h
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ __BEGIN_DECLS

/* these headers are not C++ safe */
#include <kinetis.h>
#include <chip/kinetis_pinmux.h>
#include <hardware/kinetis_pinmux.h>
#include <arch/board/board.h>

/* FMUK66 GPIOs ***********************************************************************************/
Expand Down
2 changes: 1 addition & 1 deletion boards/nxp/fmuk66-v3/src/init.c
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@

#include <kinetis.h>
#include <kinetis_uart.h>
#include <chip/kinetis_uart.h>
#include <hardware/kinetis_uart.h>
#include "board_config.h"

#include "up_arch.h"
Expand Down
4 changes: 2 additions & 2 deletions boards/nxp/fmuk66-v3/src/timer_config.c
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@
#include <stdint.h>

#include <kinetis.h>
#include "chip/kinetis_sim.h"
#include "chip/kinetis_ftm.h"
#include "hardware/kinetis_sim.h"
#include "hardware/kinetis_ftm.h"

#include <drivers/drv_pwm_output.h>
#include <drivers/kinetis/drv_io_timer.h>
Expand Down
131 changes: 131 additions & 0 deletions boards/nxp/fmurt1062-v1/default.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,131 @@

px4_add_board(
PLATFORM nuttx
VENDOR nxp
MODEL fmurt1062-v1
TOOLCHAIN arm-none-eabi
ARCHITECTURE cortex-m7
ROMFSROOT px4fmu_common
TESTING
# UAVCAN_INTERFACES 2

SERIAL_PORTS
# GPS1:/dev/ttyS0
# TEL1:/dev/ttyS1
# TEL2:/dev/ttyS2
# GPS2:/dev/ttyS3
# ON EVK
GPS1:/dev/ttyS1
TEL2:/dev/ttyS2

DRIVERS
barometer # all available barometer drivers
batt_smbus
# camera_capture Not portable!
camera_trigger
differential_pressure # all available differential pressure drivers
distance_sensor # all available distance sensor drivers
gps
#heater
#heater
imu/adis16448
imu/adis16497
#imu # all available imu drivers
imu/bma180
imu/bmi055
imu/bmi160
imu/mpu6000
imu/mpu9250
irlock
imxrt
imxrt/adc
imxrt/tone_alarm
lights/blinkm
lights/oreoled
lights/pca8574
lights/rgbled
lights/rgbled_ncp5623c
lights/rgbled_pwm
magnetometer # all available magnetometer drivers
mkblctrl
pca9685
optical_flow
power_monitor/ina226
#protocol_splitter
#pwm_input # NOT Portable YET drivers
pwm_out_sim
px4fmu
rc_input
roboclaw
tap_esc
telemetry # all available telemetry drivers
#test_ppm # NOT Portable YET
tone_alarm

MODULES
attitude_estimator_q
camera_feedback
commander
dataman
ekf2
events
fw_att_control
fw_pos_control_l1
rover_pos_control
land_detector
landing_target_estimator
load_mon
local_position_estimator
logger
mavlink
mc_att_control
mc_pos_control
navigator
sensors
sih
vmount
vtol_att_control
wind_estimator

SYSTEMCMDS
bl_update
config
dmesg
dumpfile
esc_calib
#hardfault_log # Needs bbsrm
i2cdetect
led_control
mixer
motor_ramp
motor_test
mtd
nshterm
param
perf
pwm
reboot
reflect
sd_bench
shutdown
tests # tests and test runner
top
topic_listener
tune_control
usb_connected
ver

EXAMPLES
bottle_drop # OBC challenge
fixedwing_control # Tutorial code from https://px4.io/dev/example_fixedwing_control
hello
hwtest # Hardware test
#matlab_csv_serial
position_estimator_inav
px4_mavlink_debug # Tutorial code from http://dev.px4.io/en/debug/debug_values.html
px4_simple_app # Tutorial code from http://dev.px4.io/en/apps/hello_sky.html
rover_steering_control # Rover example app
segway
uuv_example_app

)
13 changes: 13 additions & 0 deletions boards/nxp/fmurt1062-v1/firmware.prototype
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"board_id": 28,
"magic": "PX4FWv1",
"description": "Firmware for the NXPFMURT1062v1 board",
"image": "",
"build_time": 0,
"summary": "NXPFMURT1062v1",
"version": "0.1",
"image_size": 0,
"image_maxsize": 8388608,
"git_identity": "",
"board_revision": 0
}
54 changes: 54 additions & 0 deletions boards/nxp/fmurt1062-v1/init/rc.board
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
#!nsh
#
# PX4 FMUv5 specific board init
#
#------------------------------------------------------------------------------
#
# UART mapping on NXP FMURT1062:
#
# LPUART2 /dev/ttyS0 GPS
# LPUART3 /dev/ttyS2 TELEM2 (GPIO flow control)
# LPUART4 /dev/ttyS1 TELEM1 (UART flow control)
# LPUART5 /dev/ttyS3 TELEM4 GPS2
# LPUART6 /dev/ttyS4 TELEM3 (RC_INPUT)
# LPUART7 /dev/ttyS5 CONSOLE
# LPUART8 /dev/ttyS6 PX4IO
#
#------------------------------------------------------------------------------
#



if [ $AUTOCNF = yes ]
then
param set SYS_FMU_TASK 1
fi

set LOGGER_BUF 64

# Internal SPI bus ICM-20602
mpu6000 -R 8 -s -T 20602 start

# Internal SPI bus ICM-20689
mpu6000 -R 8 -z -T 20689 start

# Internal SPI bus BMI055 accel
bmi055 -A -R 10 start

# Internal SPI bus BMI055 gyro
bmi055 -G -R 10 start

# Possible external compasses
hmc5883 -C -T -X start

# Possible external compasses
ist8310 -C -b 1 start
ist8310 -C -b 2 start

# Possible internal compass
ist8310 -C -b 5 start

# Possible pmw3901 optical flow sensor
pmw3901 start

px4flow start &
16 changes: 16 additions & 0 deletions boards/nxp/fmurt1062-v1/nuttx-config/Kconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
#
# For a description of the syntax of this configuration file,
# see the file kconfig-language.txt in the NuttX tools repository.
#

choice
prompt "Boot Flash"
default NXP_FMURT1062_V3_QSPI_FLASH

config NXP_FMURT1062_V3_HYPER_FLASH
bool "HYPER Flash"

config NXP_FMURT1062_V3_QSPI_FLASH
bool "QSPI Flash"

endchoice # Boot Flash
Loading