Paparazzi UAS  v5.15_devel-61-g9c6bcf9
Paparazzi is a free software Unmanned Aircraft System.
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
intermcu_can module

Inter-MCU communication over CAN

To enable this, please set the "SEPARATE_FBW" configure option to TRUE in your airframe file for both AP and FBW targets

Example for airframe file

Add to your firmware section: This example contains all possible configuration options, not all of them are mandatory!

1 <module name="intermcu_can">
2  <configure name="SEPARATE_FBW" value="FALSE|TRUE" />
3 </module>

Module configuration options

Configure Options

  • name: SEPARATE_FBW value: FALSE|TRUE
    Description: Enable separation between AP and FBW on separated MCU

Files

Source Files

Raw intermcu_can.xml file:

<!DOCTYPE module SYSTEM "module.dtd">
<module name="intermcu_can" dir="intermcu">
<doc>
<description>
Inter-MCU communication over CAN
To enable this, please set the "SEPARATE_FBW" configure option to TRUE
in your airframe file for both AP and FBW targets
</description>
<configure name="SEPARATE_FBW" value="FALSE|TRUE" description="Enable separation between AP and FBW on separated MCU"/>
</doc>
<makefile target="ap|fbw" firmware="fixedwing">
<raw>
ifeq (,$(findstring $(SEPARATE_FBW),1 TRUE))
$(error Using intermcu via CAN, so dual mcu with separate fbw. Please set option "SEPARATE_FBW" to TRUE.
endif
</raw>
<define name="INTER_MCU"/>
<define name="MCU_CAN_LINK"/>
<file name="link_mcu_can.c" dir="."/>
<file name="can.c" dir="mcu_periph"/>
<file name="can_arch.c" dir="$(SRC_ARCH)/mcu_periph"/>
</makefile>
</module>