Component: Digital Potentiometer (MCP44XX) (Analog Output)

From Flowcode Help
Revision as of 21:08, 16 November 2021 by Wiki bot (talk | contribs)
Jump to navigationJump to search
Author Matrix TSL
Version 1.0
Category Analog Output


Digital Potentiometer (MCP44XX) component

The MCP44XX device range supports 4 digital potentiometers or rheostat outputs. 129 or 257 possible output resistance values for each channel.

Detailed description

No detailed description exists yet for this component

Examples

No additional examples


Downloadable macro reference

Fc9-comp-macro.png IncrementWiper
Increments a single volatile wiper value 
Fc9-u8-icon.png - BYTE Index
Range: 0-3 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png DecrementWiper
Decrements a single volatile wiper value 
Fc9-u8-icon.png - BYTE Index
Range: 0-3 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png SetWiper
Sets the value of a single wiper 
Fc9-u8-icon.png - BYTE Index
Range: 0-3 
Fc9-u16-icon.png - UINT Value
129 Taps Range: 0-128 / 257 Taps Range: 0-256 
[[File:]] - MemoryType
0=Volatile, 1=Nonvolatile 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png ReadAddress
Reads a value from one of the registers on the device 
Fc9-u8-icon.png - BYTE Address
Range: 0-15 
Fc9-u16-icon.png - UINT Return


Fc9-comp-macro.png WriteAddress
Writes a value to one of the registers on the device 
Fc9-u8-icon.png - BYTE Address
Range: 0-15 
Fc9-u16-icon.png - UINT Value
Range: 0-256 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png Initialise
Startup the I2C peripheral ready for communications. 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png Initialise
Starts up the I2C comms ready for communicating with the LP503x module. Must be called before any of the other component macros are called. 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png Refresh
Clocks out the current colour data to the LEDs from the values stored in RAM 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png ShiftLEDs1D
Shifts the LED colours in 1D and wraps  
Fc9-u8-icon.png - BYTE Direction
0 = Forwards, 1 = Backwards 
Fc9-u8-icon.png - BYTE DataMode
0=ResetToZero, 1=WrapAroundDisplay, 2=Smear 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png DrawLine3D
Draws a line on a 3D array of LEDs 
Fc9-u16-icon.png - UINT X1
Start X Coordinate 
Fc9-u16-icon.png - UINT Y1
Start Y Coordinate 
Fc9-u16-icon.png - UINT Z1
Start Z Coordinate 
Fc9-u16-icon.png - UINT X2
End X Coordinate 
Fc9-u16-icon.png - UINT Y2
End Y Coordinate 
Fc9-u16-icon.png - UINT Z2
End Z Coordinate 
Fc9-u8-icon.png - BYTE R
Red Colour Channel 
Fc9-u8-icon.png - BYTE G
Green Colour Channel 
Fc9-u8-icon.png - BYTE B
Blue Colour Channel 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png Delay_T1H
 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png GetLEDIndex2D
Sets the index of a single LED in RAM as a 2D array. 
Fc9-u16-icon.png - UINT X
LED Column to change the colour / Range: 0 to (LED Column - 1) 
Fc9-u16-icon.png - UINT Y
LED Row to change the colour / Range: 0 to (LED Row - 1) 
Fc9-u16-icon.png - UINT Return


Fc9-comp-macro.png DrawRectangle2D
Draws a basic 2D rectangle onto the LEDs 
Fc9-u8-icon.png - BYTE X1
 
Fc9-u8-icon.png - BYTE Y1
 
Fc9-u8-icon.png - BYTE X2
 
Fc9-u8-icon.png - BYTE Y2
 
Fc9-u8-icon.png - BYTE DrawStyle
Sets the draw style - 0=Soild, 1=Edge, 2=Corners 
Fc9-u8-icon.png - BYTE R
 
Fc9-u8-icon.png - BYTE G
 
Fc9-u8-icon.png - BYTE B
 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png ShiftLEDs2D
Shifts the contents of the display by the number of vertices specified ***Please Note that Wrap mode is currently unavailable*** 
[[File:]] - X
Number of pixels to shift the display -1 to 1 / 0 = No Shift 
[[File:]] - Y
Number of pixels to shift the display -1 to 1 / 0 = No Shift 
Fc9-u8-icon.png - BYTE DataMode
0=ResetToZero, 1=WrapAroundDisplay, 2=Smear 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png GetLEDIndex3D
Gets the index of a single LED in RAM as a 3D array. 
Fc9-u16-icon.png - UINT X
LED Column to change the colour / Range: 0 to (LED Column - 1) 
Fc9-u16-icon.png - UINT Y
LED Row to change the colour / Range: 0 to (LED Row - 1) 
Fc9-u16-icon.png - UINT Z
LED Layer to change the colour / Range: 0 to (LED Layer - 1) 
Fc9-u16-icon.png - UINT Return


Fc9-comp-macro.png DrawCuboid3D
Draws a basic 3D cuboid onto the LEDs 
Fc9-u8-icon.png - BYTE X1
Start X pixel coordinate 
Fc9-u8-icon.png - BYTE Y1
Start Y pixel coordinate 
Fc9-u8-icon.png - BYTE Z1
Start Z pixel coordinate 
Fc9-u8-icon.png - BYTE X2
End X pixel coordinate 
Fc9-u8-icon.png - BYTE Y2
End Y pixel coordinate 
Fc9-u8-icon.png - BYTE Z2
End Z pixel coordinate 
Fc9-u8-icon.png - BYTE DrawStyle
Sets the draw style - 0=Soild, 1=Edge, 2=Corners 
Fc9-u8-icon.png - BYTE R
Red Colour Channel 
Fc9-u8-icon.png - BYTE G
Green Colour Channel 
Fc9-u8-icon.png - BYTE B
White Colour Channel 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png Initialise
Inisialises the RGB colour RAM to 0,0,0 = LED Off and clocks out the data to initialise all the LED ICs in the chain. 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png ShiftLEDs3D
Shifts the contents of the display by the number of vertices specified ***Please Note that Wrap mode is currently unavailable*** 
[[File:]] - X
Number of pixels to shift the display -1 to 1 / 0 = No Shift 
[[File:]] - Y
Number of pixels to shift the display -1 to 1 / 0 = No Shift 
[[File:]] - Z
Number of pixels to shift the display -1 to 1 / 0 = No Shift 
Fc9-u8-icon.png - BYTE DataMode
0=ResetToZero, 1=WrapAroundDisplay, 2=Smear 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png Initialise
Sets up the data memory and draws the simulated LED cube on the panel. 
Fc9-void-icon.png - VOID Return



Property reference

Fc9-prop-icon.png Properties
Fc9-type-16-icon.png Channel
Channel selection 
Fc9-type-5-icon.png SDA
Pin used for SDA (data signal) 
Fc9-type-5-icon.png SCL
Pin used for SCL (clock signal) 
Fc9-type-16-icon.png Baud Select
Baud rate option selector 
Fc9-type-14-icon.png Baud Rate
Baud rate to be used 
Fc9-type-7-icon.png 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.  
Fc9-type-16-icon.png Number of Taps
 
Fc9-type-16-icon.png Address Bits
 
Fc9-type-7-icon.png Scope Traces
Selects if the component pin connections are automatically generated on the data recorder window or not. Yes: Automatically add the component pins to a group on the data recorder which will reflect the sim data during simultion. No: Do not show the pin signals on the data recorder window. 
Fc9-type-7-icon.png Console Data
Selects if the console data is automatically generated or not 
Fc9-type-16-icon.png API
Specifies the injector component on the panel to interact with to provide comms simulation. 
Fc9-conn-icon.png Connections
Fc9-conn-icon.png Simulations
Fc9-type-7-icon.png Simulate Comms