UAVCANv1 demo UAVCAN146 <-> BMS-722 is working

Fixed UAVCAN146 linker script that caused CXX initalization to wrong
Enabled uORB listener command
Updated UAVCANv1 msg definition

Known isssue: PX4 params are not working on the UAVCAN146
This commit is contained in:
Peter van der Perk 2020-05-29 15:34:29 +02:00 committed by Lorenz Meier
parent 58ca575871
commit e5d29d4079
4 changed files with 15 additions and 10 deletions

View File

@ -71,7 +71,7 @@ px4_add_board(
#sd_bench
system_time
top
#topic_listener
topic_listener
#tune_control
ver
work_queue

View File

@ -44,11 +44,14 @@ CONFIG_I2CTOOL_MINADDR=0x00
CONFIG_INTELHEX_BINARY=y
CONFIG_LIBC_FLOATINGPOINT=y
CONFIG_LIBC_STRERROR=y
CONFIG_LPUART0_RXBUFSIZE=64
CONFIG_LPUART0_TXBUFSIZE=64
CONFIG_LPUART1_RXBUFSIZE=64
CONFIG_LPUART0_BAUD=38400
CONFIG_LPUART0_RXBUFSIZE=600
CONFIG_LPUART0_RXDMA=y
CONFIG_LPUART0_TXBUFSIZE=1100
CONFIG_LPUART0_TXDMA=y
CONFIG_LPUART1_RXBUFSIZE=128
CONFIG_LPUART1_SERIAL_CONSOLE=y
CONFIG_LPUART1_TXBUFSIZE=64
CONFIG_LPUART1_TXBUFSIZE=128
CONFIG_MAX_TASKS=16
CONFIG_MOTOROLA_SREC=y
CONFIG_NET=y
@ -71,13 +74,14 @@ CONFIG_NSH_ROMFSSECTSIZE=128
CONFIG_NSH_STRERROR=y
CONFIG_NSH_VARS=y
CONFIG_PREALLOC_TIMERS=4
CONFIG_PSEUDOTERM=y
CONFIG_RAM_SIZE=126976
CONFIG_RAM_START=0x1fff0000
CONFIG_RAW_BINARY=y
CONFIG_RR_INTERVAL=200
CONFIG_RTC=y
CONFIG_RTC_FREQUENCY=32768
CONFIG_RTC_HIRES=y
# CONFIG_RTC_FREQUENCY=32768
# CONFIG_RTC_HIRES=y
CONFIG_S32K1XX_FLEXCAN0=y
CONFIG_S32K1XX_FLEXCAN1=y
CONFIG_S32K1XX_LPI2C0=y

View File

@ -235,7 +235,7 @@ void UavcanNode::Run()
if (_battery_status_sub.update(&battery_status)) {
regulated::drone::sensor::BMSStatus_1_0 bmsstatus{};
//bmsstatus.timestamp = battery_status.timestamp;
bmsstatus.remaining_capacity = battery_status.remaining;
//bmsstatus.remaining_capacity = battery_status.remaining;
bmsstatus.serializeToBuffer(_regulated_drone_sensor_bmsstatus_buffer);
@ -320,7 +320,8 @@ void UavcanNode::Run()
battery_status_s battery_status{};
battery_status.id = bms_status.battery_id;
battery_status.remaining = bms_status.remaining_capacity;
battery_status.voltage_v = bms_status.voltage;
//battery_status.remaining = bms_status.remaining_capacity;
battery_status.timestamp = hrt_absolute_time();
_battery_status_pub.publish(battery_status);
}

@ -1 +1 @@
Subproject commit e378c3a4c5eb38ad30866059b838d4099a85f2ea
Subproject commit 4ef80c77c7ea9a5ac74ec1fa58055e7609b7758e