Go to Post Don't underestimate the ability of a highly skilled technician with simple tools (and don't overestimate the ability of an unskilled fool with exotic tools!). - dlavery [more]
Home
Go Back   Chief Delphi > Technical > Electrical > CAN
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Reply
Thread Tools Rating: Thread Rating: 7 votes, 5.00 average. Display Modes
  #1   Spotlight this post!  
Unread 27-10-2010, 22:30
ratdude747's Avatar
ratdude747 ratdude747 is offline
Official Scorekeeper
AKA: Larry Bolan
no team
 
Join Date: Feb 2009
Rookie Year: 2008
Location: Madison, IN
Posts: 1,064
ratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond repute
CAN vs PWM

Myself and another member on my team were discussing whether to shoot for CAN or PWM for the jaguars next year.

we do not plan on using any victors, as we were rookies in 2009 and all we have are a few stray ones on a donated prototype chassis. We also plan to program using labview.

as i understand from the table at nationals, next year's KOP has solely black jaguars in it.

a little gracious advice would be helpful as my last 3 years of FRC wiring have been pwm only.
__________________
Dean's List Semi-finalist 2010
1747 Harrison Boiler Robotics 2008-2010, 2783 Engineers of Tomorrow 2011, Event Volunteer 2012-current

DISCLAIMER: Any opinions/comments posted are solely my personal opinion and does not reflect the views/opinions of FIRST, IndianaFIRST, or any other organization.

Last edited by ratdude747 : 27-10-2010 at 23:27.
Reply With Quote
  #2   Spotlight this post!  
Unread 28-10-2010, 00:28
Radical Pi Radical Pi is offline
Putting the Jumper in the Bumper
AKA: Ian Thompson
FRC #0639 (Code Red Robotics)
Team Role: Programmer
 
Join Date: Jan 2010
Rookie Year: 2010
Location: New York
Posts: 655
Radical Pi has a spectacular aura aboutRadical Pi has a spectacular aura aboutRadical Pi has a spectacular aura about
Re: CAN vs PWM

We used CAN last year, and though it's a little temperamental, when it works it works well.

Be warned, our problems included difficulty in making the cables, a higher sensitivity to slowdowns in your robot code (We cannot safely enable the bot until the camera feed starts at the driver station), jags randomly resetting their IDs (this has been fixed), and under last year's code the system cannot handle more than 2 jaguars being unpowered (if all goes well that won't be a problem again this year).

On the plus side, the wiring is infinitely simpler with CAN (assuming you can make the cables), as there is only one wire going to the cRIO. I also would have been gutted by the drive team if I pulled the robot apart trying to get at the two jags which power our kicker so I could switch the coast/brake jumper on the day before shipping (true story). Instead, I was able to override it through code. And if there are any problems, you can quickly plug the bus into a computer and check if any jags are not operating properly.

Overall the decision of if to switch should be based on whether you have a use for the extra abilities of the CAN bus and whether you can devote the resources to the problems that will most likely arise from the bus.

disclaimer: I'm a C++ programmer so I may have a different experience with the CAN bus than the LV teams
__________________

"To have no errors would be life without meaning. No strugle, no joy"
"A network is only as strong as it's weakest linksys"
Reply With Quote
  #3   Spotlight this post!  
Unread 29-10-2010, 15:13
kamocat's Avatar
kamocat kamocat is offline
Test Engineer
AKA: Marshal Horn
FRC #3213 (Thunder Tech)
Team Role: Mentor
 
Join Date: May 2008
Rookie Year: 2008
Location: Tacoma
Posts: 894
kamocat is just really nicekamocat is just really nicekamocat is just really nicekamocat is just really nicekamocat is just really nice
Send a message via AIM to kamocat Send a message via MSN to kamocat
Re: CAN vs PWM

Try it out before the season. We're happy to support you on any issues you run into, but this is NOT something you want to have to figure out when you should be testing your robot design.
I have data on the performance of CAN using the Black Jaguar plugin at this thread:
http://www.chiefdelphi.com/forums/sh...ad.php?t=86259

2CAN should provide better performance, but I have not tested it.
__________________
-- Marshal Horn
Reply With Quote
  #4   Spotlight this post!  
Unread 30-10-2010, 01:01
ratdude747's Avatar
ratdude747 ratdude747 is offline
Official Scorekeeper
AKA: Larry Bolan
no team
 
Join Date: Feb 2009
Rookie Year: 2008
Location: Madison, IN
Posts: 1,064
ratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond repute
Re: CAN vs PWM

i have another question:

if what i remember from the demo at nationals is right, do you use rg45 patch for the lead in and rg11 2 line phone cord (4 wires) for the rest? or do you use all six rg11 pins?

i know the extra pins of the black are what make it a black (and hence why using all blacks next year works)
__________________
Dean's List Semi-finalist 2010
1747 Harrison Boiler Robotics 2008-2010, 2783 Engineers of Tomorrow 2011, Event Volunteer 2012-current

DISCLAIMER: Any opinions/comments posted are solely my personal opinion and does not reflect the views/opinions of FIRST, IndianaFIRST, or any other organization.
Reply With Quote
  #5   Spotlight this post!  
Unread 30-10-2010, 18:26
Radical Pi Radical Pi is offline
Putting the Jumper in the Bumper
AKA: Ian Thompson
FRC #0639 (Code Red Robotics)
Team Role: Programmer
 
Join Date: Jan 2010
Rookie Year: 2010
Location: New York
Posts: 655
Radical Pi has a spectacular aura aboutRadical Pi has a spectacular aura aboutRadical Pi has a spectacular aura about
Re: CAN vs PWM

If using a serial interface: RJ-45 is used to communicate between the cRIO and the black jaguar. For the rest of the system only 2 wires are needed

If using a 2CAN: Everything is 2-wire
__________________

"To have no errors would be life without meaning. No strugle, no joy"
"A network is only as strong as it's weakest linksys"
Reply With Quote
  #6   Spotlight this post!  
Unread 30-10-2010, 22:43
ratdude747's Avatar
ratdude747 ratdude747 is offline
Official Scorekeeper
AKA: Larry Bolan
no team
 
Join Date: Feb 2009
Rookie Year: 2008
Location: Madison, IN
Posts: 1,064
ratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond repute
Re: CAN vs PWM

Quote:
Originally Posted by Radical Pi View Post
If using a serial interface: RJ-45 is used to communicate between the cRIO and the black jaguar. For the rest of the system only 2 wires are needed

If using a 2CAN: Everything is 2-wire
ok then. by lead in i meant from cRIO to the first black jag. the rest sounds like stanard phone wire which 2 or 4 wires, fits in an RJ-45 socket just fine... they do that in office buildings a lot.

sounds like making the wires requires modular phone cord, RJ-11 (phone) jacks, the proper crimp tool, and a CAT 5e patch cable. i think i saw the crimp tools for phone wire at Lowe's cheap...
__________________
Dean's List Semi-finalist 2010
1747 Harrison Boiler Robotics 2008-2010, 2783 Engineers of Tomorrow 2011, Event Volunteer 2012-current

DISCLAIMER: Any opinions/comments posted are solely my personal opinion and does not reflect the views/opinions of FIRST, IndianaFIRST, or any other organization.
Reply With Quote
  #7   Spotlight this post!  
Unread 31-10-2010, 13:45
kamocat's Avatar
kamocat kamocat is offline
Test Engineer
AKA: Marshal Horn
FRC #3213 (Thunder Tech)
Team Role: Mentor
 
Join Date: May 2008
Rookie Year: 2008
Location: Tacoma
Posts: 894
kamocat is just really nicekamocat is just really nicekamocat is just really nicekamocat is just really nicekamocat is just really nice
Send a message via AIM to kamocat Send a message via MSN to kamocat
Re: CAN vs PWM

You are correct.
__________________
-- Marshal Horn
Reply With Quote
  #8   Spotlight this post!  
Unread 31-10-2010, 23:03
ratdude747's Avatar
ratdude747 ratdude747 is offline
Official Scorekeeper
AKA: Larry Bolan
no team
 
Join Date: Feb 2009
Rookie Year: 2008
Location: Madison, IN
Posts: 1,064
ratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond repute
Re: CAN vs PWM

cool.

so i guess the wiring side is established. now for the programming side, which is not quite my thing... i know labview basics, i imagine the place to find the jags is not pwm with CAN...
__________________
Dean's List Semi-finalist 2010
1747 Harrison Boiler Robotics 2008-2010, 2783 Engineers of Tomorrow 2011, Event Volunteer 2012-current

DISCLAIMER: Any opinions/comments posted are solely my personal opinion and does not reflect the views/opinions of FIRST, IndianaFIRST, or any other organization.
Reply With Quote
  #9   Spotlight this post!  
Unread 01-11-2010, 20:44
kamocat's Avatar
kamocat kamocat is offline
Test Engineer
AKA: Marshal Horn
FRC #3213 (Thunder Tech)
Team Role: Mentor
 
Join Date: May 2008
Rookie Year: 2008
Location: Tacoma
Posts: 894
kamocat is just really nicekamocat is just really nicekamocat is just really nicekamocat is just really nicekamocat is just really nice
Send a message via AIM to kamocat Send a message via MSN to kamocat
Re: CAN vs PWM

You're looking for the CANJaguar project at FIRST Forge.
http://firstforge.wpi.edu/sf/frs/do/....canjaguar/frs
__________________
-- Marshal Horn
Reply With Quote
  #10   Spotlight this post!  
Unread 18-12-2010, 21:34
ratdude747's Avatar
ratdude747 ratdude747 is offline
Official Scorekeeper
AKA: Larry Bolan
no team
 
Join Date: Feb 2009
Rookie Year: 2008
Location: Madison, IN
Posts: 1,064
ratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond repute
Re: CAN vs PWM

my team might try it... since we will end up buying a black jag anyway, all it is to us is a db9 plug and a some rj11 parts (we already have the crimper).

i fiund a good pdf by 116 on the subject, but the programming instructions are for C++. we are using labview.

two questions:

1. what all does the programmer need to know to convert the code written for pwm to CAN?

2. is the cRIO FTP thing the same?

the electrical and firmware thing i have down... I was made electrical subteam leader today and i read the pdf and my laptop is set to be a reflash device (you use the homemade serial dongle to do that, right?).

any other advice?
__________________
Dean's List Semi-finalist 2010
1747 Harrison Boiler Robotics 2008-2010, 2783 Engineers of Tomorrow 2011, Event Volunteer 2012-current

DISCLAIMER: Any opinions/comments posted are solely my personal opinion and does not reflect the views/opinions of FIRST, IndianaFIRST, or any other organization.
Reply With Quote
  #11   Spotlight this post!  
Unread 18-12-2010, 23:27
Radical Pi Radical Pi is offline
Putting the Jumper in the Bumper
AKA: Ian Thompson
FRC #0639 (Code Red Robotics)
Team Role: Programmer
 
Join Date: Jan 2010
Rookie Year: 2010
Location: New York
Posts: 655
Radical Pi has a spectacular aura aboutRadical Pi has a spectacular aura aboutRadical Pi has a spectacular aura about
Re: CAN vs PWM

Quote:
Originally Posted by ratdude747 View Post
1. what all does the programmer need to know to convert the code written for pwm to CAN?
I'm a C++ programmer, so this may not be 100% accurate, but from my understanding of the LabVIEW API you just need to replace the references to the regular Jaguar VIs with CANJaguar VIs

Quote:
Originally Posted by ratdude747 View Post
2. is the cRIO FTP thing the same?
Nothing changes in the stuff to upload from C++ to LabVIEW

Side note: Your PDF may not have said this, but you need to make sure to undo the change to ni-rt.ini before attempting to re-image the cRIO. For some reason it fails if the CAN plugin is loaded.

Quote:
Originally Posted by ratdude747 View Post
the electrical and firmware thing i have down... I was made electrical subteam leader today and i read the pdf and my laptop is set to be a reflash device (you use the homemade serial dongle to do that, right?).

any other advice?
Yep, the serial dongle is all you need to reflash the jaguars.

Make sure you have plenty of extra cables. One broken cable will most likely take the entire network down. We have 2 or 3 spare jag-jag (2 wire) cables, and an extra jag-cRIO (6-wire) cable. We also found it useful to make a second serial dongle and keep the spare jag-cRIO cable with it so we don't have to dig the connection out of the robot if anything goes wrong (like last year's device number reset bug). A spare termination resistor is also a good idea.

Also, be extra careful about disconnecting power to jaguars. Even though the bus can still travel through an unpowered jaguar, C++ had a (hopefully fixed) bug that would cause glitches if it didn't receive responses from a jaguar. Not sure if LV had that same bug.
__________________

"To have no errors would be life without meaning. No strugle, no joy"
"A network is only as strong as it's weakest linksys"
Reply With Quote
  #12   Spotlight this post!  
Unread 18-12-2010, 23:35
ratdude747's Avatar
ratdude747 ratdude747 is offline
Official Scorekeeper
AKA: Larry Bolan
no team
 
Join Date: Feb 2009
Rookie Year: 2008
Location: Madison, IN
Posts: 1,064
ratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond repute
Re: CAN vs PWM

i'm confused. the six wire cord is only for the first bit?

ok... i assume 8 wire patch cord with rj12 pluds (2 wires not used) would work?

one other dumb thing- is only one 100 ohm resistor needed or is one needed at each end?
__________________
Dean's List Semi-finalist 2010
1747 Harrison Boiler Robotics 2008-2010, 2783 Engineers of Tomorrow 2011, Event Volunteer 2012-current

DISCLAIMER: Any opinions/comments posted are solely my personal opinion and does not reflect the views/opinions of FIRST, IndianaFIRST, or any other organization.
Reply With Quote
  #13   Spotlight this post!  
Unread 18-12-2010, 23:44
Ether's Avatar
Ether Ether is offline
systems engineer (retired)
no team
 
Join Date: Nov 2009
Rookie Year: 1969
Location: US
Posts: 8,125
Ether has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond repute
Re: CAN vs PWM

Quote:
Originally Posted by ratdude747 View Post
one other dumb thing- is only one 100 ohm resistor needed or is one needed at each end?
Search is your friend:

http://www.chiefdelphi.com/forums/sh...88&postcount=4



Reply With Quote
  #14   Spotlight this post!  
Unread 18-12-2010, 23:54
ratdude747's Avatar
ratdude747 ratdude747 is offline
Official Scorekeeper
AKA: Larry Bolan
no team
 
Join Date: Feb 2009
Rookie Year: 2008
Location: Madison, IN
Posts: 1,064
ratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond repute
Re: CAN vs PWM

gotcha.

ok... luckily I have a bunch of 100 ohm resistors thanks to some junk power supplies i desoldered as soldering practice... already have the end terminator made.
__________________
Dean's List Semi-finalist 2010
1747 Harrison Boiler Robotics 2008-2010, 2783 Engineers of Tomorrow 2011, Event Volunteer 2012-current

DISCLAIMER: Any opinions/comments posted are solely my personal opinion and does not reflect the views/opinions of FIRST, IndianaFIRST, or any other organization.
Reply With Quote
  #15   Spotlight this post!  
Unread 19-12-2010, 01:10
kamocat's Avatar
kamocat kamocat is offline
Test Engineer
AKA: Marshal Horn
FRC #3213 (Thunder Tech)
Team Role: Mentor
 
Join Date: May 2008
Rookie Year: 2008
Location: Tacoma
Posts: 894
kamocat is just really nicekamocat is just really nicekamocat is just really nicekamocat is just really nicekamocat is just really nice
Send a message via AIM to kamocat Send a message via MSN to kamocat
Re: CAN vs PWM

Quote:
Originally Posted by ratdude747 View Post
what all does the programmer need to know to convert the code written for pwm to CAN?
If you're just converting PWM control to open-loop voltage mode in CAN (also called percent Vbus), it's pretty easy.
There should be an example drive project in the CAN release.

If you're using speed or position mode, you should understand PID and how to use encoders.
If you're using Current mode, you should know that the sensor is only accurate within 1 amp, and is not suitable for small motors.
__________________
-- Marshal Horn
Reply With Quote
Reply


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
R63 and mixed CAN-PWM designs Shinigami2057 Electrical 2 18-01-2010 10:51
PWM cables... Where can i buy them??? M. Gildner Electrical 10 11-02-2009 12:31
Can one PWM control 2 Victors for Tandem Motors ericsundbergva Control System 1 18-02-2008 04:55
Can we shorten the PWM cables? RAWdealer59 Electrical 3 18-02-2003 15:49


All times are GMT -5. The time now is 10:48.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi