Skip to content

Commit

Permalink
remove train_id and block_id dependence in layout format
Browse files Browse the repository at this point in the history
also introduce layout version. In the future this needs to be smarter
closes #122
  • Loading branch information
Novakasa committed Aug 17, 2023
1 parent 070c8c1 commit 173f482
Show file tree
Hide file tree
Showing 11 changed files with 929 additions and 49 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
- Spacebar now triggers emergency stop. For the extra urgent emergencies.
- Added automatic level crossings. Add a crossing in the track inspector, assign motors to layout controller ports and have them automatically run based on train routes (https://github.com/Novakasa/brickrail/issues/146).
- Added debug color buffer and plot written to file after unexpected Marker (https://github.com/Novakasa/brickrail/issues/144)
- Trains and Blocks can now be renamed by clicking their names in the inspector (https://github.com/Novakasa/brickrail/issues/122).

### Fixed

Expand All @@ -22,6 +23,7 @@

### Changed

- Changed the internal ids for blocks and trains are now not the same as their names. This means old layout files will be converted. Issues with train positions might arise (https://github.com/Novakasa/brickrail/issues/122).
- Renamed "Sensor" to "Marker" and "Prior sensor" to "Reverse entry marker" in all user-facing contexts (https://github.com/Novakasa/brickrail/issues/135).
- ble-server log files will not be overwritten anymore (https://github.com/Novakasa/brickrail/issues/151)

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
{
"version": "1.0.0",
"devices": {
"trains": [
{
Expand Down Expand Up @@ -1631,7 +1632,6 @@
],
"blocks": [
{
"name": "block0",
"block_name": "block0",
"section": {
"tracks": [
Expand Down Expand Up @@ -1686,7 +1686,6 @@
}
},
{
"name": "block6_",
"block_name": "block6_",
"section": {
"tracks": [
Expand Down Expand Up @@ -1741,8 +1740,7 @@
}
},
{
"name": "block7_",
"block_name": "block7_",
"block_name": "block_upper_south",
"section": {
"tracks": [
{
Expand Down Expand Up @@ -1796,7 +1794,6 @@
}
},
{
"name": "block6",
"block_name": "block6",
"section": {
"tracks": [
Expand Down Expand Up @@ -1851,7 +1848,6 @@
}
},
{
"name": "block7",
"block_name": "block7",
"section": {
"tracks": [
Expand Down Expand Up @@ -1906,7 +1902,6 @@
}
},
{
"name": "block5",
"block_name": "block5",
"section": {
"tracks": [
Expand Down Expand Up @@ -1954,7 +1949,6 @@
}
},
{
"name": "block6__",
"block_name": "block6__",
"section": {
"tracks": [
Expand Down Expand Up @@ -2002,7 +1996,6 @@
}
},
{
"name": "block7__",
"block_name": "block7__",
"section": {
"tracks": [
Expand Down Expand Up @@ -2053,19 +2046,17 @@
"trains": [
{
"train_name": "train1",
"name": "train1",
"facing": 1,
"reversing_behavior": "off",
"color": "ff00b007",
"num_wagons": 4,
"random_targets": true,
"block_id": "block6__",
"block_id": "block0",
"blockindex": 0,
"ble_train": "city-green"
},
{
"train_name": "train-red",
"name": "train-red",
"facing": 1,
"reversing_behavior": "off",
"color": "ffff0000",
Expand All @@ -2077,13 +2068,12 @@
},
{
"train_name": "train2",
"name": "train2",
"facing": 1,
"reversing_behavior": "off",
"color": "ffff9500",
"num_wagons": 5,
"random_targets": true,
"block_id": "block7__",
"block_id": "block1",
"blockindex": 0,
"ble_train": "city-orange"
}
Expand Down
Loading

0 comments on commit 173f482

Please sign in to comment.