NetBurner 3.1
nm_bus_wrapper.h File Reference

This module contains NMC1000 bus wrapper APIs declarations. More...

Go to the source code of this file.

Classes

struct  tstrNmBusCapabilities
 Structure holding bus capabilities information. More...
 
struct  tstrNmI2cDefault
 Structure holding I2C default operation parameters. More...
 
struct  tstrNmI2cSpecial
 Structure holding I2C special operation parameters. More...
 
struct  tstrNmSpiRw
 Structure holding SPI R/W parameters. More...
 

Macros

#define NM_BUS_TYPE_I2C   ((uint8)0)
 
#define NM_BUS_IOCTL_R   ((uint8)0)
 
#define NM_BUS_IOCTL_W   ((uint8)1)
 
#define NM_BUS_IOCTL_W_SPECIAL   ((uint8)2)
 
#define NM_BUS_IOCTL_RW   ((uint8)3)
 
#define NM_BUS_IOCTL_WR_RESTART   ((uint8)4)
 
#define NM_BUS_IOCTL_CMD_52   ((uint8)5)
 
#define NM_BUS_IOCTL_CMD_53   ((uint8)6)
 

Functions

sint8 nm_bus_deinit (void)
 De-initialize the bus wrapper. More...
 

Variables

tstrNmBusCapabilities egstrNmBusCapabilities
 

Detailed Description

This module contains NMC1000 bus wrapper APIs declarations.

Copyright (c) 2016-2018 Atmel Corporation. All rights reserved.

Macro Definition Documentation

◆ NM_BUS_IOCTL_CMD_52

#define NM_BUS_IOCTL_CMD_52   ((uint8)5)

Issue SDIO Command 52. parameter:tstrNmSdioCmd52

◆ NM_BUS_IOCTL_CMD_53

#define NM_BUS_IOCTL_CMD_53   ((uint8)6)

Issue SDIO Command 53. parameter:tstrNmSdioCmd53

◆ NM_BUS_IOCTL_R

#define NM_BUS_IOCTL_R   ((uint8)0)

IOCTL commandsRead only ==> I2C. Parameter:tstrNmI2cDefault

◆ NM_BUS_IOCTL_RW

#define NM_BUS_IOCTL_RW   ((uint8)3)

Read/Write at the same time ==> SPI only. Parameter:tstrNmSpiRw

◆ NM_BUS_IOCTL_W

#define NM_BUS_IOCTL_W   ((uint8)1)

Write only ==> I2C. Parameter type tstrNmI2cDefault

◆ NM_BUS_IOCTL_W_SPECIAL

#define NM_BUS_IOCTL_W_SPECIAL   ((uint8)2)

Write two buffers within the same transaction (same start/stop conditions) ==> I2C only. Parameter:tstrNmI2cSpecial

◆ NM_BUS_IOCTL_WR_RESTART

#define NM_BUS_IOCTL_WR_RESTART   ((uint8)4)

Write buffer then made restart condition then read ==> I2C only. parameter:tstrNmI2cSpecial

◆ NM_BUS_TYPE_I2C

#define NM_BUS_TYPE_I2C   ((uint8)0)

BUS Type

Function Documentation

◆ nm_bus_deinit()

nm_bus_deinit ( void  )

De-initialize the bus wrapper.

Returns
ZERO in case of success and M2M_ERR_BUS_FAIL in case of failure

Variable Documentation

◆ egstrNmBusCapabilities

tstrNmBusCapabilities egstrNmBusCapabilities

< Bus capabilities. This structure must be declared at platform specific bus wrapper