Navigation

    • Register
    • Login
    • Search
    • OpenHardware.io
    • Categories
    • Recent
    • Tags
    • Popular
    1. Home
    2. doctor64
    • Profile
    • Following
    • Followers
    • Topics
    • Posts
    • Best
    • Groups

    doctor64

    @doctor64

    4
    Reputation
    29
    Posts
    1036
    Profile views
    0
    Followers
    0
    Following
    Joined Last Online

    doctor64 Follow

    Best posts made by doctor64

    • IKEA Varv lamp and MySensors

      Hello!
      Let me introduce simple project - MySensors control for IKEA Varv lamp. http://www.ikea.com/us/en/catalog/products/70280709/
      Used hardware:

      • Arduino Pro Mini 5v
      • nrf24L01+ module
      • solid state relay https://www.aliexpress.com/item/5v-1-Channel-OMRON-SSR-G3MB-202P-Solid-State-Relay-Module/32545508200.html
      • 5V to 3.3V converter based on LM1117 https://www.aliexpress.com/item/LM1117-AMS1117-4-5-7V-turn-3-3V-DC-DC-Step-down-Power-Supply-Module-For/32588261370.html
      • piece of prototype board, wires, etc

      Disassemble lamp: remove shade, disassemble bulb holder to get access to switch and wiring, remove cover from base (note four screws hidden under rubber pads)
      0_1504117110134_20170826_141344.jpg
      and get access to internals
      0_1504117769624_20170826_141515.jpg
      Remove mains wires from switch, connect it directly to lamp bulb holder, connect additional wires to switch to use it wits MySensors and route new wires throw pipe stand to bottom part
      0_1504117864798_20170826_195636.jpg
      Open cover of usb charger (be careful and do not damage the board)
      0_1504117979585_20170826_162900.jpg
      solder wires for powering arduino to usb ground and +5v

      Connection between nrf24L01+ and arduino pretty standard, i use piece of prototyping board to hold radio module and voltage converter together. This sub-assembly and arduino pro mini fits perfectly into base of lamp, just cut a little for wires pass freely.
      0_1504118652007_20170827_001716-1.jpg
      Relay module little modified to fit into lamp base - relay de-soldered, pins bend to 90 degree and relay soldered from other side of board, terminals for control signals replaced with pin connectors.
      0_1504118812401_20170827_001734.jpg
      Relay connected to arduino pin 3, switch to pin 4 .
      Because this project should have a wife compatibility mode 🙂 switch was used not as on/off switch, but as a trigger, lamp switch state on switch change, not on switch position.

      Comments and suggestion is welkomed, and sorry for my not-so-good English.

      Successfully used over a week in my home, using OpenHab2 and ethernet gateway.
      Code, if somebody interest, here
      0_1504119175102_IkeaLamp.ino

      posted in My Project
      doctor64
      doctor64

    Latest posts made by doctor64

    • RE: openHAB 2.2 binding

      @timo Looks like new binding no more support reporting of battery voltage from sensors, or I missed something?

      posted in OpenHAB
      doctor64
      doctor64
    • RE: openHAB 2.0 binding

      @andreacioni All mySensors item defined using auto-discovery, so no things file in configuration. I'm think you mean this file? 0_1506175698221_org.eclipse.smarthome.core.thing.Thing.json

      posted in OpenHAB
      doctor64
      doctor64
    • RE: openHAB 2.0 binding

      @TimO just updated to version 2.2.0.201708090807 of binding and get exception in network check

      22:41:33.015 [DEBUG] [rsAbstractConnection$MySensorsWriter] - Sending to MySensors: 0;0;3;0;2;
      22:41:33.029 [DEBUG] [rsAbstractConnection$MySensorsReader] - Message from gateway received: 0;255;3;0;2;2.1.1
      22:41:36.015 [DEBUG] [ateway.MySensorsNetworkSanityChecker] - Network sanity check: PASSED
      22:41:36.015 [DEBUG] [ateway.MySensorsNetworkSanityChecker] - Sending I_HEARTBEAT_REQUESTs
      22:41:36.016 [DEBUG] [rsAbstractConnection$MySensorsWriter] - Sending to MySensors: 0;255;3;0;18;
      22:41:36.032 [DEBUG] [rsAbstractConnection$MySensorsReader] - Message from gateway received: 0;255;3;0;22;436674305
      22:41:36.116 [DEBUG] [rsAbstractConnection$MySensorsWriter] - Sending to MySensors: 1;255;3;0;18;
      22:41:36.217 [DEBUG] [rsAbstractConnection$MySensorsWriter] - Sending to MySensors: 2;255;3;0;18;
      22:41:36.317 [DEBUG] [rsAbstractConnection$MySensorsWriter] - Sending to MySensors: 3;255;3;0;18;
      22:41:36.398 [DEBUG] [rsAbstractConnection$MySensorsReader] - Message from gateway received: 3;255;3;0;22;717683
      22:41:36.418 [DEBUG] [rsAbstractConnection$MySensorsWriter] - Sending to MySensors: 4;255;3;0;18;
      22:41:36.518 [DEBUG] [rsAbstractConnection$MySensorsWriter] - Sending to MySensors: 5;255;3;0;18;
      22:41:36.619 [DEBUG] [rsAbstractConnection$MySensorsWriter] - Sending to MySensors: 6;255;3;0;18;
      22:41:36.652 [DEBUG] [rsAbstractConnection$MySensorsReader] - Message from gateway received: 5;255;3;0;22;9428217
      22:41:36.683 [DEBUG] [rsAbstractConnection$MySensorsReader] - Message from gateway received: 6;255;3;0;22;3111897
      22:41:39.016 [DEBUG] [ateway.MySensorsNetworkSanityChecker] - Node 1 request heartbreat answer, missing null of 10
      22:41:39.016 [ERROR] [ateway.MySensorsNetworkSanityChecker] - Exception in network sanity thread checker
      java.lang.NullPointerException
      	at org.openhab.binding.mysensors.internal.gateway.MySensorsNetworkSanityChecker.checkHeartbeatsResponse(MySensorsNetworkSanityChecker.java:178)[195:org.openhab.binding.mysensors:2.2.0.201708090807]
      	at org.openhab.binding.mysensors.internal.gateway.MySensorsNetworkSanityChecker.run(MySensorsNetworkSanityChecker.java:122)[195:org.openhab.binding.mysensors:2.2.0.201708090807]
      	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)[:1.8.0_144]
      	at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308)[:1.8.0_144]
      	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180)[:1.8.0_144]
      	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294)[:1.8.0_144]
      	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)[:1.8.0_144]
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)[:1.8.0_144]
      	at java.lang.Thread.run(Thread.java:748)[:1.8.0_144]
      
      
      posted in OpenHAB
      doctor64
      doctor64
    • RE: IKEA Varv lamp and MySensors

      Hmm, for some reason link to code does not working, so, if anybody interested, here on github:
      link text

      posted in My Project
      doctor64
      doctor64
    • RE: How to build an overridable MySensors relay based device (e.g. lamp with manual switch)

      @anonymouslemming Hmm, you wish to use existing switch on mains cord? Or have some socket block with control is enough? I have use old one-for-all remote-controller socket for that - it have button, place for LED, nice case and i put inside arduino pro mini and 5 volt supply, using existing relay.
      alt text

      You are from Great Britain, right? So you have different power socket, but, may be you can find something similar?

      posted in Hardware
      doctor64
      doctor64
    • RE: How to build an overridable MySensors relay based device (e.g. lamp with manual switch)

      @anonymouslemming Sorry for self-advertising, but i'm think my project https://forum.mysensors.org/topic/7417/ikea-varv-lamp-and-mysensors exactly what you wish - lamp with local control and, of course, OpenHab status automatically updated on flick a switch.

      posted in Hardware
      doctor64
      doctor64
    • IKEA Varv lamp and MySensors

      Hello!
      Let me introduce simple project - MySensors control for IKEA Varv lamp. http://www.ikea.com/us/en/catalog/products/70280709/
      Used hardware:

      • Arduino Pro Mini 5v
      • nrf24L01+ module
      • solid state relay https://www.aliexpress.com/item/5v-1-Channel-OMRON-SSR-G3MB-202P-Solid-State-Relay-Module/32545508200.html
      • 5V to 3.3V converter based on LM1117 https://www.aliexpress.com/item/LM1117-AMS1117-4-5-7V-turn-3-3V-DC-DC-Step-down-Power-Supply-Module-For/32588261370.html
      • piece of prototype board, wires, etc

      Disassemble lamp: remove shade, disassemble bulb holder to get access to switch and wiring, remove cover from base (note four screws hidden under rubber pads)
      0_1504117110134_20170826_141344.jpg
      and get access to internals
      0_1504117769624_20170826_141515.jpg
      Remove mains wires from switch, connect it directly to lamp bulb holder, connect additional wires to switch to use it wits MySensors and route new wires throw pipe stand to bottom part
      0_1504117864798_20170826_195636.jpg
      Open cover of usb charger (be careful and do not damage the board)
      0_1504117979585_20170826_162900.jpg
      solder wires for powering arduino to usb ground and +5v

      Connection between nrf24L01+ and arduino pretty standard, i use piece of prototyping board to hold radio module and voltage converter together. This sub-assembly and arduino pro mini fits perfectly into base of lamp, just cut a little for wires pass freely.
      0_1504118652007_20170827_001716-1.jpg
      Relay module little modified to fit into lamp base - relay de-soldered, pins bend to 90 degree and relay soldered from other side of board, terminals for control signals replaced with pin connectors.
      0_1504118812401_20170827_001734.jpg
      Relay connected to arduino pin 3, switch to pin 4 .
      Because this project should have a wife compatibility mode 🙂 switch was used not as on/off switch, but as a trigger, lamp switch state on switch change, not on switch position.

      Comments and suggestion is welkomed, and sorry for my not-so-good English.

      Successfully used over a week in my home, using OpenHab2 and ethernet gateway.
      Code, if somebody interest, here
      0_1504119175102_IkeaLamp.ino

      posted in My Project
      doctor64
      doctor64
    • RE: openHAB 2.0 binding

      @rob I have similar problems caused by unstable radio link. Long debug and playing with position of gateway and sensors in apartment, radio channel, etc resolved it, but it can be very frustrating. I recommend from my experience try to reduce distance between gateway and sensor and use MYScontroller as debug tool. Once you have stable sensor network openhab plugin start working like a charm.

      As far as I understand, mysensor and openhab plugin works like this (timo, correct me if I wrong)
      1: sensor establish link to gateway.
      2: sensor request node ID from gateway.
      3: plugin generate node ID and send it via gateway to sensor
      4: if sensor with nodeID not defined aready in plugin config, sensor added to detected inbox

      Looks like your setup stopped somewhere on step 3, but as check I recommend use myscontroller as independent verification

      posted in OpenHAB
      doctor64
      doctor64
    • RE: openHAB 2.0 binding

      @rob
      As I see from log, gateway unable to send to sensor 5 response to find parent
      2017-07-05 12:56:14.193 [DEBUG] [rsAbstractConnection$MySensorsReader] - 0;255;3;0;9;205371 !TSF:MSG:SEND,0-0-5-5,s=255,c=3,t=8,pt=1,l=1,sg=0,ft=0,st=NACK:0

      I recommend to debug your radio link, may be using MYSController

      posted in OpenHAB
      doctor64
      doctor64
    • RE: openHAB 2.0 binding

      Hello @TimO !
      I delete all things and items (btw, seems like items not deleted completely, and re-apperas after item re-create), create things again and not see error anymore. Some black magic in action, looks like.
      I will create separate topic if this issue appears again. Thank you!

      posted in OpenHAB
      doctor64
      doctor64