Skip to content

Commit

Permalink
Update register schema to conform to standard json
Browse files Browse the repository at this point in the history
  • Loading branch information
glopesdev committed Dec 13, 2023
1 parent 121b5b6 commit bd4d52a
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 21 deletions.
42 changes: 21 additions & 21 deletions schema/common.yml
Original file line number Diff line number Diff line change
Expand Up @@ -109,37 +109,37 @@ groupMasks:
OperationMode:
description: Specifies the operation mode of the device.
values:
Standby: {0, description: Disable all event reporting on the device.}
Active: {1, description: Event detection is enabled. Only enabled events are reported by the device.}
Speed: {3, description: The device enters speed mode.}
Standby: {value: 0, description: Disable all event reporting on the device.}
Active: {value: 1, description: Event detection is enabled. Only enabled events are reported by the device.}
Speed: {value: 3, description: The device enters speed mode.}
EnableFlag:
description: Specifies whether a specific register flag is enabled or disabled.
values:
Disabled: {0, description: Specifies that the flag is disabled.}
Enabled: {1, description: Specifies that the flag is enabled.}
Disabled: {value: 0, description: Specifies that the flag is disabled.}
Enabled: {value: 1, description: Specifies that the flag is enabled.}
LedState:
description: Specifies the state of an LED on the device.
values:
Off: {0, description: Specifies that the LED is off.}
On: {1, description: Specifies that the LED is on.}
Off: {value: 0, description: Specifies that the LED is off.}
On: {value: 1, description: Specifies that the LED is on.}
bitMasks:
ResetFlags:
description: Specifies the behavior of the non-volatile registers when resetting the device.
bits:
None: {0, description: All reset flags are cleared.}
RestoreDefault: {0x1, description: The device will boot with all the registers reset to their default factory values.}
RestoreEeprom: {0x2, description: The device will boot and restore all the registers to the values stored in non-volatile memory.}
Save: {0x4, description: The device will boot and save all the current register values to non-volatile memory.}
RestoreName: {0x8, description: The device will boot with the default device name.}
BootFromDefault: {0x40, description: Specifies that the device has booted from default factory values.}
BootFromEeprom: {0x80, description: Specifies that the device has booted from non-volatile values stored in EEPROM.}
None: {value: 0, description: All reset flags are cleared.}
RestoreDefault: {value: 0x1, description: The device will boot with all the registers reset to their default factory values.}
RestoreEeprom: {value: 0x2, description: The device will boot and restore all the registers to the values stored in non-volatile memory.}
Save: {value: 0x4, description: The device will boot and save all the current register values to non-volatile memory.}
RestoreName: {value: 0x8, description: The device will boot with the default device name.}
BootFromDefault: {value: 0x40, description: Specifies that the device has booted from default factory values.}
BootFromEeprom: {value: 0x80, description: Specifies that the device has booted from non-volatile values stored in EEPROM.}
ClockConfigurationFlags:
description: Specifies configuration flags for the device synchronization clock.
bits:
None: {0, description: All clock configuration flags are cleared.}
ClockRepeater: {0x1, description: "The device will repeat the clock synchronization signal to the clock output connector, if available."}
ClockGenerator: {0x2, description: "The device resets and generates the clock synchronization signal on the clock output connector, if available."}
RepeaterCapability: {0x8, description: Specifies the device has the capability to repeat the clock synchronization signal to the clock output connector.}
GeneratorCapability: {0x10, description: Specifies the device has the capability to generate the clock synchronization signal to the clock output connector.}
ClockUnlock: {0x40, description: The device will unlock the timestamp register counter and will accept commands to set new timestamp values.}
ClockLock: {0x80, description: The device will lock the timestamp register counter and will not accept commands to set new timestamp values.}
None: {value: 0, description: All clock configuration flags are cleared.}
ClockRepeater: {value: 0x1, description: "The device will repeat the clock synchronization signal to the clock output connector, if available."}
ClockGenerator: {value: 0x2, description: "The device resets and generates the clock synchronization signal on the clock output connector, if available."}
RepeaterCapability: {value: 0x8, description: Specifies the device has the capability to repeat the clock synchronization signal to the clock output connector.}
GeneratorCapability: {value: 0x10, description: Specifies the device has the capability to generate the clock synchronization signal to the clock output connector.}
ClockUnlock: {value: 0x40, description: The device will unlock the timestamp register counter and will accept commands to set new timestamp values.}
ClockLock: {value: 0x80, description: The device will lock the timestamp register counter and will not accept commands to set new timestamp values.}
5 changes: 5 additions & 0 deletions schema/registers.json
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,16 @@
{
"type": "object",
"properties": {
"value": {
"description": "Specifies the numerical mask value.",
"type": "integer"
},
"description": {
"description": "Specifies a summary description of the mask value function.",
"type": "string"
}
},
"required": ["value"],
"additionalProperties": false
}
]
Expand Down

1 comment on commit bd4d52a

@bruno-f-cruz
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.