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

[core] Added units kvarh and kvar #695

Merged
merged 1 commit into from
Apr 7, 2019
Merged

Conversation

Hilbrand
Copy link
Member

@Hilbrand Hilbrand commented Apr 3, 2019

Also simplified gravity unit.

Also simplified gravity unit.

Signed-off-by: Hilbrand Bouwkamp <[email protected]>
@hakan42
Copy link
Contributor

hakan42 commented Apr 4, 2019

Out of curiosity, how will those units be used? The description on wikiperia is not really informative for people like me who are not electrical engineers :)

@Hilbrand
Copy link
Member Author

Hilbrand commented Apr 4, 2019

Here is an explanation using the 🍺 analogy 😄
https://electrical-engineering-portal.com/beer-mug-and-power-factor

These units are used for a new smart meter thing. Where the meter gives those values.

@Hilbrand
Copy link
Member Author

Hilbrand commented Apr 6, 2019

@wborn or @cweitkamp can one of you have a look. It is now blocking my dsmr pr and thus blocking migrating the dsmr binding to bnd.

@@ -82,8 +84,8 @@

// Alphabetical ordered by Unit.
public static final Unit<Acceleration> METRE_PER_SQUARE_SECOND = addUnit(Units.METRE_PER_SQUARE_SECOND);
public static final Unit<Acceleration> STANDARD_GRAVITY = new TransformedUnit<>("gₙ",
Copy link
Contributor

Choose a reason for hiding this comment

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

Don't we loose the symbol "g" when applying this.

Copy link
Member

Choose a reason for hiding this comment

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

I think so. Rest looks good IMHO.

Copy link
Contributor

@cweitkamp cweitkamp left a comment

Choose a reason for hiding this comment

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

The label is assigned in

SimpleUnitFormat.getInstance().label(STANDARD_GRAVITY, "gₙ");

@cweitkamp cweitkamp merged commit 1d8b7be into openhab:master Apr 7, 2019
@cweitkamp cweitkamp added enhancement An enhancement or new feature of the Core UoM Units of Measurement labels Apr 7, 2019
@Hilbrand Hilbrand deleted the add_units branch April 7, 2019 09:15
@openhab-bot
Copy link
Collaborator

This pull request has been mentioned on openHAB Community. There might be relevant details there:

https://community.openhab.org/t/preparation-for-2-5m2/75738/1

@wborn wborn added this to the 2.5 milestone Jul 30, 2019
@cweitkamp cweitkamp changed the title Added units kvarh and kvar. [core] Added units kvarh and kvar Dec 7, 2019
Rosi2143 pushed a commit to Rosi2143/openhab-core that referenced this pull request Dec 26, 2020
splatch pushed a commit to ConnectorIO/copybara-hab-core that referenced this pull request Jul 11, 2023
Also simplified gravity unit.

Signed-off-by: Hilbrand Bouwkamp <[email protected]>
GitOrigin-RevId: 1d8b7be
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement An enhancement or new feature of the Core UoM Units of Measurement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants