Shop OBEX P1 Docs P2 Docs Learn Events
Implementing the DC-16 to 2p40 — Parallax Forums

Implementing the DC-16 to 2p40

danilodanilo Posts: 7
edited 2006-03-07 16:58 in BASIC Stamp
I need to control 4 stepper motors individually using a BS2p40-IC Module.

The number of I/O pins are very limited for my design and i have considered using the DC-16 Ouput Expansion Board (#31216) in order to expand the number of I/O pins.
However, The intructions on the DC-16: CONNECTIONS-SERIAL CONTROL

" ... the DC-16 is to be connected to a host like the ... Basic Stamp 2 series microcontroller in a Board-of-Education (BOE). To make the connection between the host controller and the DC-16 use a 3-wire servo extender cable."

I am not using a BOE and i want to know·if i can use the I/O pins (p0-p15 or x0-x15) on the BS2p40 to make this type of connection and implement the DC-16?

Comments

  • Vern GranerVern Graner Posts: 337
    edited 2006-03-07 01:21
    danilo said...
    " ... the DC-16 is to be connected to a host like the ... Basic Stamp 2 series microcontroller in a Board-of-Education (BOE). To make the connection between the host controller and the DC-16 use a 3-wire servo extender cable."

    I am not using a BOE and i want to know if i can use the I/O pins (p0-p15 or x0-x15) on the BS2p40 to make this type of connection and implement the DC-16?

    The DC-16 has a "servo" style header in that it uses three pins. One for Ground (labeled "G") one for Power (labeled "R") and one for signal (labeled "W"). You would make sure the BS2P40 and the DC-16 had the same source for power and ground, then connect one of the pins from the BS2P40 to the "W" pin on the DC-16. Pretty straight forward. smile.gif

    Vern

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Vern Graner CNE/CNA/SSE    | "If the network is down, then you're
    Senior Systems Engineer    | obviously incompetent so why are we
    Texas Information Services | paying you? Of course,if the network
    http://www.txis.com        | is up, then we obviously don't need
    Austin Office 512 328-8947 | you, so why are we paying you?" ©VLG
    
    
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2006-03-07 01:45
    Actually you only need a common ground and any I/O pin can be a serial pin.· With Stepper Motors you may not want your BS2p40 to have the same power source.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
    csavage@parallax.com
  • argmafiaargmafia Posts: 30
    edited 2006-03-07 02:34
    DDDDDJay Donny!
  • danilodanilo Posts: 7
    edited 2006-03-07 03:45
    Chris Savage (Parallax) said...
    Actually you only need a common ground and any I/O pin can be a serial pin.· With Stepper Motors you may not want your BS2p40 to have the same power source.

    Thanks everyone.



    I am aware about sharing the same power source and the [url=mailto:BS@p40]BS2p40[/url] has its own power and power regulation source.

    As for the stepper motors I will be using a ULN2803 Driver to connect between the DC-16 and the stepper motor.

    Does anyone see any "red flags" about this configuration?
  • Jon WilliamsJon Williams Posts: 6,491
    edited 2006-03-07 03:51
    Watch you're current use -- everyone loves to point to the 500 mA per channel on the ULN, but that's only with one channel running. You would have up to 4 channels per ULN active so that means you need to make sure your steppers don't use more than 300 mA per coil.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Jon Williams
    Applications Engineer, Parallax
  • danilodanilo Posts: 7
    edited 2006-03-07 04:08
    Jon Williams (Parallax) said...
    Watch you're current use -- everyone loves to point to the 500 mA per channel on the ULN, but that's only with one channel running. You would have up to 4 channels per ULN active so that means you need to make sure your steppers don't use more than 300 mA per coil.

    No more than one stepper motor will be functioning at a time but the current will be closely monitored.
  • Vern GranerVern Graner Posts: 337
    edited 2006-03-07 15:20
    Chris Savage (Parallax) said...
    Actually you only need a common ground and any I/O pin can be a serial pin. With Stepper Motors you may not want your BS2p40 to have the same power source.

    Good point! smile.gif I had assumed that the DC-16 power switch would be placed in the "1" position so it would obtain microcontroller power from the same source as the BS2P40, and the steppers (via the ULN2803) from an alternate power source to keep noise etc. from the digital control circuit.

    Vern

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Vern Graner CNE/CNA/SSE    | "If the network is down, then you're
    Senior Systems Engineer    | obviously incompetent so why are we
    Texas Information Services | paying you? Of course,if the network
    http://www.txis.com        | is up, then we obviously don't need
    Austin Office 512 328-8947 | you, so why are we paying you?" ©VLG
    
    
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2006-03-07 15:34
    Vern,

    ·· There is, of course, more than one way to do this.· I was just making sure there was a separate supply in the mix.· But what you said could work as well.· Depending on the load with the servos a common supply with the Stamp Module may not be a good idea.· Although, that really depends on the supply.· In this case it seems that only one unit will operate at a time so it may not be an issue.· OTOH, keeping the coils on the other Stepper Motor energized still draws current, and without that they don't hold position, so I don't know if that was taken into consideration.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
    csavage@parallax.com
  • Ryan ClarkeRyan Clarke Posts: 738
    edited 2006-03-07 16:58
    Attached:

    DC-16 as simple stepper driver


    Heed cautions by Jon W. with regards to power requirements.

    Note the bit shifting of the coil patterns to get to the second stepper attached (the rotate 4s).



    Ryan

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Ryan Clarke
    Parallax Tech Support

    RClarke@Parallax.com
Sign In or Register to comment.