enum USCI_A0_SPI_2xx.UC7BIT_t |
|
Character length. Selects 7-bit or 8-bit character length
XDCscript usage |
meta-domain |
values of type USCI_A0_SPI_2xx.UC7BIT_t
const USCI_A0_SPI_2xx.UC7BIT_OFF;
// 8-bit
const USCI_A0_SPI_2xx.UC7BIT;
// 7-bit
enum USCI_A0_SPI_2xx.UCADDR_t |
|
Address received in address-bit multiprocessor mode
XDCscript usage |
meta-domain |
values of type USCI_A0_SPI_2xx.UCADDR_t
const USCI_A0_SPI_2xx.UCADDR_OFF;
// Received character is data
const USCI_A0_SPI_2xx.UCADDR;
// Received character is an address
enum USCI_A0_SPI_2xx.UCBRKIE_t |
|
Receive break character interrupt-enable
XDCscript usage |
meta-domain |
values of type USCI_A0_SPI_2xx.UCBRKIE_t
const USCI_A0_SPI_2xx.UCBRKIE_OFF;
// Received break characters do not set UCAxRXIFG
const USCI_A0_SPI_2xx.UCBRKIE;
// Received break characters set UCAxRXIFG
enum USCI_A0_SPI_2xx.UCBRK_t |
|
Break detect flag
XDCscript usage |
meta-domain |
values of type USCI_A0_SPI_2xx.UCBRK_t
const USCI_A0_SPI_2xx.UCBRK_OFF;
// No break condition
const USCI_A0_SPI_2xx.UCBRK;
// Break condition occurred
enum USCI_A0_SPI_2xx.UCBUSY_t |
|
USCI busy. This bit indicates if a transmit or receive operation is in progress
XDCscript usage |
meta-domain |
values of type USCI_A0_SPI_2xx.UCBUSY_t
const USCI_A0_SPI_2xx.UCBUSY_OFF;
// USCI inactive
const USCI_A0_SPI_2xx.UCBUSY;
// USCI transmitting or receiving
enum USCI_A0_SPI_2xx.UCCKPH_t |
|
Clock phase select
XDCscript usage |
meta-domain |
values of type USCI_A0_SPI_2xx.UCCKPH_t
const USCI_A0_SPI_2xx.UCCKPH_OFF;
// Data is changed on the first UCLK edge and captured on the following edge
const USCI_A0_SPI_2xx.UCCKPH;
// Data is captured on the first UCLK edge and changed on the following edge
enum USCI_A0_SPI_2xx.UCCKPL_t |
|
Clock polarity select
XDCscript usage |
meta-domain |
values of type USCI_A0_SPI_2xx.UCCKPL_t
const USCI_A0_SPI_2xx.UCCKPL_OFF;
// Inactive state is low
const USCI_A0_SPI_2xx.UCCKPL;
// Inactive state is high
enum USCI_A0_SPI_2xx.UCDORM_t |
|
Dormant. Puts USCI into sleep mode
XDCscript usage |
meta-domain |
values of type USCI_A0_SPI_2xx.UCDORM_t
const USCI_A0_SPI_2xx.UCDORM_OFF;
// Not dormant. All received characters will set UCAxRXIFG
const USCI_A0_SPI_2xx.UCDORM;
// Dormant. Only characters that are preceded by an idle-line or with
address bit set will set UCAxRXIFG. In UART mode with automatic baud
rate detection only the combination of a break and synch field will set
UCAxRXIFG
enum USCI_A0_SPI_2xx.UCFE_t |
|
Framing error flag
XDCscript usage |
meta-domain |
values of type USCI_A0_SPI_2xx.UCFE_t
const USCI_A0_SPI_2xx.UCFE_OFF;
// 0 No error
const USCI_A0_SPI_2xx.UCFE;
// Character received with low stop bit
enum USCI_A0_SPI_2xx.UCIDLE_t |
|
Idle line detected in idle-line multiprocessor mode
XDCscript usage |
meta-domain |
values of type USCI_A0_SPI_2xx.UCIDLE_t
const USCI_A0_SPI_2xx.UCIDLE_OFF;
// No idle line detected
const USCI_A0_SPI_2xx.UCIDLE;
// Idle line detected
enum USCI_A0_SPI_2xx.UCLISTEN_t |
|
Listen enable. The UCLISTEN bit selects loopback mode
XDCscript usage |
meta-domain |
values of type USCI_A0_SPI_2xx.UCLISTEN_t
const USCI_A0_SPI_2xx.UCLISTEN_OFF;
// Disabled
const USCI_A0_SPI_2xx.UCLISTEN;
// Enabled. UCAxTXD is internally fed back to the receiver
enum USCI_A0_SPI_2xx.UCMODE_SYNC_t |
|
USCI mode. The UCMODEx bits select the synchronous mode when UCSYNC = 1
XDCscript usage |
meta-domain |
values of type USCI_A0_SPI_2xx.UCMODE_SYNC_t
const USCI_A0_SPI_2xx.UCMODE_0;
// 3-Pin SPI
const USCI_A0_SPI_2xx.UCMODE_1;
// 4-Pin SPI with UCxSTE active high: slave enabled when UCxSTE = 1
const USCI_A0_SPI_2xx.UCMODE_2;
// 4-Pin SPI with UCxSTE active low: slave enabled when UCxSTE = 0
const USCI_A0_SPI_2xx.UCMODE_3;
// I2C Mode
enum USCI_A0_SPI_2xx.UCMSB_t |
|
MSB first select. Controls the direction of the receive and transmit shift register
XDCscript usage |
meta-domain |
values of type USCI_A0_SPI_2xx.UCMSB_t
const USCI_A0_SPI_2xx.UCMSB_OFF;
// LSB first
const USCI_A0_SPI_2xx.UCMSB;
// MSB first
enum USCI_A0_SPI_2xx.UCMST_t |
|
Master mode select
XDCscript usage |
meta-domain |
values of type USCI_A0_SPI_2xx.UCMST_t
const USCI_A0_SPI_2xx.UCMST_OFF;
// Slave mode
const USCI_A0_SPI_2xx.UCMST;
// Master mode
enum USCI_A0_SPI_2xx.UCOE_t |
|
Overrun error flag
XDCscript usage |
meta-domain |
values of type USCI_A0_SPI_2xx.UCOE_t
const USCI_A0_SPI_2xx.UCOE_OFF;
// No error
const USCI_A0_SPI_2xx.UCOE;
// Overrun error occurred
enum USCI_A0_SPI_2xx.UCPE_t |
|
Parity error flag. When UCPEN = 0, UCPE is read as 0
XDCscript usage |
meta-domain |
values of type USCI_A0_SPI_2xx.UCPE_t
const USCI_A0_SPI_2xx.UCPE_OFF;
// No error
const USCI_A0_SPI_2xx.UCPE;
// Character received with parity error
enum USCI_A0_SPI_2xx.UCRXEIE_t |
|
Receive erroneous-character interrupt-enable
XDCscript usage |
meta-domain |
values of type USCI_A0_SPI_2xx.UCRXEIE_t
const USCI_A0_SPI_2xx.UCRXEIE_OFF;
// Erroneous characters rejected and UCAxRXIFG is not set
const USCI_A0_SPI_2xx.UCRXEIE;
// Erroneous characters received will set UCAxRXIFG
enum USCI_A0_SPI_2xx.UCRXERR_t |
|
Bit 2 Receive error flag. This bit indicates a character was received with error(s).
When UCRXERR = 1, on or more error flags (UCFE, UCPE, UCOE) is also
set. UCRXERR is cleared when UCAxRXBUF is read
XDCscript usage |
meta-domain |
values of type USCI_A0_SPI_2xx.UCRXERR_t
const USCI_A0_SPI_2xx.UCRXERR_OFF;
// No receive errors detected
const USCI_A0_SPI_2xx.UCRXERR;
// Receive error detected
enum USCI_A0_SPI_2xx.UCSSEL_SPI_t |
|
USCI clock source select. These bits select the BRCLK source clock
XDCscript usage |
meta-domain |
values of type USCI_A0_SPI_2xx.UCSSEL_SPI_t
const USCI_A0_SPI_2xx.UCSSEL_0;
// NA
const USCI_A0_SPI_2xx.UCSSEL_1;
// ACLK
const USCI_A0_SPI_2xx.UCSSEL_2;
// SMCLK
enum USCI_A0_SPI_2xx.UCSWRST_t |
|
Software reset enable
XDCscript usage |
meta-domain |
values of type USCI_A0_SPI_2xx.UCSWRST_t
const USCI_A0_SPI_2xx.UCSWRST_OFF;
// Disabled. USCI reset released for operation
const USCI_A0_SPI_2xx.UCSWRST;
// Enabled. USCI logic held in reset state
enum USCI_A0_SPI_2xx.UCSYNC_t |
|
Synchronous mode enable
XDCscript usage |
meta-domain |
values of type USCI_A0_SPI_2xx.UCSYNC_t
const USCI_A0_SPI_2xx.UCSYNC_OFF;
// Asynchronous mode
const USCI_A0_SPI_2xx.UCSYNC;
// Synchronous Mode
enum USCI_A0_SPI_2xx.UCTXADDR_t |
|
Transmit address. Next frame to be transmitted will be marked as address depending on the selected multiprocessor mode
XDCscript usage |
meta-domain |
values of type USCI_A0_SPI_2xx.UCTXADDR_t
const USCI_A0_SPI_2xx.UCTXADDR_OFF;
// Next frame transmitted is data
const USCI_A0_SPI_2xx.UCTXADDR;
// Next frame transmitted is an address
enum USCI_A0_SPI_2xx.UCTXBRK_t |
|
Transmit break. Transmits a break with the next write to the transmit buffer.
In UART mode with automatic baud rate detection 055h must be written
into UCAxTXBUF to generate the required break/synch fields. Otherwise
0h must be written into the transmit buffer
XDCscript usage |
meta-domain |
values of type USCI_A0_SPI_2xx.UCTXBRK_t
const USCI_A0_SPI_2xx.UCTXBRK_OFF;
// Next frame transmitted is not a break
const USCI_A0_SPI_2xx.UCTXBRK;
// Next frame transmitted is a break or a break/synch
struct USCI_A0_SPI_2xx.ForceSetDefaultRegister_t |
|
Force Set Default Register
XDCscript usage |
meta-domain |
var obj = new USCI_A0_SPI_2xx.ForceSetDefaultRegister_t;
obj.register = String ...
obj.regForceSet = Bool ...
DETAILS
Type to store if each register needs to be forced initialized
even if the register is in default state.
SEE
struct USCI_A0_SPI_2xx.UCxCTL0_t |
|
XDCscript usage |
meta-domain |
var obj = new USCI_A0_SPI_2xx.UCxCTL0_t;
// Clock phase select.
0 Data is changed on the first UCLK edge and captured on the
following edge.
1 Data is captured on the first UCLK edge and changed on the
following edge
// Clock polarity select
0 The inactive state is low
1 The inactive state is high
// MSB first select. Controls the direction of the receive and transmit shift
register.
0 LSB first
1 MSB first
// Character length. Selects 7-bit or 8-bit character length.
0 8-bit data
1 7-bit data
// Master mode select
0 Slave mode
1 Master mode
// USCI mode. The UCMODEx bits select the synchronous mode when
UCSYNC = 1.
00 3-Pin SPI
01 4-Pin SPI with UCxSTE active high: slave enabled when UCxSTE = 1
10 4-Pin SPI with UCxSTE active low: slave enabled when UCxSTE = 0
11 I2C Mode
// Synchronous mode enable
0 Asynchronous mode
1 Synchronous Mode
struct USCI_A0_SPI_2xx.UCxCTL1_t |
|
XDCscript usage |
meta-domain |
var obj = new USCI_A0_SPI_2xx.UCxCTL1_t;
// USCI clock source select. These bits select the BRCLK source clock in
master mode. UCxCLK is always used in slave mode.
00 NA
01 ACLK
10 SMCLK
11 SMCLK
// Software reset enable
0 Disabled. USCI reset released for operation.
1 Enabled. USCI logic held in reset state
struct USCI_A0_SPI_2xx.UCxSTAT_t |
|
XDCscript usage |
meta-domain |
var obj = new USCI_A0_SPI_2xx.UCxSTAT_t;
// Listen enable. The UCLISTEN bit selects loopback mode.
0 Disabled
1 Enabled. UCAxTXD is internally fed back to the receiver
// Framing error flag. This bit indicates a bus conflict in 4-wire master mode.
UCFE is not used in 3-wire master or any slave mode.
0 No error
1 Bus conflict occurred
// Overrun error flag. This bit is set when a character is transferred into
UCAxRXBUF before the previous character was read. UCOE is cleared
automatically when UCxRXBUF is read, and must not be cleared by
software. Otherwise, it will not function correctly.
0 No error
1 Overrun error occurred
// USCI busy. This bit indicates if a transmit or receive operation is in
progress.
0 USCI inactive
1 USCI transmitting or receiving
USCI_A0_SPI_2xx.addPeripheralsMap() // module-wide |
|
Create a map of all peripherals available on a device
XDCscript usage |
meta-domain |
ARGUMENTS
DETAILS
The config parameter
peripherals is by default undefined in an
xdc.platform.ICpuDataSheet instance. This function gathers
all instance configuration parameters that are of the type
xdc.platform.IPeripheral into the map
peripherals.
USCI_A0_SPI_2xx.getAll() // module-wide |
|
Find all peripherals of a certain type
XDCscript usage |
meta-domain |
DETAILS
The type of the peripherals returned is defined by the type of the
caller.
RETURNS
Returns an array of IPeripheral instances
USCI_A0_SPI_2xx.getRegisters() // module-wide |
|
Find all registers defined by the peripheral
XDCscript usage |
meta-domain |
USCI_A0_SPI_2xx.getRegisters() returns String[]
RETURNS
Returns an array of register names
Instance Config Parameters |
|
XDCscript usage |
meta-domain |
var params = new USCI_A0_SPI_2xx.Params;
// Instance config-params object
params.UCA0BR0 = UChar 0;
// Bit Rate Control Register 0
params.UCA0BR1 = UChar 0;
// Bit Rate Control Register 1
// Control Register 0
};
// Control Register 1
};
params.UCA0RXBUF = UChar 0;
// Receive Buffer Register
// Status Register
};
params.UCA0TXBUF = UChar 0;
// Transmit Buffer Register
params.UCLKHz = Float 1000000;
// Stores the UCLK external clock frequency in float
// Determine if each Register needs to be forced set or not
{
register: "UCA0CTL0",
regForceSet: false
},
{
register: "UCA0CTL1",
regForceSet: false
},
{
register: "UCA0BR0",
regForceSet: false
},
{
register: "UCA0BR1",
regForceSet: false
},
{
register: "UCA0STAT",
regForceSet: false
},
{
register: "UCA0RXBUF",
regForceSet: false
},
{
register: "UCA0TXBUF",
regForceSet: false
}
];
params.name = String undefined;
// Specific peripheral name given by the device
params.owner = String undefined;
// String specifying the entity that manages the peripheral
config USCI_A0_SPI_2xx.UCA0BR0 // instance |
|
Bit Rate Control Register 0
XDCscript usage |
meta-domain |
var params = new USCI_A0_SPI_2xx.Params;
...
params.UCA0BR0 = UChar 0;
config USCI_A0_SPI_2xx.UCA0BR1 // instance |
|
Bit Rate Control Register 1
XDCscript usage |
meta-domain |
var params = new USCI_A0_SPI_2xx.Params;
...
params.UCA0BR1 = UChar 0;
config USCI_A0_SPI_2xx.UCA0CTL0 // instance |
|
Control Register 0
XDCscript usage |
meta-domain |
var params = new USCI_A0_SPI_2xx.Params;
...
};
config USCI_A0_SPI_2xx.UCA0CTL1 // instance |
|
Control Register 1
XDCscript usage |
meta-domain |
var params = new USCI_A0_SPI_2xx.Params;
...
};
config USCI_A0_SPI_2xx.UCA0RXBUF // instance |
|
Receive Buffer Register
XDCscript usage |
meta-domain |
var params = new USCI_A0_SPI_2xx.Params;
...
params.UCA0RXBUF = UChar 0;
config USCI_A0_SPI_2xx.UCA0STAT // instance |
|
Status Register
XDCscript usage |
meta-domain |
var params = new USCI_A0_SPI_2xx.Params;
...
};
config USCI_A0_SPI_2xx.UCA0TXBUF // instance |
|
Transmit Buffer Register
XDCscript usage |
meta-domain |
var params = new USCI_A0_SPI_2xx.Params;
...
params.UCA0TXBUF = UChar 0;
config USCI_A0_SPI_2xx.UCLKHz // instance |
|
Stores the UCLK external clock frequency in float
XDCscript usage |
meta-domain |
var params = new USCI_A0_SPI_2xx.Params;
...
params.UCLKHz = Float 1000000;
config USCI_A0_SPI_2xx.forceSetDefaultRegister // instance |
|
Determine if each Register needs to be forced set or not
XDCscript usage |
meta-domain |
var params = new USCI_A0_SPI_2xx.Params;
...
{
register: "UCA0CTL0",
regForceSet: false
},
{
register: "UCA0CTL1",
regForceSet: false
},
{
register: "UCA0BR0",
regForceSet: false
},
{
register: "UCA0BR1",
regForceSet: false
},
{
register: "UCA0STAT",
regForceSet: false
},
{
register: "UCA0RXBUF",
regForceSet: false
},
{
register: "UCA0TXBUF",
regForceSet: false
}
];
config USCI_A0_SPI_2xx.name // instance |
|
Specific peripheral name given by the device
XDCscript usage |
meta-domain |
var params = new USCI_A0_SPI_2xx.Params;
...
params.name = String undefined;
DETAILS
Devices can have more than one peripheral of the same type. In such
cases, device data sheets give different names to the instances of a
same peripheral. For example, the name for a timer module could be
TimerA3, and a device that has two such timers can name them TA0
and TA1.
config USCI_A0_SPI_2xx.owner // instance |
|
String specifying the entity that manages the peripheral
XDCscript usage |
meta-domain |
var params = new USCI_A0_SPI_2xx.Params;
...
params.owner = String undefined;
Instance Creation |
|
XDCscript usage |
meta-domain |
var params =
new USCI_A0_SPI_2xx.
Params;
// Allocate instance config-params
params.config = ...
// Assign individual configs
// Create an instance-object
USCI_A0_SPI_2xx.getUCRXIE() // instance |
|
XDCscript usage |
meta-domain |
inst.getUCRXIE() returns Bool
USCI_A0_SPI_2xx.getUCTXIE() // instance |
|
XDCscript usage |
meta-domain |
inst.getUCTXIE() returns Bool
USCI_A0_SPI_2xx.setUCRXIE() // instance |
|
XDCscript usage |
meta-domain |
inst.setUCRXIE(Bool set) returns Bool
USCI_A0_SPI_2xx.setUCTXIE() // instance |
|
XDCscript usage |
meta-domain |
inst.setUCTXIE(Bool set) returns Bool