Name | Description |
---|---|
Not | Not Logic |
And | And logic with multiple input and one output |
Nand | Nand logic with multiple input and one output |
Or | Or logic with multiple input and one output |
Nor | Nor logic with multiple input and one output |
Xor | Xor logic with multiple input and one output |
Xnor | Xnor logic with multiple input and one output |
Not with 1 input value, without delay.
Extends from D.Interfaces.SISO (Single input, single output).
Type | Name | Description |
---|---|---|
input DigitalInput | x | Connector of Digital input signal |
output DigitalOutput | y | Connector of Digital output signal |
model Not "Not Logic" import D = Modelica.Electrical.Digital; import L = Modelica.Electrical.Digital.Interfaces.Logic; extends D.Interfaces.SISO; protected D.Interfaces.Logic auxiliary(start=L.'0', fixed=true); equation auxiliary = D.Tables.NotTable[x]; y = pre(auxiliary);end Not;
And with n input values, without delay.
Extends from D.Interfaces.MISO (Multiple input - single output).
Type | Name | Default | Description |
---|---|---|---|
Integer | n | 2 | Number of inputs |
Type | Name | Description |
---|---|---|
input DigitalInput | x[n] | Connector of Digital input signal vector |
output DigitalOutput | y | Connector of Digital output signal |
model And "And logic with multiple input and one output" import D = Modelica.Electrical.Digital; import L = Modelica.Electrical.Digital.Interfaces.Logic; extends D.Interfaces.MISO; protected D.Interfaces.Logic auxiliary[n](each start=L.'U', each fixed=true); equation auxiliary[1] = x[1]; for i in 1:n - 1 loop auxiliary[i + 1] = D.Tables.AndTable[auxiliary[i], x[i + 1]]; end for; y = pre(auxiliary[n]);end And;
Nand with n input values, without delay.
Extends from D.Interfaces.MISO (Multiple input - single output).
Type | Name | Default | Description |
---|---|---|---|
Integer | n | 2 | Number of inputs |
Type | Name | Description |
---|---|---|
input DigitalInput | x[n] | Connector of Digital input signal vector |
output DigitalOutput | y | Connector of Digital output signal |
model Nand "Nand logic with multiple input and one output" import D = Modelica.Electrical.Digital; import L = Modelica.Electrical.Digital.Interfaces.Logic; extends D.Interfaces.MISO; protected D.Interfaces.Logic auxiliary[n](each start=L.'U', each fixed=true); equation auxiliary[1] = x[1]; for i in 1:n - 1 loop auxiliary[i + 1] = D.Tables.AndTable[auxiliary[i], x[i + 1]]; end for; y = pre(D.Tables.NotTable[auxiliary[n]]);end Nand;
Or with n input values, without delay.
Extends from D.Interfaces.MISO (Multiple input - single output).
Type | Name | Default | Description |
---|---|---|---|
Integer | n | 2 | Number of inputs |
Type | Name | Description |
---|---|---|
input DigitalInput | x[n] | Connector of Digital input signal vector |
output DigitalOutput | y | Connector of Digital output signal |
model Or "Or logic with multiple input and one output" import D = Modelica.Electrical.Digital; import L = Modelica.Electrical.Digital.Interfaces.Logic; extends D.Interfaces.MISO; protected D.Interfaces.Logic auxiliary[n](each start=L.'U', each fixed=true); equation auxiliary[1] = x[1]; for i in 1:n - 1 loop auxiliary[i + 1] = D.Tables.OrTable[auxiliary[i], x[i + 1]]; end for; y = pre(auxiliary[n]);end Or;
Nor with n input values, without delay.
Extends from D.Interfaces.MISO (Multiple input - single output).
Type | Name | Default | Description |
---|---|---|---|
Integer | n | 2 | Number of inputs |
Type | Name | Description |
---|---|---|
input DigitalInput | x[n] | Connector of Digital input signal vector |
output DigitalOutput | y | Connector of Digital output signal |
model Nor "Nor logic with multiple input and one output" import D = Modelica.Electrical.Digital; import L = Modelica.Electrical.Digital.Interfaces.Logic; extends D.Interfaces.MISO; protected D.Interfaces.Logic auxiliary[n](each start=L.'U', each fixed=true); equation auxiliary[1] = x[1]; for i in 1:n - 1 loop auxiliary[i + 1] = D.Tables.OrTable[auxiliary[i], x[i + 1]]; end for; y = pre(D.Tables.NotTable[auxiliary[n]]);end Nor;
Xor with n input values, without delay.
Extends from D.Interfaces.MISO (Multiple input - single output).
Type | Name | Default | Description |
---|---|---|---|
Integer | n | 2 | Number of inputs |
Type | Name | Description |
---|---|---|
input DigitalInput | x[n] | Connector of Digital input signal vector |
output DigitalOutput | y | Connector of Digital output signal |
model Xor "Xor logic with multiple input and one output" import D = Modelica.Electrical.Digital; import L = Modelica.Electrical.Digital.Interfaces.Logic; extends D.Interfaces.MISO; protected D.Interfaces.Logic auxiliary[n](each start=L.'U', each fixed=true); equation auxiliary[1] = x[1]; for i in 1:n - 1 loop auxiliary[i + 1] = D.Tables.XorTable[auxiliary[i], x[i + 1]]; end for; y = pre(auxiliary[n]);end Xor;
XNor with n input values, without delay.
Extends from D.Interfaces.MISO (Multiple input - single output).
Type | Name | Default | Description |
---|---|---|---|
Integer | n | 2 | Number of inputs |
Type | Name | Description |
---|---|---|
input DigitalInput | x[n] | Connector of Digital input signal vector |
output DigitalOutput | y | Connector of Digital output signal |
model Xnor "Xnor logic with multiple input and one output" import D = Modelica.Electrical.Digital; import L = Modelica.Electrical.Digital.Interfaces.Logic; extends D.Interfaces.MISO; protected D.Interfaces.Logic auxiliary[n](each start=L.'U', each fixed=true); equation auxiliary[1] = x[1]; for i in 1:n - 1 loop auxiliary[i + 1] = D.Tables.XorTable[auxiliary[i], x[i + 1]]; end for; y = pre(D.Tables.NotTable[auxiliary[n]]);end Xnor;