Class CircuitPythonREPL
Provides functionality for circuit python boards via the REPL console
Inheritance
System.Object
CircuitPythonREPL
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Assembly: ElatecFCT.dll
Syntax
public class CircuitPythonREPL : IControlFCT, ISignal
Constructors
View Source
CircuitPythonREPL()
Initializes a new instance of the ElatecFCT.Hardware.CircuitPythonREPL search for port automaticaly
Declaration
public CircuitPythonREPL()
View Source
CircuitPythonREPL(String)
Initializes a new instance of the ElatecFCT.Hardware.CircuitPythonREPL using a serial port
Declaration
public CircuitPythonREPL(string port)
Parameters
Type |
Name |
Description |
System.String |
port |
|
Properties
View Source
Busy
Declaration
public Signal Busy { get; set; }
Property Value
View Source
Comm
Get or set the serial port for the board
Declaration
public SerialPort Comm { get; set; }
Property Value
Type |
Description |
System.IO.Ports.SerialPort |
|
View Source
Error
Declaration
public Signal Error { get; set; }
Property Value
View Source
GPIO16
Declaration
public Signal GPIO16 { get; set; }
Property Value
View Source
GPIO17
Declaration
public Signal GPIO17 { get; set; }
Property Value
View Source
GPIO18
Declaration
public Signal GPIO18 { get; set; }
Property Value
View Source
IsBusy
Declaration
public bool IsBusy { get; set; }
Property Value
Type |
Description |
System.Boolean |
|
View Source
IsError
Declaration
public bool IsError { get; set; }
Property Value
Type |
Description |
System.Boolean |
|
View Source
IsOK
Declaration
public bool IsOK { get; set; }
Property Value
Type |
Description |
System.Boolean |
|
View Source
IsReady
Declaration
public bool IsReady { get; set; }
Property Value
Type |
Description |
System.Boolean |
|
View Source
IsTestStart
Declaration
public bool IsTestStart { get; }
Property Value
Type |
Description |
System.Boolean |
|
View Source
OK
Declaration
public Signal OK { get; set; }
Property Value
View Source
Ready
Declaration
public Signal Ready { get; set; }
Property Value
View Source
Start
Declaration
public Signal Start { get; set; }
Property Value
Methods
View Source
ClearIO(Byte[])
Declaration
public void ClearIO(byte[] io)
Parameters
Type |
Name |
Description |
System.Byte[] |
io |
|
View Source
Close()
Declaration
View Source
InitGPIO()
Init GPIOs for FCT controler
Declaration
View Source
Open()
Open serial port and start circuit python REPL
Declaration
View Source
ReadIO(Byte[])
Declaration
public bool ReadIO(byte[] io)
Parameters
Type |
Name |
Description |
System.Byte[] |
io |
|
Returns
Type |
Description |
System.Boolean |
|
View Source
ReadIoDirOutput(Byte[])
Declaration
public bool ReadIoDirOutput(byte[] io)
Parameters
Type |
Name |
Description |
System.Byte[] |
io |
|
Returns
Type |
Description |
System.Boolean |
|
View Source
SearchPort()
Search for REPL CDC port (10 tries, 5 ms sleep = 50 ms max)
Declaration
public string SearchPort()
Returns
Type |
Description |
System.String |
|
View Source
SearchPort(Int32, Int32)
Search for CircuitPython CDC port
Declaration
public string SearchPort(int tries, int waitMS)
Parameters
Type |
Name |
Description |
System.Int32 |
tries |
|
System.Int32 |
waitMS |
|
Returns
Type |
Description |
System.String |
|
View Source
SetIO(Byte[])
Declaration
public void SetIO(byte[] io)
Parameters
Type |
Name |
Description |
System.Byte[] |
io |
|
View Source
SetIoHighZ(Byte[])
Declaration
public void SetIoHighZ(byte[] io)
Parameters
Type |
Name |
Description |
System.Byte[] |
io |
|
View Source
Declaration
public void SetIoInput(byte[] io)
Parameters
Type |
Name |
Description |
System.Byte[] |
io |
|
View Source
SetIoOutput(Byte[])
Declaration
public void SetIoOutput(byte[] io)
Parameters
Type |
Name |
Description |
System.Byte[] |
io |
|
View Source
WriteLine(String)
Write line and expect no response
Declaration
public void WriteLine(string codeLine)
Parameters
Type |
Name |
Description |
System.String |
codeLine |
command
|
Exceptions
Type |
Condition |
System.ApplicationException |
Response missmatch
|
View Source
WriteReadLine(String)
Write code line and read result. Use only if you expect a result
Declaration
public string WriteReadLine(string codeLine)
Parameters
Type |
Name |
Description |
System.String |
codeLine |
command
|
Returns
Type |
Description |
System.String |
result of command
|
Exceptions
Type |
Condition |
System.ApplicationException |
Response missmatch
|
Implements