Jump to content

Component: ADC16bit ADS111x (Analog Input)

From Flowcode Help
Revision as of 14:15, 13 July 2026 by SteveT (talk | contribs) (Text replacement - "class="wikitable" style="width:60%; background-color:#FFFFFF;"" to "class="mtx-class-macrotable wikitable"")
Author Matrix TSL
Version 1.0
Category Analog Input


ADC16bit ADS111x component

A Precision Low power 16Bit I2C ADC 4 channes device with a Programmable comparator

Detailed description

No detailed description exists yet for this component

Examples

Simple example file to generate a two column CSV file that can be loaded into Microsoft Excel or LibreOffice Math.

The CSV Read/Write component is for simulation or App Developer.

For an embedded CSV read write see the File component

CSV Component used with App Developer -> File component: CSV Test AD


The component requires linking to a File component to provide access to the file system for simulation and runtime, this could be the File SD, File RPI or File AppDeveloper components.


Macro reference

Initialise

Initialise
Sets up the I2C bus ready for communications with the device. Returned value: 0 = Success 
- BYTE Return


SampleSglRaw

SampleSglRaw
Performs a single ADC sample on the selected ADC channel 
- BYTE Channel
Range: 0-3 
- BYTE Mode
Single-Shot Mode - powers down when conversion has finished. Range 0 to 1. 0 = Continuous, 1 = Single-Shot 
- BYTE Gain
GAIN 0 = 6.144V, 1 = 4.096V, 2 = 2.048V, 3 = 1.024V, 4 = 0.512V 5 = +- 0.256V 
- UINT Return


SampleSglVolts

SampleSglVolts
Performs a single ADC sample on the selected ADC channel 
- BYTE Channel
Range: 0-3 
- BYTE Mode
Single-Shot Mode - powers down when conversion has finished. Range 0 to 1. 0 = Continuous, 1 = Single-Shot 
- BYTE Gain
GAIN 0 = 6.144V, 1 = 4.096V, 2 = 2.048V, 3 = 1.024V, 4 = 0.512V 5 = +- 0.256V 
- FLOAT Return


Property reference

Properties
Connections
Device Address
ADDR connects either to the GDN, VDD, SDA or SCL to determing the address of the ADC.  
Channel
Channel selection 
SDA
Pin used for SDA (data signal) 
SCL
Pin used for SCL (clock signal) 
Stop Delay
On older microcontroller devices there is a potential for the I2C hardware channel to lock up if there is not a 10ms delay between an I2C stop event and the next I2C start event. Most modern microcontrollers will not have a problem so this property can be disabled to speed up the I2C communications.  
Baud Select
Baud rate option selector 
Baud Rate
Baud rate to be used 
RDY/ALRT
 
Configuation
Samples Per Sec
 
Simulation
Gain A0
Gain is for simulation only. The hardware ADC gain is set within the function parameter.  
Gain A1
Gain is for simulation only. The hardware ADC gain is set within the function parameter.  
Gain A2
Gain is for simulation only. The hardware ADC gain is set within the function parameter.  
Gain A3
Gain is for simulation only. The hardware ADC gain is set within the function parameter.  
Simulate Comms
Allows the communications to be simulated overriding the value on the panel slider controls. 

Component Source Code

Please click here to download the component source project: FC_Comp_Source_External_ADC16Bit_ADS111x.fcfx

Please click here to view the component source code (Beta): FC_Comp_Source_External_ADC16Bit_ADS111x.fcfx