Difference between revisions of "Bot test"
Line 1: | Line 1: | ||
− | + | ||
+ | |||
+ | {| width="50%" | ||
+ | |- | ||
+ | | width="20%" style="color: gray;" | Author | ||
+ | | Matrix TSL | ||
+ | |- | ||
+ | | width="20%" style="color: gray;" | Version | ||
+ | | 1.0 (Release) | ||
+ | |- | ||
+ | | width="20%" style="color: gray;" | Category | ||
+ | | Analog Input | ||
+ | |} | ||
+ | |||
+ | |||
+ | |||
+ | ==[[File:Component Icon 937e425e_21c0_4b08_8d8f_0bf80a6391d2.png|Image]] ADC (AD7680) component== | ||
+ | 16-bit external ADC connected to the microcontroller using SPI. | ||
+ | |||
+ | ==Examples== | ||
+ | ''<span style="color:red;">No additional examples</span>'' | ||
+ | |||
+ | |||
+ | ==Downloadable macro reference== | ||
+ | |||
+ | ===<span style="font-weight: normal;"><u><tt>SampleADC</tt></u></span>=== | ||
+ | Reads the ADC and returns the reading as an unsigned 16-bit value. | ||
+ | |||
+ | Range: 0-65535 / 0=0V / 65535=VCC | ||
+ | |||
+ | '''Parameters''' | ||
+ | |||
+ | :''This macro has no parameters'' | ||
+ | |||
+ | |||
+ | '''Return value''' | ||
+ | |||
+ | :[[Variable Types|UINT]] | ||
+ | |||
+ | |||
+ | ===<span style="font-weight: normal;"><u><tt>Initialise</tt></u></span>=== | ||
+ | Initialise the SPI bus ready for communications, | ||
+ | |||
+ | '''Parameters''' | ||
+ | |||
+ | :''This macro has no parameters'' | ||
+ | |||
+ | |||
+ | '''Return value''' | ||
+ | |||
+ | :''This call does not return a value'' | ||
+ | |||
+ | |||
+ | |||
+ | ==Simulation macro reference== | ||
+ | |||
+ | ''This component does not contain any simulation macros'' | ||
+ | |||
+ | |||
+ | ==Property reference== | ||
+ | <span style="font-weight: normal;"><u>Channel</u></span> | ||
+ | |||
+ | This property is of type ''Fixed list of ints'' and can be referenced with the variable name ''cal_spi1::CHANNEL''. | ||
+ | |||
+ | SPI Channel selector | ||
+ | |||
+ | <span style="font-weight: normal;"><u>Prescale</u></span> | ||
+ | |||
+ | This property is of type ''Fixed list of ints'' and can be referenced with the variable name ''cal_spi1::PR_SCALE''. | ||
+ | |||
+ | Prescale option selector | ||
+ | |||
+ | <span style="font-weight: normal;"><u>MOSI</u></span> | ||
+ | |||
+ | This property is of type ''Single digital pin'' and can be referenced with the variable name ''cal_spi1::MOSI''. | ||
+ | |||
+ | SPI Data Out Pin SDO - Also Known as Master Out Slave In (MOSI) when used in Master mode. | ||
+ | |||
+ | <span style="font-weight: normal;"><u>MISO</u></span> | ||
+ | |||
+ | This property is of type ''Single digital pin'' and can be referenced with the variable name ''cal_spi1::MISO''. | ||
+ | |||
+ | SPI Data In Pin SDI - Also Known as Master In Slave Out (MISO) when used in Master mode. | ||
+ | |||
+ | <span style="font-weight: normal;"><u>CLK</u></span> | ||
+ | |||
+ | This property is of type ''Single digital pin'' and can be referenced with the variable name ''cal_spi1::CLK''. | ||
+ | |||
+ | SPI Clock Pin CLK - The Clock signal is driven by the SPI master. | ||
+ | |||
+ | <span style="font-weight: normal;"><u>CS / SS</u></span> | ||
+ | |||
+ | This property is of type ''Single digital pin'' and can be referenced with the variable name ''cal_spi1::SS''. | ||
+ | |||
+ | Chip Select / Slave Select Pin | ||
+ | |||
+ | Master Mode: General purpose output pin used to select the remote SPI device. | ||
+ | |||
+ | Slave Mode: Hardware chip select pin input used to select the SPI device. | ||
+ | |||
+ | <span style="font-weight: normal;"><u>Simulate Comms</u></span> | ||
+ | |||
+ | This property is of type ''True or false'' and can be referenced with the variable name ''SimulateComms''. | ||
+ | |||
+ | ''<span style="color:red;">No additional information</span>'' | ||
+ | |||
+ | |||
+ | |||
+ | <span style="font-weight: normal;"><u>Console Data</u></span> | ||
+ | |||
+ | This property is of type ''True or false'' and can be referenced with the variable name ''cal_spi1::ConsoleData''. | ||
+ | |||
+ | Selects if the console data is automatically generated or not | ||
+ | |||
+ | <span style="font-weight: normal;"><u>Scope Traces</u></span> | ||
+ | |||
+ | This property is of type ''True or false'' and can be referenced with the variable name ''cal_spi1::ScopeTraces''. | ||
+ | |||
+ | Selects if the scope traces are automatically generated or not | ||
+ | |||
+ | <span style="font-weight: normal;"><u>Injector</u></span> | ||
+ | |||
+ | This property is of type ''Fixed list of ints'' and can be referenced with the variable name ''cal_spi1::Injector''. | ||
+ | |||
+ | ''<span style="color:red;">No additional information</span>'' |
Revision as of 11:15, 10 August 2021
Author | Matrix TSL |
Version | 1.0 (Release) |
Category | Analog Input |
Contents
ADC (AD7680) component
16-bit external ADC connected to the microcontroller using SPI.
Examples
No additional examples
Downloadable macro reference
SampleADC
Reads the ADC and returns the reading as an unsigned 16-bit value.
Range: 0-65535 / 0=0V / 65535=VCC
Parameters
- This macro has no parameters
Return value
Initialise
Initialise the SPI bus ready for communications,
Parameters
- This macro has no parameters
Return value
- This call does not return a value
Simulation macro reference
This component does not contain any simulation macros
Property reference
Channel
This property is of type Fixed list of ints and can be referenced with the variable name cal_spi1::CHANNEL.
SPI Channel selector
Prescale
This property is of type Fixed list of ints and can be referenced with the variable name cal_spi1::PR_SCALE.
Prescale option selector
MOSI
This property is of type Single digital pin and can be referenced with the variable name cal_spi1::MOSI.
SPI Data Out Pin SDO - Also Known as Master Out Slave In (MOSI) when used in Master mode.
MISO
This property is of type Single digital pin and can be referenced with the variable name cal_spi1::MISO.
SPI Data In Pin SDI - Also Known as Master In Slave Out (MISO) when used in Master mode.
CLK
This property is of type Single digital pin and can be referenced with the variable name cal_spi1::CLK.
SPI Clock Pin CLK - The Clock signal is driven by the SPI master.
CS / SS
This property is of type Single digital pin and can be referenced with the variable name cal_spi1::SS.
Chip Select / Slave Select Pin
Master Mode: General purpose output pin used to select the remote SPI device.
Slave Mode: Hardware chip select pin input used to select the SPI device.
Simulate Comms
This property is of type True or false and can be referenced with the variable name SimulateComms.
No additional information
Console Data
This property is of type True or false and can be referenced with the variable name cal_spi1::ConsoleData.
Selects if the console data is automatically generated or not
Scope Traces
This property is of type True or false and can be referenced with the variable name cal_spi1::ScopeTraces.
Selects if the scope traces are automatically generated or not
Injector
This property is of type Fixed list of ints and can be referenced with the variable name cal_spi1::Injector.
No additional information