UWAGA: Strona oraz Forum Smart'ny Dom nie będzie dostępne 23 Grudnia 2024 ze względu na przenoszenie serwisu na mocniejszą maszynę.
W tym czasie polecam poświęcenie swojego czasu na pomoc partnerowi w przygotowaniu udanych Świąt 😉
Za niedogodności z góry przepraszam, admin
Hej
Robię pilota do oświetlenia na 8266 i mam błędy w konsoli po odebraniu info z esp
Odczyt który działa
Thing topic S1 "Switch" { Channels: Type string : state "S1" [ stateTopic="Switch/S1/state" ] } Thing topic S2 "Switch" { Channels: Type string : state "S2" [ stateTopic="Switch/S2/state"] } String S1_Switch "Sara S1" <my_suspend> {channel="mqtt:topic:Sw:S1:state"} String S2_Switch "Sara S2" <my_suspend> {channel="mqtt:topic:Sw:S2:state"}
Reguła też działa ale chyba tu jest problem
rule"Sw_S1" when Item S1_Switch changed to closed then { logInfo("Sw_S1","S1") OswDzien.sendCommand(ON) } end rule"Sw_S2" when Item S2_Switch changed to open then { logInfo("Sw_S2","S2") OswDzien.sendCommand(OFF) } end
Log
18:52:31.992 [INFO ] [openhab.event.ItemStateChangedEvent ] - Item 'S1_Switch' changed from closed to open 18:52:32.718 [ERROR] [b.client.write.events.WriteErrorEvent] - The error occurred during writing of data com.influxdb.exceptions.UnprocessableEntityException: failure writing points to database: partial write: field type conflict: input field "value" on measurement "S1_Switch" is type string, already exists as type integer dropped=2 at com.influxdb.internal.AbstractRestClient.responseToError(AbstractRestClient.java:116) ~[bundleFile:?] at com.influxdb.client.internal.AbstractWriteClient.toInfluxException(AbstractWriteClient.java:574) ~[bundleFile:?] at com.influxdb.client.internal.AbstractWriteClient.lambda$new$12(AbstractWriteClient.java:181) ~[bundleFile:?] at io.reactivex.internal.subscribers.LambdaSubscriber.onNext(LambdaSubscriber.java:65) [bundleFile:?] at io.reactivex.internal.operators.flowable.FlowableDoFinally$DoFinallySubscriber.onNext(FlowableDoFinally.java:84) [bundleFile:?] at io.reactivex.internal.operators.mixed.FlowableConcatMapMaybe$ConcatMapMaybeSubscriber.drain(FlowableConcatMapMaybe.java:284) [bundleFile:?] at io.reactivex.internal.operators.mixed.FlowableConcatMapMaybe$ConcatMapMaybeSubscriber.onNext(FlowableConcatMapMaybe.java:137) [bundleFile:?] at io.reactivex.internal.operators.mixed.FlowableConcatMapSingle$ConcatMapSingleSubscriber.drain(FlowableConcatMapSingle.java:279) [bundleFile:?] at io.reactivex.internal.operators.mixed.FlowableConcatMapSingle$ConcatMapSingleSubscriber.innerSuccess(FlowableConcatMapSingle.java:179) [bundleFile:?] at io.reactivex.internal.operators.mixed.FlowableConcatMapSingle$ConcatMapSingleSubscriber$ConcatMapSingleObserver.onSuccess(FlowableConcatMapSingle.java:317) [bundleFile:?] at io.reactivex.internal.operators.single.SingleMap$MapSingleObserver.onSuccess(SingleMap.java:64) [bundleFile:?] at io.reactivex.internal.operators.single.SingleMap$MapSingleObserver.onSuccess(SingleMap.java:64) [bundleFile:?] at io.reactivex.internal.operators.flowable.FlowableCollectSingle$CollectSubscriber.onComplete(FlowableCollectSingle.java:119) [bundleFile:?] at io.reactivex.internal.subscribers.BasicFuseableSubscriber.onComplete(BasicFuseableSubscriber.java:120) [bundleFile:?] at io.reactivex.internal.subscribers.BasicFuseableConditionalSubscriber.onComplete(BasicFuseableConditionalSubscriber.java:119) [bundleFile:?] at io.reactivex.internal.operators.flowable.FlowableGroupBy$State.checkTerminated(FlowableGroupBy.java:686) [bundleFile:?] at io.reactivex.internal.operators.flowable.FlowableGroupBy$State.drainNormal(FlowableGroupBy.java:626) [bundleFile:?] at io.reactivex.internal.operators.flowable.FlowableGroupBy$State.drain(FlowableGroupBy.java:558) [bundleFile:?] at io.reactivex.internal.operators.flowable.FlowableGroupBy$State.onComplete(FlowableGroupBy.java:548) [bundleFile:?] at io.reactivex.internal.operators.flowable.FlowableGroupBy$GroupedUnicast.onComplete(FlowableGroupBy.java:474) [bundleFile:?] at io.reactivex.internal.operators.flowable.FlowableGroupBy$GroupBySubscriber.onComplete(FlowableGroupBy.java:213) [bundleFile:?] at io.reactivex.processors.UnicastProcessor.checkTerminated(UnicastProcessor.java:430) [bundleFile:?] at io.reactivex.processors.UnicastProcessor.drainRegular(UnicastProcessor.java:314) [bundleFile:?] at io.reactivex.processors.UnicastProcessor.drain(UnicastProcessor.java:397) [bundleFile:?] at io.reactivex.processors.UnicastProcessor.onComplete(UnicastProcessor.java:487) [bundleFile:?] at io.reactivex.internal.operators.flowable.FlowableWindowBoundarySupplier$WindowBoundaryMainSubscriber.drain(FlowableWindowBoundarySupplier.java:254) [bundleFile:?] at io.reactivex.internal.operators.flowable.FlowableWindowBoundarySupplier$WindowBoundaryMainSubscriber.innerNext(FlowableWindowBoundarySupplier.java:166) [bundleFile:?] at io.reactivex.internal.operators.flowable.FlowableWindowBoundarySupplier$WindowBoundaryInnerSubscriber.onNext(FlowableWindowBoundarySupplier.java:316) [bundleFile:?] at io.reactivex.processors.PublishProcessor$PublishSubscription.onNext(PublishProcessor.java:360) [bundleFile:?] at io.reactivex.processors.PublishProcessor.onNext(PublishProcessor.java:243) [bundleFile:?] at io.reactivex.internal.operators.flowable.FlowableFlatMap$MergeSubscriber.tryEmit(FlowableFlatMap.java:282) [bundleFile:?] at io.reactivex.internal.operators.flowable.FlowableFlatMap$InnerSubscriber.onNext(FlowableFlatMap.java:668) [bundleFile:?] at io.reactivex.subscribers.SerializedSubscriber.onNext(SerializedSubscriber.java:100) [bundleFile:?] at io.reactivex.internal.operators.flowable.FlowableWindowTimed$WindowExactBoundedSubscriber.drainLoop(FlowableWindowTimed.java:498) [bundleFile:?] at io.reactivex.internal.operators.flowable.FlowableWindowTimed$WindowExactBoundedSubscriber$ConsumerIndexHolder.run(FlowableWindowTimed.java:579) [bundleFile:?] at io.reactivex.Scheduler$Worker$PeriodicTask.run(Scheduler.java:479) [bundleFile:?] at io.reactivex.internal.schedulers.ScheduledRunnable.run(ScheduledRunnable.java:66) [bundleFile:?] at io.reactivex.internal.schedulers.ScheduledRunnable.call(ScheduledRunnable.java:57) [bundleFile:?] at java.util.concurrent.FutureTask.run(FutureTask.java:264) [?:?] at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:304) [?:?] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) [?:?] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) [?:?] at java.lang.Thread.run(Thread.java:834) [?:?]
Gdzieś w sieci widziałem że ktoś konwertował lub usuwał z bazy ale jest to niejasne dla mnie
A próbowałeś usunąć Item S2_Switch i dodać ponownie?
Tak próbowałem usuwać z OH na chwilę problem sam się pojawił i sam znikł.
Widziałem że czasem ludziom pomaga usunięcie pozycji z bazy danych i ponowne wprowadzenie.