Hello Community,
i’m playing with the Astro Binding and i want to use the getAzimuth(timeStamp) as described here:
when doing so, I´m getting the Info in the Log and Visual Studio Code shows an Error, but it is working as intended and I’m getting the correct value.
16:34:16.758 [INFO ] [del.core.internal.ModelRepositoryImpl] - Validation issues found in configuration model 'astro.rules', using it anyway:
The method getAzimuth(ThingActions, ZonedDateTime) from the type AstroActions refers to the missing type Object
If i understand the Source of the Astro Actions correct, then the return type of the function should be QuantityType<Angle>, which should be known. What do i miss?
the rule where it is used:
rule "Update Azimuth"
when
Item UpdateAzimuth received command ON
then
val sunActions = getActions("astro","astro:sun:home")
if(null === sunActions) {
logInfo("actions", "sunActions not found, check thing ID")
return
} else {
val sunSetEvent = "SUN_SET"
val sunRiseEvent = "SUN_RISE"
val today = ZonedDateTime.now
val sunSetEventTime = sunActions.getEventTime(sunSetEvent,today,"START")
val sunRiseEventTime = sunActions.getEventTime(sunRiseEvent,today,"START")
val sunSetAzimuth = sunActions.getAzimuth(sunSetEventTime)
val sunRiseAzimuth = sunActions.getAzimuth(sunRiseEventTime)
SunsetPositionAzimuth.sendCommand(sunSetAzimuth.toBigDecimal)
SunrisePositionAzimuth.sendCommand(sunRiseAzimuth.toBigDecimal)
}
UpdateAzimuth.sendCommand(OFF)
end