progress on GPIO example

This commit is contained in:
Kevin Hester 2020-12-07 10:17:24 +08:00
parent 6e8d220ad0
commit f38b8e3040
2 changed files with 9 additions and 8 deletions

View file

@ -33,7 +33,7 @@
- [remote_hardware.proto](#remote_hardware.proto)
- [HardwareMessage](#.HardwareMessage)
- [HardwareMessage.MessageType](#.HardwareMessage.MessageType)
- [HardwareMessage.Type](#.HardwareMessage.Type)
- [Scalar Value Types](#scalar-value-types)
@ -616,13 +616,14 @@ Also provides easy remote access to any GPIO.
In the future other remote hardware operations can be added based on user interest
(i.e. serial output, spi/i2c input/output).
FIXME - currently this feature is turned on by default which is dangerous because no security yet (beyond the channel
channel mechanism). It should be off by default and then protected based on some TBD mechanism (a special channel?)
FIXME - currently this feature is turned on by default which is dangerous because no security yet (beyond the
channel mechanism). It should be off by default and then protected based on some TBD mechanism (a special channel
once multichannel support is included?)
| Field | Type | Label | Description |
| ----- | ---- | ----- | ----------- |
| typ | [HardwareMessage.MessageType](#HardwareMessage.MessageType) | | What type of HardwareMessage is this? |
| typ | [HardwareMessage.Type](#HardwareMessage.Type) | | What type of HardwareMessage is this? |
| gpio_mask | [uint64](#uint64) | | What gpios are we changing. Not used for all MessageTypes, see MessageType for details |
| gpio_value | [uint64](#uint64) | | For gpios that were listed in gpio_mask as valid, what are the signal levels for those gpios. Not used for all MessageTypes, see MessageType for details |
@ -633,9 +634,9 @@ channel mechanism). It should be off by default and then protected based on som
<a name=".HardwareMessage.MessageType"></a>
<a name=".HardwareMessage.Type"></a>
### HardwareMessage.MessageType
### HardwareMessage.Type
| Name | Number | Description |

View file

@ -12,7 +12,7 @@ channel mechanism). It should be off by default and then protected based on som
once multichannel support is included?)
*/
message HardwareMessage {
enum MessageType {
enum Type {
/** Unset/unused */
UNSET = 0;
@ -37,7 +37,7 @@ message HardwareMessage {
}
/** What type of HardwareMessage is this? */
MessageType typ = 1;
Type typ = 1;
/** What gpios are we changing. Not used for all MessageTypes, see MessageType for details */
uint64 gpio_mask = 2;