Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Power switches preset #4441

Closed
flacombe opened this issue Oct 14, 2017 · 5 comments
Closed

Power switches preset #4441

flacombe opened this issue Oct 14, 2017 · 5 comments
Labels
help wanted For intermediate contributors, requires investigation or knowledge of iD code preset An issue with an OpenStreetMap preset or tag

Comments

@flacombe
Copy link

flacombe commented Oct 14, 2017

Hi,

Last year, a proposal was adopted to extend power=switch features on OSM.
https://wiki.openstreetmap.org/wiki/Proposed_features/Power_switching_extension
A key switch=* can be used on power=switch objects and take 4 values : disconnector, circuit_breaker, mechanical and earthing
https://wiki.openstreetmap.org/wiki/Key:switch

According to ​https://wiki.openstreetmap.org/wiki/Tag:power%3Dswitch
It may be useful to create a preset for power switches, and ask mappers for following tags

  • switch
  • cables
  • operator
  • voltage
  • ref

As power=transformer, a switch can also be on top of a pole.
In this case (and only), switch=* will be used with power=pole (and not power=switch)
It may be good to create a specific preset "pole with switch" and ask for same tags than standalone switches.
Since some keys can be used both for pole and switches, some namespaces may be useful :
ref => pole:ref and switch:ref

As a side business, it may be good to add a validation rule to warn about any power=switch without switch key.

Let me know if you have any issue to take care of this
Thanks in advance :)

@JamesKingdom JamesKingdom added the preset An issue with an OpenStreetMap preset or tag label Oct 15, 2017
@bhousel
Copy link
Member

bhousel commented Oct 15, 2017

Most of this seems ok..

As power=transformer, a switch can also be on top of a pole.
In this case (and only), switch=* will be used with power=pole (and not power=switch)
It may be good to create a specific preset "pole with switch" and ask for same tags than standalone switches.

Let's not do this part ☝️ Switches should always be power=switch. If people want to put it on a pole, they can use location=pole or something.

@bhousel bhousel added Hacktoberfest help wanted For intermediate contributors, requires investigation or knowledge of iD code labels Oct 15, 2017
@flacombe
Copy link
Author

Let's not do this part ☝️ Switches should always be power=switch. If people want to put it on a pole, they can use location=pole or something.

I'm afraid not
How can we use power=pole and power=switch on the same node ?
This is intended for such objects : https://www.openstreetmap.org/node/2419117926

At least, this is the reviewed tagging

@bhousel
Copy link
Member

bhousel commented Oct 15, 2017

How can we use power=pole and power=switch on the same node ?

We can't.. So people should just make 2 nodes - 1 node for the pole, and 1 node just next to the pole for the device.

@flacombe
Copy link
Author

flacombe commented Oct 15, 2017

We can't.. So people should just make 2 nodes - 1 node for the pole, and 1 node just next to the pole for the device.

This won't match reality
Creating a node beside the pole for the switch may indicate the switch is beside the pole while it is actually on it.
We are discussing about such things : https://auvergne-rhone-alpes.lpo.fr/images/cna/pylone_interrupteur.jpg
While other stuff like this exists : https://wiki.openstreetmap.org/wiki/File:Power_63kV_dual_bay_disconnector_circuitbreaker.jpg where a dedicated power=switch node is relevant.

A relation involving the line and the pole node may also be created. This will add a lot of complexity to data while power=pole + switch=* makes sense.

And there are dozen of objects described like this currently. It takes years to change this

@bhousel
Copy link
Member

bhousel commented Oct 26, 2017

@octagonal if you want to try this issue, we're looking for a new "Power Switch" preset:

  • copy data/presets/presets/power/transformer.json to data/presets/presets/power/switch.json
  • edit that new file to
    • change the "name" to "Power Switch"
    • change the "tags" to "power": "switch"
    • change the array of fields to just include switch, cables, voltage, location, operator, ref
  • some of those fields don't exist yet, so you will need to create .json files for them too:
    • switch: copy data/presets/fields/windings/configuration.json to data/presets/fields/switch.json
      • This will be a combo field with a fixed list of values to choose from..
      • edit that new file and change details..
    • cables: copy data/presets/fields/windings.json to data/presets/fields/cables.json
      • This will be a numeric field with a spinner so the user can increment/decrement..
      • edit that new file and change details..
    • voltage: copy data/presets/fields/voltage/primary.json to data/presets/fields/voltage.json
      • This will be a combo field which will offer the user commonly used values to choose from..
      • edit that new file and change details..
  • npm run build

I left out some of the "change details" parts above, but try it and let me know if you need more info! 🙇

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted For intermediate contributors, requires investigation or knowledge of iD code preset An issue with an OpenStreetMap preset or tag
Projects
None yet
Development

No branches or pull requests

3 participants