pub struct TlMbox<'d> {
pub sys_subsystem: Sys,
pub mm_subsystem: MemoryManager,
pub ble_subsystem: Ble,
pub mac_subsystem: Mac,
/* private fields */
}
Expand description
Transport Layer for the Mailbox interface
Fields§
§sys_subsystem: Sys
§mm_subsystem: MemoryManager
§ble_subsystem: Ble
§mac_subsystem: Mac
Implementations§
Source§impl<'d> TlMbox<'d>
impl<'d> TlMbox<'d>
Sourcepub fn init(
ipcc: impl Peripheral<P = IPCC> + 'd,
_irqs: impl Binding<IPCC_C1_RX, ReceiveInterruptHandler> + Binding<IPCC_C1_TX, TransmitInterruptHandler>,
config: Config,
) -> Self
pub fn init( ipcc: impl Peripheral<P = IPCC> + 'd, _irqs: impl Binding<IPCC_C1_RX, ReceiveInterruptHandler> + Binding<IPCC_C1_TX, TransmitInterruptHandler>, config: Config, ) -> Self
Initialise the Transport Layer, and creates and returns a wrapper around it.
This method performs the initialisation laid out in AN5289 annex 14.1. However, it differs from the implementation documented in Figure 64, to avoid needing to reference any C function pointers.
Annex 14.1 lays out the following methods that should be called: 1. tl_mbox.c/TL_Init, which initialises the reference table that is shared between CPU1 and CPU2. 2. shci_tl.c/shci_init(), which initialises the system transport layer, and in turn calls tl_mbox.c/TL_SYS_Init, which initialises SYSTEM_EVT_QUEUE channel. 3. tl_mbox.c/TL_MM_Init(), which initialises the channel used for sending memory manager commands. 4. tl_mbox.c/TL_Enable(), which enables the IPCC, and starts CPU2. This implementation initialises all of the shared refernce tables and all IPCC channel that would be initialised by this process. The developer should therefore treat this method as completing all steps in Figure 64.
Once this method has been called, no system commands may be sent until the CPU2 ready signal is received, via [sys_subsystem.read]; this completes the procedure laid out in Figure 65.
If the ble
feature is enabled, at this point, the user should call
[sys_subsystem.shci_c2_ble_init], before any commands are written to the
[TlMbox.ble_subsystem] (sub::ble::Ble::new() completes the process that would otherwise
be handled by TL_BLE_Init
; see Figure 66). This completes the procedure laid out in
Figure 66.