• Isadora
  • Get it
  • Forum
  • Help
  • ADD-ONS
  • Newsletter
  • Impressum
  • Dsgvo
  • Impressum
Forum
    • Categories
    • Recent
    • Popular
    • Tags
    • Register
    • Login

    [SOLVED] Control multiple servos with Isadora -> Arduino (example attached)

    Hardware
    arduino servos
    5
    20
    2.9k
    Loading More Posts
    • 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.
    • FredF
      Fred @Juriaan
      last edited by

      @juriaan I would love to use OSC but I am looking at a pile of arduino UNO's so no joy.

      http://www.fredrodrigues.net/
      https://github.com/fred-dev
      OSX 10.15.15 MBP 2019 16" 2.3 GHz 8-Core i9, Radeon Pro 5500M 8 GB, 32g RAM
      Windows 10 7700K, GTX 1080ti, 32g RAM, 2tb raided SSD
      Windows 10 Threadripper 3960x 64g ram, 1tb NVME, rtx 2080ti + rtx2070 super

      1 Reply Last reply Reply Quote 0
      • bonemapB
        bonemap Izzy Guru @Fred
        last edited by

        @fred said:

        a problem with the serial send function in Isadora

         Hi @Fred,

        I have just fired up an Arduino Micro with a PMW 12v relay plus a 3v infrared remote, I had no problem communicating to both at the same time running a pulse generator at 30 hz through a sequential trigger to switch the relay and a pulse generator at 5 hz switching the remote. I did not see any issues with the Send Serial Data in the patch setup. 

        http://bonemap.com | Australia
        Izzy STD/USB 3.2.6 | + Beta 3.x.x
        MBP 16” 2019 2.4 GHz Intel i9 64GB AMD Radeon Pro 5500 8 GB 4TB SSD | 14.1.2 Sonoma
        Mac Studio 2023 M2 Ultra 128GB | OSX 14.1.2 Sonoma
        A range of deployable older Macs

        FredF 1 Reply Last reply Reply Quote 0
        • FredF
          Fred @bonemap
          last edited by

          @bonemap can you send me your patch and Arduino code to test here? I did not have trouble when using single parameters with the send serial but only with multiple parameters on a send serial.

          http://www.fredrodrigues.net/
          https://github.com/fred-dev
          OSX 10.15.15 MBP 2019 16" 2.3 GHz 8-Core i9, Radeon Pro 5500M 8 GB, 32g RAM
          Windows 10 7700K, GTX 1080ti, 32g RAM, 2tb raided SSD
          Windows 10 Threadripper 3960x 64g ram, 1tb NVME, rtx 2080ti + rtx2070 super

          bonemapB 1 Reply Last reply Reply Quote 0
          • bonemapB
            bonemap Izzy Guru @Fred
            last edited by bonemap

            @fred said:

            send me your patch and Arduino code

            Here it is, but be aware that the code and the patch are not well annotated.

            Arduino-Isadora-Relay-Fan-test.zip (apologies I uploaded the wrong files - these are a match)

            http://bonemap.com | Australia
            Izzy STD/USB 3.2.6 | + Beta 3.x.x
            MBP 16” 2019 2.4 GHz Intel i9 64GB AMD Radeon Pro 5500 8 GB 4TB SSD | 14.1.2 Sonoma
            Mac Studio 2023 M2 Ultra 128GB | OSX 14.1.2 Sonoma
            A range of deployable older Macs

            FredF 1 Reply Last reply Reply Quote 0
            • FredF
              Fred @bonemap
              last edited by Fred

              @bonemap Cheers, I just took a look, and I also had no trouble sending single characters as you are doing in this example, the issue I am getting is sending more than that, I need to control 4 servos so I have to send 4 different kinds of messages, that should be readable as strings and then split them out at the other end. I make a string like this (using either send serial or send raw serial) A<intvalA>B<intvalB>C<intvalC>D<intvalD>| where <intvalN> are integers (without using the :C delimiter in the send serial so they are sent as ascii), or just using the text formater and creating a string and sending with send Raw Serial.


              Either way the messages are received properly but with a lot of delay and not reliably. As I said, the simple versions, just sending a char to switch a Boolean seems to work fine, but more than that gives issues.


              Sending the same strings from an application I wrote myself works fine and is very responsive, so either I am misunderstanding how the formatting in the send serial actor works, or there is an issue. It would still be great if someone can test something closer to what I am doing.

              http://www.fredrodrigues.net/
              https://github.com/fred-dev
              OSX 10.15.15 MBP 2019 16" 2.3 GHz 8-Core i9, Radeon Pro 5500M 8 GB, 32g RAM
              Windows 10 7700K, GTX 1080ti, 32g RAM, 2tb raided SSD
              Windows 10 Threadripper 3960x 64g ram, 1tb NVME, rtx 2080ti + rtx2070 super

              bonemapB 1 Reply Last reply Reply Quote 0
              • bonemapB
                bonemap Izzy Guru @Fred
                last edited by bonemap

                @fred said:

                great if someone can test something closer to what I am doing

                 Yep! well my other projects use NodeMCU and OSC, have not used longer strings through the Send Serial Data modules that I can recall. I hope you can work it out.

                best wishes

                Russell 

                http://bonemap.com | Australia
                Izzy STD/USB 3.2.6 | + Beta 3.x.x
                MBP 16” 2019 2.4 GHz Intel i9 64GB AMD Radeon Pro 5500 8 GB 4TB SSD | 14.1.2 Sonoma
                Mac Studio 2023 M2 Ultra 128GB | OSX 14.1.2 Sonoma
                A range of deployable older Macs

                FredF 1 Reply Last reply Reply Quote 0
                • FredF
                  Fred @bonemap
                  last edited by

                  @bonemap yes I much prefer to use other protocols but this should work, and it is for teaching....it is easier to keep everything in one place for beginner students.

                  At any rate, here is the Isadora patch and the arduino file in case anyone has the time to take a look.Isadora-Arduino serial version _not working.zip

                  http://www.fredrodrigues.net/
                  https://github.com/fred-dev
                  OSX 10.15.15 MBP 2019 16" 2.3 GHz 8-Core i9, Radeon Pro 5500M 8 GB, 32g RAM
                  Windows 10 7700K, GTX 1080ti, 32g RAM, 2tb raided SSD
                  Windows 10 Threadripper 3960x 64g ram, 1tb NVME, rtx 2080ti + rtx2070 super

                  1 Reply Last reply Reply Quote 1
                  • JuriaanJ
                    Juriaan Tech Staff
                    last edited by

                    Will hook up an Arduino and give it a shot when I get back from work.

                    Isadora 3.1.1, Dell XPS 17 9710, Windows 10
                    Interactive Performance Designer, Freelance Artist, Scenographer, Lighting Designer, TroikaTronix Community moderator
                    Always in for chatting about interaction in space / performance design. Drop me an email at hello@juriaan.me

                    FredF 1 Reply Last reply Reply Quote 0
                    • FredF
                      Fred @Juriaan
                      last edited by

                      @juriaan @bonemap

                      I found out what the issue is. Arduino read as string is very slow and takes 2.5 seconds to resolve. I have a version now that reads byte by byte and it works great. I have attached the Arduino and Isadora files here.Isadora-Arduino serial version _WORKING!.zip

                      http://www.fredrodrigues.net/
                      https://github.com/fred-dev
                      OSX 10.15.15 MBP 2019 16" 2.3 GHz 8-Core i9, Radeon Pro 5500M 8 GB, 32g RAM
                      Windows 10 7700K, GTX 1080ti, 32g RAM, 2tb raided SSD
                      Windows 10 Threadripper 3960x 64g ram, 1tb NVME, rtx 2080ti + rtx2070 super

                      DusXD 1 Reply Last reply Reply Quote 1
                      • DusXD
                        DusX Tech Staff @Fred
                        last edited by

                        @fred

                        Good to hear.. I was actually going thru your code to debug this last night and felt it was on the processing side but couldn't be sure yet.

                        Troikatronix Technical Support

                        • New Support Ticket Link: https://support.troikatronix.com/support/tickets/new
                        • Isadora Add-ons: https://troikatronix.com/add-ons/
                        • My Add-ons: https://troikatronix.com/add-ons/?u=dusx

                        Running: Win 11 64bit, i7, M.2 PCIe SSD's, 32gb DDR4, nVidia GTX 4070 | located in Ontario Canada.

                        1 Reply Last reply Reply Quote 1
                        • First post
                          Last post