View Single Post
  #2   Spotlight this post!  
Unread 18-05-2010, 02:23
RyanCahoon's Avatar
RyanCahoon RyanCahoon is offline
Disassembling my prior presumptions
FRC #0766 (M-A Bears)
Team Role: Engineer
 
Join Date: Dec 2007
Rookie Year: 2007
Location: Mountain View
Posts: 689
RyanCahoon has a reputation beyond reputeRyanCahoon has a reputation beyond reputeRyanCahoon has a reputation beyond reputeRyanCahoon has a reputation beyond reputeRyanCahoon has a reputation beyond reputeRyanCahoon has a reputation beyond reputeRyanCahoon has a reputation beyond reputeRyanCahoon has a reputation beyond reputeRyanCahoon has a reputation beyond reputeRyanCahoon has a reputation beyond reputeRyanCahoon has a reputation beyond repute
Re: Programming EasyC

I don't know easyC, but I assume you know how to control digital outputs.

Referencing the Users Guide on the Spike product info page, the input cable to the Spike is wired so that the White (or Yellow or Orange) wire is the Forward signal, the Red wire is the Reverse signal, and the Black wire is ground. So you'll need to use two digital outputs and create a cable like such:
Code:
                 ,--W   \
                 |  R   |  digital output 1
                 |  B   /
         /  W----'       
to Spike |  R----.       
         \  B--. '--W   \
               |    R   |  digital output 2
               '----B   /

W,R,B = White, Red, Black
It might end up looking like a PWM Y-cable, but it is different. Then set the digital inputs as specified in the Users Guide to direct the spike into either Off, Forward, Reverse, or Brake modes.

Hope that answers your question

--Ryan
__________________
FRC 2046, 2007-2008, Student member
FRC 1708, 2009-2012, College mentor; 2013-2014, Mentor
FRC 766, 2015-, Mentor