Skip to content

Commit

Permalink
SKA-490 default paths (#18)
Browse files Browse the repository at this point in the history
* SKA-490: update default paths in config files + update README

* SKA-490: uncomment gpiochips

* SKA-490: feedback took into account
  • Loading branch information
VKyllianAubry authored and GitHub Enterprise committed May 14, 2024
1 parent 4d572c4 commit 5ec2d62
Show file tree
Hide file tree
Showing 8 changed files with 24 additions and 22 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,5 @@
*.vector
/**/.run/
*.out
/adchips/
/chardevs/
6 changes: 3 additions & 3 deletions adapter/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ In order to match the above setup, you need to adapt Linux IO ``path`` attribute
# Running the Demos
Now is a good point to start the ``sil-kit-registry`` and the ``sil-kit-adapter-generic-linux-io``. In separate terminals:
```
./path/to/SilKit-x.y.z-$platform/SilKit/bin/sil-kit-registry --listen-uri 'silkit://0.0.0.0:8501'
/path/to/SilKit-x.y.z-$platform/SilKit/bin/sil-kit-registry --listen-uri 'silkit://0.0.0.0:8501'
./bin/sil-kit-adapter-generic-linux-io --log Debug --adapter-configuration ./adapter/demos/DevicesConfig.yaml
```
Expand Down Expand Up @@ -78,9 +78,9 @@ First you can start each demo in separte terminals:
You should see the following output in the GLIO Adapter window:
```
[2024-02-01 14:44:49.870] [SilKitAdapterGenericLinuxIO] [debug] New value received on toVoltage103
[2024-02-01 14:44:49.870] [SilKitAdapterGenericLinuxIO] [debug] Updating /home/dev/temp/adchip0/in_voltage103
[2024-02-01 14:44:49.870] [SilKitAdapterGenericLinuxIO] [debug] Updating ./adchips/adchip0/in_voltage103
[2024-02-01 14:44:55.738] [SilKitAdapterGenericLinuxIO] [debug] New value received on toFifo2
[2024-02-01 14:44:55.738] [SilKitAdapterGenericLinuxIO] [debug] Updating /home/dev/temp/chardevs/fifo2
[2024-02-01 14:44:55.738] [SilKitAdapterGenericLinuxIO] [debug] Updating ./chardevs/fifo2
[2024-02-01 14:44:55.738] [SilKitAdapterGenericLinuxIO] [debug] Serializing data and publishing on topic: fromFifo2
[2024-02-01 14:45:01.437] [SilKitAdapterGenericLinuxIO] [debug] New values received on topic: toGpiochip1Line2
[2024-02-01 14:45:01.437] [SilKitAdapterGenericLinuxIO] [debug] Updating gpiochip1 line 2
Expand Down
8 changes: 4 additions & 4 deletions adapter/demos/DevicesConfig.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
# | `-- direction
# 
advalues:
- path: "/path/to/adchips/adchip0/"
- path: "./adchips/adchip0/"
int16_t:
- files:
- name: in_voltage103
Expand All @@ -22,7 +22,7 @@ advalues:
topic_publish: fromVoltage15
- name: out_voltage32
topic_publish: fromVoltage32
- path: "/path/to/adchips/adchip1/"
- path: "./adchips/adchip1/"
uint8_t:
- files:
- name: PIN12/value
Expand All @@ -42,9 +42,9 @@ advalues:
# /path/to/chardevs/fifo2
#
chardevs:
- path: "/path/to/chardevs/fifo1"
- path: "./chardevs/fifo1"
topic_publish: fromFifo1
- path: "/path/to/chardevs/fifo2"
- path: "./chardevs/fifo2"
topic_publish: fromFifo2
topic_subscribe: toFifo2

Expand Down
10 changes: 5 additions & 5 deletions advalues/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ Each file can also be configured to deal with a specific data type. The handled
# Running the Demos
Now is a good point to start the ``sil-kit-registry`` and the ``sil-kit-adapter-generic-linux-io``. In separate terminals:
```
./path/to/SilKit-x.y.z-$platform/SilKit/bin/sil-kit-registry --listen-uri 'silkit://0.0.0.0:8501'
/path/to/SilKit-x.y.z-$platform/SilKit/bin/sil-kit-registry --listen-uri 'silkit://0.0.0.0:8501'
./bin/sil-kit-adapter-generic-linux-io --adapter-configuration ./advalues/demos/DevicesConfig.yaml --log Debug
```
Expand Down Expand Up @@ -106,19 +106,19 @@ The GLIO Adapter published the initial values, it means ``3`` is the initial val
On the GLIO Adapter terminal you should see two new lines:
```
[2024-01-31 14:49:00.116] [SilKitAdapterGenericLinuxIO] [debug] New value received on toVoltage103
[2024-01-31 14:49:00.116] [SilKitAdapterGenericLinuxIO] [debug] Updating /home/dev/temp/adchip0/in_voltage103
[2024-01-31 14:49:00.116] [SilKitAdapterGenericLinuxIO] [debug] Updating ./adchips/adchip0/in_voltage103
```

In your adchip0 folder you can see the updated value in ``in_voltage103``:
```
cat /path/to/adchips/adchip0/in_voltage103
cat ./adchips/adchip0/in_voltage103
3
```

Then you can update ``out_voltage32``:
```
echo 2 > /path/to/adchips/adchip0/out_voltage32
cat /path/to/adchips/adchip0/in_voltage103
echo 2 > ./adchips/adchip0/out_voltage32
cat ./adchips/adchip0/in_voltage103
2
```

Expand Down
4 changes: 2 additions & 2 deletions advalues/demos/DevicesConfig.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
# | `-- direction
# 
advalues:
- path: "/path/to/adchips/adchip0/"
- path: "./adchips/adchip0/"
int16_t:
- files:
- name: in_voltage103
Expand All @@ -22,7 +22,7 @@ advalues:
topic_publish: fromVoltage15
- name: out_voltage32
topic_publish: fromVoltage32
- path: "/path/to/adchips/adchip1/"
- path: "./adchips/adchip1/"
uint8_t:
- files:
- name: PIN12/value
Expand Down
10 changes: 5 additions & 5 deletions chardev/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ In order to match the above setup, you need to adapt the chardev ``path`` attrib
# Running the Demos
Now is a good point to start the ``sil-kit-registry`` and the ``sil-kit-adapter-generic-linux-io``. In separate terminals:
```
./path/to/SilKit-x.y.z-$platform/SilKit/bin/sil-kit-registry --listen-uri 'silkit://0.0.0.0:8501'
/path/to/SilKit-x.y.z-$platform/SilKit/bin/sil-kit-registry --listen-uri 'silkit://0.0.0.0:8501'
./bin/sil-kit-adapter-generic-linux-io --log Debug --adapter-configuration ./chardev/demos/DevicesConfig.yaml
```
Expand Down Expand Up @@ -91,20 +91,20 @@ The GLIO Adapter published the initial data, it means ``message1`` is the initia
On the GLIO Adapter window you should see three new lines:
```
[2024-02-01 10:17:59.853] [SilKitAdapterGenericLinuxIO] [debug] New value received on toFifo2
[2024-02-01 10:17:59.853] [SilKitAdapterGenericLinuxIO] [debug] Updating /path/to/chardevs/fifo2
[2024-02-01 10:17:59.853] [SilKitAdapterGenericLinuxIO] [debug] Updating ./chardevs/fifo2
[2024-02-01 10:17:59.853] [SilKitAdapterGenericLinuxIO] [debug] Serializing data and publishing on topic: fromFifo2
```

In your chardevs folder you can see the updated value in ``fifo2``:
```
cat /path/to/chardevs/fifo2
cat ./chardevs/fifo2
message1
```

Then you can update ``fifo1``:
```
echo "new message" > /path/to/chardevs/fifo1
cat /path/to/chardevs/fifo2
echo "new message" > ./chardevs/fifo1
cat ./chardevs/fifo2
new message
```

Expand Down
4 changes: 2 additions & 2 deletions chardev/demos/DevicesConfig.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
# /path/to/chardevs/fifo2
#
chardevs:
- path: "/path/to/chardevs/fifo1"
- path: "./chardevs/fifo1"
topic_publish: fromFifo1
- path: "/path/to/chardevs/fifo2"
- path: "./chardevs/fifo2"
topic_publish: fromFifo2
topic_subscribe: toFifo2
2 changes: 1 addition & 1 deletion gpio/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ By default the GPIO chips are located under ``/dev/gpiochipX`` (with X a number)
# Running the Demos
Now is a good point to start the ``sil-kit-registry`` and the ``sil-kit-adapter-generic-linux-io``. In separate terminals:
```
./path/to/SilKit-x.y.z-$platform/SilKit/bin/sil-kit-registry --listen-uri 'silkit://0.0.0.0:8501'
/path/to/SilKit-x.y.z-$platform/SilKit/bin/sil-kit-registry --listen-uri 'silkit://0.0.0.0:8501'
./bin/sil-kit-adapter-generic-linux-io --log Debug --adapter-configuration ./gpio/demos/DevicesConfig.yaml
```
Expand Down

0 comments on commit 5ec2d62

Please sign in to comment.