Skip to content
  • OpenHardware.io
  • Categories
  • Recent
  • Tags
  • Popular
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo
  1. Home
  2. General Discussion
  3. Help needed - SSR switch / SCR dimmer
  • Getting Started
  • Controller
  • Build
  • Hardware
  • Download/API
  • Forum
  • Store

Help needed - SSR switch / SCR dimmer

Scheduled Pinned Locked Moved General Discussion
15 Posts 4 Posters 5.0k Views 6 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • K ksga

    @stedew
    Hi Stefan, and thanks.

    I agree that I might have to crawl before I run ;)
    In the link you provided there are two 30k ½W resistors in front of the bridge rectifier. Would they not produce a lot of heat as well?
    He uses a bridge rectifier. As far as I know the only function of that is to convert AC to DC, but it would still be 240V and be in a waveform.
    The zero-point detector I ordered (based on the Arduino playground schematic) can handle a bi-directional input, as opposed to the 4n25 that is used on Instructables, so couldn't I just leave the rectifier out?

    S Offline
    S Offline
    stedew
    wrote on last edited by
    #4

    @ksga
    idd the bridge is not needed because the H1AA1 has two antiparrallel diodes.
    As i said before the heat is a function I³*R. So yes, these resistors will get very hot (1W consumption @ 240V in total) It is ilmho not a good idea to use it like this given the fact that you get a few resistors in your circuit that always consume 1W even when the dimmer is off (and the resistors get very hot when you use a 1/2w type)
    Yust imagine you consume 8760W every year yust to know the zero crossing..

    K 1 Reply Last reply
    0
    • S stedew

      @ksga
      idd the bridge is not needed because the H1AA1 has two antiparrallel diodes.
      As i said before the heat is a function I³*R. So yes, these resistors will get very hot (1W consumption @ 240V in total) It is ilmho not a good idea to use it like this given the fact that you get a few resistors in your circuit that always consume 1W even when the dimmer is off (and the resistors get very hot when you use a 1/2w type)
      Yust imagine you consume 8760W every year yust to know the zero crossing..

      K Offline
      K Offline
      ksga
      wrote on last edited by
      #5

      @stedew
      But only if I have them before the ON/OFF relay ;)

      Okay... so when looking at the specs for the H11AA1 I can see that the maximum current on the input is 60mA.
      Looking at lthis I've reached the conclusion - that I believe you wanted me to - that I have to lower the ac current before the zero-cross detector using an AC/AC transformer.
      I'm having a bit of trouble finding a suitable (read - cheap) 240 / 6-0-6 AC/AC transformer. Any suggestions (prefer ebay or ali)??

      S 1 Reply Last reply
      0
      • K ksga

        @stedew
        But only if I have them before the ON/OFF relay ;)

        Okay... so when looking at the specs for the H11AA1 I can see that the maximum current on the input is 60mA.
        Looking at lthis I've reached the conclusion - that I believe you wanted me to - that I have to lower the ac current before the zero-cross detector using an AC/AC transformer.
        I'm having a bit of trouble finding a suitable (read - cheap) 240 / 6-0-6 AC/AC transformer. Any suggestions (prefer ebay or ali)??

        S Offline
        S Offline
        stedew
        wrote on last edited by
        #6

        @ksga
        well i suggest you use google for this (the trafo). Also your link provide schema and code not so bad as a start. also there is a module (the Bluetooth classs) that set the power output from a literal in %. This is exactly what you need to bind it to Mysensor lib...
        this is what i found on ebay Example link
        This trafo does not provide much power but it is small and maybe sufficiënt for powering the arduino.
        There is one catch when using a trafo : it introduce a phase shift so you must provide e methode (i believe a fix constant will do in most cases ) to trim the "offset" of the zero crossing.
        As i am not a specialist on mysensors internal structure but for a atmega328p (uno) TCCR1A is used inseverall places ,for analog write Altsoftserial (RS485) etc. So you must be sure not to re-use the timer it will behave strange. Same is for the attachInterrupt function it is used in hwSleep function. As there are only 2 HW irq's you must choose the "right" one in most designs i believe irq 1 is used for the NRF24l01 /RFM69 so choose the other one on your mcu . For all these reasons i believe it will take many hours off testing to get the dimmer "glitch" free.
        I believe for this resons it is better to offload the mcu and use a dedicated chip/mcu when you want to use Mysensors in your dimmer.

        1 Reply Last reply
        0
        • KoreshK Offline
          KoreshK Offline
          Koresh
          Contest Winner
          wrote on last edited by Koresh
          #7

          Hi. Only my 5 cents...
          Do not doubt. It is not possible to use the mysensors library (or another serious software) and to control a dimmer from one atmega328. Your controller will omit dimmer ISR during handling radio interrupts. I solved this problem using external attiny13 to control triac (it was a little challenge because attiny13 has only one timer and very little rom so I'd written program from scratch without arduino). It is not only one solution but it works and it is low cost. In this case we can use standard atmega328 as main controller (program it as standard arduino) and attiny13 as hardware controller. I have real prototype and may be I will route the board when will have time.

          K 2 Replies Last reply
          0
          • KoreshK Koresh

            Hi. Only my 5 cents...
            Do not doubt. It is not possible to use the mysensors library (or another serious software) and to control a dimmer from one atmega328. Your controller will omit dimmer ISR during handling radio interrupts. I solved this problem using external attiny13 to control triac (it was a little challenge because attiny13 has only one timer and very little rom so I'd written program from scratch without arduino). It is not only one solution but it works and it is low cost. In this case we can use standard atmega328 as main controller (program it as standard arduino) and attiny13 as hardware controller. I have real prototype and may be I will route the board when will have time.

            K Offline
            K Offline
            ksga
            wrote on last edited by ksga
            #8

            @Koresh
            Sounds like a good plan. Have you shared the code/design anywhere?

            @stedew
            Thanks fo the link :)
            Browsed Ali and ebay, but shipping is killing me on these trafos.
            Got me wondering... a lot of cheap AC-DC transformers are flooding these sites in 5-12V variants.
            Why not just take one of those apart - salvage the trafo and scrap the rest?

            I only need a few hundred mA to run arduino, radio and relay...

            This is the kind of stuff I'm talking about (claims to be able to deliver 2A 5VDC - but that would only be if you had to start a fire...):
            0_1481269256312_IMG_20161209_083757.jpg
            0_1481269266253_IMG_20161209_083806.jpg

            1 Reply Last reply
            0
            • KoreshK Koresh

              Hi. Only my 5 cents...
              Do not doubt. It is not possible to use the mysensors library (or another serious software) and to control a dimmer from one atmega328. Your controller will omit dimmer ISR during handling radio interrupts. I solved this problem using external attiny13 to control triac (it was a little challenge because attiny13 has only one timer and very little rom so I'd written program from scratch without arduino). It is not only one solution but it works and it is low cost. In this case we can use standard atmega328 as main controller (program it as standard arduino) and attiny13 as hardware controller. I have real prototype and may be I will route the board when will have time.

              K Offline
              K Offline
              ksga
              wrote on last edited by
              #9

              @Koresh
              Does your solution looks anything like this?

              KoreshK 1 Reply Last reply
              0
              • K ksga

                @Koresh
                Does your solution looks anything like this?

                KoreshK Offline
                KoreshK Offline
                Koresh
                Contest Winner
                wrote on last edited by
                #10

                @ksga said:

                @Koresh
                Does your solution looks anything like this?

                Yes, my solution loks like this, but I use cheaper controller and digital interface between atmega328 and attiny13.

                K 1 Reply Last reply
                0
                • FutureCowF Offline
                  FutureCowF Offline
                  FutureCow
                  wrote on last edited by
                  #11

                  Isn't this something to get the same results: https://forum.mysensors.org/topic/5408/ultra-small-esp8266-node-with-2-channel-relay-temperature-dimmer-project

                  K 1 Reply Last reply
                  0
                  • FutureCowF FutureCow

                    Isn't this something to get the same results: https://forum.mysensors.org/topic/5408/ultra-small-esp8266-node-with-2-channel-relay-temperature-dimmer-project

                    K Offline
                    K Offline
                    ksga
                    wrote on last edited by
                    #12

                    @FutureCow
                    Looks like it. But no code published...
                    Also - is the ESP8266 capable of handling the interrupts without messing up the timing when it is also responsible for communicating with the controller and the rest of the stuff??

                    1 Reply Last reply
                    0
                    • KoreshK Koresh

                      @ksga said:

                      @Koresh
                      Does your solution looks anything like this?

                      Yes, my solution loks like this, but I use cheaper controller and digital interface between atmega328 and attiny13.

                      K Offline
                      K Offline
                      ksga
                      wrote on last edited by
                      #13

                      @Koresh
                      Cool.. could you share the code?

                      KoreshK 1 Reply Last reply
                      0
                      • K ksga

                        @Koresh
                        Cool.. could you share the code?

                        KoreshK Offline
                        KoreshK Offline
                        Koresh
                        Contest Winner
                        wrote on last edited by Koresh
                        #14

                        @ksga said:

                        @Koresh
                        Cool.. could you share the code?

                        New year holidays is the busy time :) I really want to start production of many boards within the coming weeks (my fulltime job projects and mysensors boards too). So I can't promise to share this project very soon (I am not sure you are interest in a code written in hurry and untested prototype). But I will try to do it asap :smirk:

                        K 1 Reply Last reply
                        0
                        • KoreshK Koresh

                          @ksga said:

                          @Koresh
                          Cool.. could you share the code?

                          New year holidays is the busy time :) I really want to start production of many boards within the coming weeks (my fulltime job projects and mysensors boards too). So I can't promise to share this project very soon (I am not sure you are interest in a code written in hurry and untested prototype). But I will try to do it asap :smirk:

                          K Offline
                          K Offline
                          ksga
                          wrote on last edited by
                          #15

                          @Koresh
                          No worries - all help is appreciated - fast or slow :)

                          1 Reply Last reply
                          0
                          Reply
                          • Reply as topic
                          Log in to reply
                          • Oldest to Newest
                          • Newest to Oldest
                          • Most Votes


                          4

                          Online

                          11.7k

                          Users

                          11.2k

                          Topics

                          113.0k

                          Posts


                          Copyright 2019 TBD   |   Forum Guidelines   |   Privacy Policy   |   Terms of Service
                          • Login

                          • Don't have an account? Register

                          • Login or register to search.
                          • First post
                            Last post
                          0
                          • OpenHardware.io
                          • Categories
                          • Recent
                          • Tags
                          • Popular