Shop OBEX P1 Docs P2 Docs Learn Events
communication with the 12V motor controllers. — Parallax Forums

communication with the 12V motor controllers.

DgswanerDgswaner Posts: 795
edited 2009-04-11 15:07 in Propeller 1
I think I'm finally ready. to tackle odometry with the 12V motor controller kits. My plan was to have one cog preforming the movement commands, forward, backward etc. while another cog received travel distances, and did the math to calculate x and Y coordinates.

my Question:
can 2 cogs communicate with the controller/encoders at the same time? or do I need to do all of this in one cog?

I don't want to go down a dead end with no encoders! (joke)

thanks

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
DGSwaner

"When in doubt, use C4" - Jamie Hyneman, Myth Buster

Comments

  • MicrocontrolledMicrocontrolled Posts: 2,461
    edited 2009-04-11 11:49
    Two cogs can communicate at the same time. They can even share the information they gathered with another cog. You could write in assembly to save hub RAM or in spin for ease of use with variables and outputs. If you mean can two cogs work with the same I/O pins, than you will have to try this to see if it will work. I cannot see why this could not work this way but It could mess up if you are trying to send the information along the same wire you are receiving it with!

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Toys are microcontroled.
    Robots are microcontroled.
    I am microcontrolled.
  • WNedWNed Posts: 157
    edited 2009-04-11 15:07
    You are basically starting the same discussion started a couple of days ago here:
    http://forums.parallax.com/forums/default.aspx?f=25&m=342479
    This user is talking about a different peripheral, but the communication requirement is the same, two cogs, one device.

    Ned

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    "They may have computers, and other weapons of mass destruction." - Janet Reno
Sign In or Register to comment.