Page 1 of 2 12 LastLast
Results 1 to 10 of 17

Thread: Control servos via Vixen 3 with Mini Maestro servo controller

  1. #1
    Join Date
    Apr 2017
    Posts
    30
    Post Thanks / Like

    Default Control servos via Vixen 3 with Mini Maestro servo controller

    Hello,
    This is my first attempt at posting to any forum, so please point me in the right direction if I appear to be lost. Over the past few years, I have used a Pololu Mini Maestro 18 Servo control board to run analog servos (mainly the Hitec HS-322HD model) without a problem. The Pololu Maestro Control Center that the board comes with has worked fine on my computer (Windows 7), and because I know very little about coding, provides an excellent GUI. Recently, I wanted to be able to control servos through Vixen 3 using the control board that I already have, but have been unable to figure out how to do so. After reading some older posts, I set the control center to USB Dual Port; created a generic serial controller in Vixen; matched the COM port for that controller to the the first port listed (port 5); Set the Baud Rate to 115,200, Parity to None, Data Bits to 8, and Stop Bits to One; patched a single item to output one; and clicked okay. Then, I opened a new sequence and tried adding a Custom Value effect from the Device Actions section, which yielded no movement from the servo that I had plugged into channel 1 on my board. No variations of adjusting the Value or Data Type seemed to make a difference, so I deleted the effect from the timeline. After changing the COM port and repeating my setup, I was still unable to make the servo budge. As a last resort, I added a Set Level effect from the Basic Lighting section, and the servo responded. I found that by changing the color of the light, I was able to make the servo move, but only between two general positions. In addition, it seems that only some colors have this affect on the servo. Dimming seems to have no affect at all, and I find these results to be very puzzling. If someone could give me some advice as to what to do next, it would be greatly appreciated. Also, if I need to provide further details, please let me know.

    One final note, I did also try the parallax servo controller option with similar settings as the one's listed above, but did not have any luck.

    Thank you very much for your help!

  2. #2
    Join Date
    Nov 2011
    Location
    Chicago - Southwest Suburbs
    Posts
    6,395
    Post Thanks / Like

    Default Re: Control servos via Vixen 3 with Mini Maestro servo controller

    The first thing to start with is the communications protocol. I don't know anything about your servo controller, but I doubt it speaks the generic serial protocol. Pretty much nothing except custom controllers use the generic serial controller. So the first step is to see what protocol that controller is using and then figure out which (if any) of vixens supported protocols will speak the language your hardware understands.


    Sent from my iPhone using Tapatalk

  3. #3
    Join Date
    Apr 2017
    Posts
    30
    Post Thanks / Like

    Default Re: Control servos via Vixen 3 with Mini Maestro servo controller

    Thank you so much for responding, jchuchla. It appears that the Pololu Maestro servo controller responds to serial commands. Specifically, it responds to three sub-protocols:

    -Compact Protocol, in which the command packet consists of, "command byte (with MSB set), any necessary data bytes"

    -Pololu Protocol, in which the command packet consists of, "command byte (with MSB set), any necessary data bytes"

    -Mini SSC Protocol, in which the command packet consists of, "0xFF, servo number byte, servo target byte"

    Please let me know if this is useful, or if you need more info. Thanks again!

  4. #4
    Join Date
    Nov 2011
    Location
    Chicago - Southwest Suburbs
    Posts
    6,395
    Post Thanks / Like

    Default Re: Control servos via Vixen 3 with Mini Maestro servo controller

    none of those sound like generic serial. The name "generic serial" has always bothered me a bit. There's nothing that generic about it. It's just as specific as any other protocol.

    If you compare the data communication to human communication, it may be easier to understand. There's two parts to the communication, there's the mechanism, and the protocol. The mechanism can be serial, or Ethernet, or any number of other methods. This is how the information gets from point A to point B. This is much like with human communication where we can use verbal words, or written words, or sign language. The protocol is much like a language. You can use the same voice to speak English, or Spanish, or Chinese. The opposite is also true, You can use the same language on different communication mechanisms. You can speak English words, or you can write them down and they get the point across the same both ways.

    Your controller looks like it defines 3 different protocols that it understands. None of those coincide with the protocols that vixen can speak.
    The one exception would be to use a command controller. A command controller is a different beast. It's designed as a multipurpose way to send specific serial strings from vixen. These strings can be routed to the serial port, as well as to the command prompt, or to an IP port. This output device was originally intended as a way to drive RDS radio data, so some of the controls may be a bit misleading. So you can set this controller up with the serial parameters of your servo controller. To send the actual commands to the command controller, you need to use the RDS effect. This is simply a string that gets sent out the port.
    One thing that may give you trouble is the non-printable characters that the protocol uses. Each ASCII letter corresponds with a hex code. But not all hex codes correspond with ASCII letters that can be typed into a text box. I'm not sure off hand if you can send non-printable characters using the RDS effect. You'll need to play with that.

  5. #5
    Join Date
    Nov 2016
    Posts
    96
    Post Thanks / Like

    Default Re: Control servos via Vixen 3 with Mini Maestro servo controller

    Not sure what exactly you're trying to do with Vixen and the Mini Maestro.. but IMHO your best chance of success is to add an Arduino into the mix.

    In simple terms...
    Vixen would send DMX commands to the Arduino.
    The Arduino converts the DMX commands into Maestro commands
    The Maestro moves the servos.

    It's not going to be plug & play... (you'll have to pull information/code from multiple places).

    The Arduino forum on this site should be able to help you with the DMX code.
    http://doityourselfchristmas.com/for...php?93-Arduino

    The Pololu site has information on how to use an Arduino to talk to the Maestro.
    https://www.pololu.com/docs/0J40/5.h.5
    https://github.com/pololu/maestro-arduino

    Another option is to not use the Maestro and instead use a prebuilt DMX-Servo controller.
    https://www.frightideas.com/servo-co.../servodmx.html
    http://northlightdmx.com/dmx512toRCservo.htm

    Just FYI... I'm currently working on a little project that controls a few servos over E1.31 using xLights and Vixen3. What you want to do can be done... but it's going to require a little more work on your side

    Here is one of my 'Singing Skulls' i just finished.

  6. #6
    Join Date
    Apr 2017
    Posts
    30
    Post Thanks / Like

    Default Re: Control servos via Vixen 3 with Mini Maestro servo controller

    Thank you very much for responding, TheLost. I really appreciate the links, and will read them over immediately. Out of curiosity, is DMX the only option for Vixen to interface with arduino, or can it be treated as a different type of controller? Although I don't have any hands on experience with DMX, I would be willing to move into the Arduino forum if it made what I'm trying to do easier. I already have an Arduino UNO board, so this might be a viable option. For the DMX to work between the computer and Arduino, would I have to buy any additional components, or is the UNO board itself sufficient? If at all possible, I would like to make the Maestro board work for this project. Great job on the singing skull; it gives me hope!
    Last edited by CS20; 04-12-2017 at 12:19 PM.

  7. #7
    Join Date
    Apr 2017
    Posts
    30
    Post Thanks / Like

    Default Re: Control servos via Vixen 3 with Mini Maestro servo controller

    Thank you very much for explaining this concept to me, jchuchla. Just to be sure I understand, if I want Vixen to communicate with the Maestro board, I will need to set up a command controller to translate the language into something more readable. Because the command controller is used for radio data, I will connect to the board via the serial port it is currently connected to. Then, I will rely on sending data through the RDS effect to the board. Is this correct? If so, can I enter the command packet string directly into the space for RDS text?

  8. #8
    Join Date
    Nov 2011
    Location
    Chicago - Southwest Suburbs
    Posts
    6,395
    Post Thanks / Like

    Default Re: Control servos via Vixen 3 with Mini Maestro servo controller

    Mostly right. The command controller isn't translating. But rather it's a way to send a specific piece of data at a specific time.
    The thing that might give you trouble with this method is if the protocol calls for something that can't be typed into the rds effect. For example hex characters like 0x02 0x0A 0x0D etc.
    Just to be clear this actually has nothing to do with radio data, you're just repurposing the tools that were originally invented for radio data.

    In the end though, this doesn't seem like this is a very practical implementation. You're not going to get very smooth ramping movements (unless the controller does it for you). I think you'd be better served with something that speaks dmx. That's a much more standard way of communicating that'll give you smoother response and easier control.


    Sent from my iPhone using Tapatalk

  9. #9
    Join Date
    Apr 2017
    Posts
    30
    Post Thanks / Like

    Default Re: Control servos via Vixen 3 with Mini Maestro servo controller

    Ah, this makes sense. It looks like DMX will be the way to go, then. I'm going to try to connect my Arduino UNO board to Vixen and treat it like a DMX device, just as TheLost suggested. If it works, I'll let you know. Thank you again for all your help!

  10. #10
    Join Date
    Apr 2017
    Posts
    30
    Post Thanks / Like

    Default Re: Control servos via Vixen 3 with Mini Maestro servo controller

    Hello, I don't know if my post will be read here, but I wanted to try updating this thread with some new information before starting a new one. With the wonderful help of Barnabybear, I was able to move my servo a small amount using Vixen, an Arduino UNO R3, and Mini Maestro. It worked by treating the Arduino as a Generic Serial Controller, which I think I was warned against doing. Barnabybear has suggested that I set up three channels for each servo (command start, servo number, and required servo position) in Vixen instead of using DMX. This way, I could get a full range out of the servos, and not have to worry about purchasing extra hardware. It sounds good to me, but I wanted a second opinion since I am relatively new to all of these concepts. Also, with all respect to Barnabybear, I am hesitant to part with DMX after hearing how it can simplify the process. Would it be possible to run the DMX code directly from the PC to the Arduino without any hardware besides the serial cable? Any advice would be much appreciated!

Page 1 of 2 12 LastLast

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •