Skip to content

Commit 0120fcc

Browse files
committed
docs: better optics in hal/basic
1 parent c42f908 commit 0120fcc

1 file changed

Lines changed: 28 additions & 28 deletions

File tree

docs/src/hal/basic-hal.adoc

Lines changed: 28 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ Flags may be one or more of the following:
113113

114114
-n:: name a component when it is a valid option for that component.
115115

116-
.loadusr Syntax and Examples
116+
.`loadusr` Syntax and Examples
117117
[source,{hal}]
118118
----
119119
loadusr <component> <options>
@@ -126,13 +126,13 @@ In English it means 'loadusr wait for name spindle component gs2_vfd name spindl
126126
[[sub:hal-net]]
127127
=== net(((HAL net,net)))
128128

129-
The command 'net' creates a 'connection' between a signal and one or more pins.
129+
The command `net` creates a 'connection' between a signal and one or more pins.
130130
If the signal does not exist net creates the new signal.
131131
This replaces the need to use the command newsig.
132-
The optional direction arrows '<=', '=>' and '<=>' make it easier to follow the logic when reading a 'net' command line and are not used by the net command.
132+
The optional direction arrows `<=`, `=>` and `<=>` make it easier to follow the logic when reading a `net` command line and are not used by the net command.
133133
The direction arrows must be separated by a space from the pin names.
134134

135-
.net Syntax and Example
135+
.`net` Syntax and Example
136136
[source,{hal}]
137137
----
138138
net signal-name pin-name <optional arrow> <optional second pin-name>
@@ -178,15 +178,15 @@ An I/O pin like encoder._N_.index-enable can be read or set as allowed by the co
178178
[[sub:hal-setp]]
179179
=== setp(((HAL setp,setp)))
180180

181-
The command 'setp' sets the value of a pin or parameter.
181+
The command `setp` sets the value of a pin or parameter.
182182
The valid values will depend on the type of the pin or parameter.
183183
It is an error if the data types do not match.
184184

185185
Some components have parameters that need to be set before use.
186186
Parameters can be set before use or while running as needed.
187187
You cannot use setp on a pin that is connected to a signal.
188188

189-
.setp Syntax and Example
189+
.`setp` Syntax and Example
190190
[source,{hal}]
191191
----
192192
setp <pin/parameter-name> <value>
@@ -196,9 +196,9 @@ setp parport.0.pin-08-out TRUE
196196
[[sub:hal-sets]]
197197
=== sets(((HAL sets,sets)))
198198

199-
The command 'sets' sets the value of a signal.
199+
The command `sets` sets the value of a signal.
200200

201-
.sets Syntax and Example:
201+
.`sets` Syntax and Example:
202202
[source,{hal}]
203203
----
204204
sets <signal-name> <value>
@@ -215,11 +215,11 @@ It is an error if:
215215
[[sub:hal-inlinkp]]
216216
=== unlinkp(((HAL unlinkp,unlinkp)))
217217

218-
The command 'unlinkp' unlinks a pin from the connected signal.
218+
The command `unlinkp` unlinks a pin from the connected signal.
219219
If no signal was connected to the pin prior running the command, nothing happens.
220-
The 'unlinkp' command is useful for trouble shooting.
220+
The `unlinkp` command is useful for trouble shooting.
221221

222-
.unlinkp syntax and Example
222+
.`unlinkp` Syntax and Example
223223
[source,{hal}]
224224
----
225225
unlinkp <pin-name>
@@ -236,7 +236,7 @@ These commands are included so older configurations will still work.
236236

237237
The command `linksp` creates a 'connection' between a signal and one pin.
238238

239-
.linksp Syntax and Example
239+
.`linksp` Syntax and Example
240240
[source,{hal}]
241241
----
242242
linksp <signal-name> <pin-name>
@@ -250,7 +250,7 @@ linksp X-step parport.0.pin-02-out
250250
The command `linkps` creates a 'connection' between one pin and one signal.
251251
It is the same as `linksp` but the arguments are reversed.
252252

253-
.linkps Syntax and Example
253+
.`linkps` Syntax and Example
254254
[source,{hal}]
255255
----
256256
linkps <pin-name> <signal-name>
@@ -264,7 +264,7 @@ linkps parport.0.pin-02-out X-Step
264264
the command `newsig` creates a new HAL signal by the name _<signame>_ and the data type of _<type>_.
265265
Type must be 'bit', 's32', 'u32' or 'float'. Error if _<signame>_ already exists.
266266

267-
.newsig Syntax and Example
267+
.`newsig` Syntax and Example
268268
[source,{hal}]
269269
----
270270
newsig <signame> <type>
@@ -365,7 +365,7 @@ and2.N.in1 (bit, in)
365365
and2.N.out (bit, out)
366366
----
367367

368-
.and2 Truth Table
368+
.`and2` Truth Table
369369
[width="90%",options="header"]
370370
|===
371371
|in0 | in1 | out
@@ -397,7 +397,7 @@ not.n.in (bit, in)
397397
not.n.out (bit, out)
398398
----
399399

400-
.not Truth Table
400+
.`not` Truth Table
401401
[width="90%",options="header"]
402402
|===
403403
|in | out
@@ -523,18 +523,18 @@ The weight ('weight') of bit 0 is 1, that of bit 2 is 4, so the sum is 5.
523523
.`weighted_sum` Example component Pin for weighted sums.
524524
[width="90%",options="header"]
525525
|===
526-
|Owner|Type |Dir |Value |Name
527-
|10 |bit |In |TRUE |wsum.0.bit.0.in
528-
|10 |s32 |I/O |1 |wsum.0.bit.0.weight
529-
|10 |bit |In |FALSE |wsum.0.bit.1.in
530-
|10 |s32 |I/O |2 |wsum.0.bit.1.weight
531-
|10 |bit |In |TRUE |wsum.0.bit.2.in
532-
|10 |s32 |I/O |4 |wsum.0.bit.2.weight
533-
|10 |bit |In |FALSE |wsum.0.bit.3.in
534-
|10 |s32 |I/O |8 |wsum.0.bit.3.weight
535-
|10 |bit |In |FALSE |wsum.0.hold
536-
|10 |s32 |I/O |0 |wsum.0.offset
537-
|10 |s32 |Out |5 |wsum.0.sum
526+
|Owner |Type |Dir |Value |Name
527+
|10 |bit |In |TRUE m|wsum.0.bit.0.in
528+
|10 |s32 |I/O |1 m|wsum.0.bit.0.weight
529+
|10 |bit |In |FALSE m|wsum.0.bit.1.in
530+
|10 |s32 |I/O |2 m|wsum.0.bit.1.weight
531+
|10 |bit |In |TRUE m|wsum.0.bit.2.in
532+
|10 |s32 |I/O |4 m|wsum.0.bit.2.weight
533+
|10 |bit |In |FALSE m|wsum.0.bit.3.in
534+
|10 |s32 |I/O |8 m|wsum.0.bit.3.weight
535+
|10 |bit |In |FALSE m|wsum.0.hold
536+
|10 |s32 |I/O |0 m|wsum.0.offset
537+
|10 |s32 |Out |5 m|wsum.0.sum
538538
|===
539539

540540
// vim: set syntax=asciidoc:

0 commit comments

Comments
 (0)