mirror of
https://github.com/PepperDash/Essentials.git
synced 2026-02-17 13:45:01 +00:00
Updated Debugging (markdown)
17
Debugging.md
17
Debugging.md
@@ -56,6 +56,8 @@ Debug.Console(0, Debug.ErrorLogLevel.Notice, "Hello World");
|
|||||||
```
|
```
|
||||||
|
|
||||||
## Console Commands
|
## Console Commands
|
||||||
|
The following console commands all perform actions on devices that have been registered with the `PepperDash.Essentials.Core.DeviceManager` static class
|
||||||
|
|
||||||
### Appdebug:[slot] [0-2]
|
### Appdebug:[slot] [0-2]
|
||||||
Gets or sets the current debug level where 0 is the lowest setting and 2 is the most verbose
|
Gets or sets the current debug level where 0 is the lowest setting and 2 is the most verbose
|
||||||
|
|
||||||
@@ -191,16 +193,21 @@ RMC3>devmethods:1 cec-1-cec
|
|||||||
RMC3>
|
RMC3>
|
||||||
```
|
```
|
||||||
### Devjson:[slot] [JSON formatted object {"deviceKey", "methodName", "params"}]
|
### Devjson:[slot] [JSON formatted object {"deviceKey", "methodName", "params"}]
|
||||||
Used in conjunction with devmethods, this command allows any of the public methods to be called from console and the appropriate arguments can be passed in to the method via a JSON object:
|
Used in conjunction with devmethods, this command allows any of the public methods to be called from console and the appropriate arguments can be passed in to the method via a JSON object.
|
||||||
|
|
||||||
|
This command is most useful for testing without access to hardware as it allows both simulated input and output for a device.
|
||||||
|
|
||||||
Example:
|
Example:
|
||||||
```
|
```
|
||||||
// This command will call the SendText(string text) method on the device with the Key 'cec-1-cec'
|
// This command will call the SendText(string text) method on the
|
||||||
// and pass in "hello world" as the argument parameter. On this particular device, it would cause
|
// device with the Key 'cec-1-cec' and pass in "hello world" as the
|
||||||
|
// argument parameter. On this particular device, it would cause
|
||||||
// the string to be sent via the CEC Transmit
|
// the string to be sent via the CEC Transmit
|
||||||
devjson:1 {"deviceKey":"cec-1-cec", "methodName":"SendText", "params": ["hello world\r"]}
|
RMC3>devjson:1 {"deviceKey":"cec-1-cec", "methodName":"SendText", "params": ["hello world\r"]}
|
||||||
|
|
||||||
// This command will call SimulateReceive(string text) on the device with Key 'cec-1-cec'
|
// This command will call SimulateReceive(string text) on the device with Key 'cec-1-cec'
|
||||||
// This would simulate receiving data on the CEC port of the DM-TX-201-C's HDMI input
|
// This would simulate receiving data on the CEC port of the DM-TX-201-C's HDMI input
|
||||||
devjson:1 {"deviceKey":"cec-1-cec", "methodName":"SimulateReceive", "params": ["hello citizen of Earth\r"]}
|
RMC3>devjson:1 {"deviceKey":"cec-1-cec", "methodName":"SimulateReceive", "params": ["hello citizen of Earth\r"]}
|
||||||
```
|
```
|
||||||
|
|
||||||
|
For additional examples, see this [file](https://github.com/PepperDash/Essentials/blob/master/devjson%20commands.json).
|
||||||
Reference in New Issue
Block a user