Go to Post Dean Kamen is a pretty smart dude. If he wants to talk to me, I want to listen. - Taylor [more]
Home
Go Back   Chief Delphi > Technical > Electrical
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Closed Thread
Thread Tools Rate Thread Display Modes
  #16   Spotlight this post!  
Unread 04-05-2013, 12:01
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: Arbitrary Quadrature Encoder

Quote:
Originally Posted by Joe Ross View Post
Facepalm.


  #17   Spotlight this post!  
Unread 04-05-2013, 16:58
PayneTrain's Avatar
PayneTrain PayneTrain is offline
no
AKA: Lizard King
FRC #0422 (The Meme Tech Pneumatic Devices)
Team Role: Mascot
 
Join Date: Mar 2010
Rookie Year: 2009
Location: RVA
Posts: 2,274
PayneTrain has a reputation beyond reputePayneTrain has a reputation beyond reputePayneTrain has a reputation beyond reputePayneTrain has a reputation beyond reputePayneTrain has a reputation beyond reputePayneTrain has a reputation beyond reputePayneTrain has a reputation beyond reputePayneTrain has a reputation beyond reputePayneTrain has a reputation beyond reputePayneTrain has a reputation beyond reputePayneTrain has a reputation beyond repute
Re: Arbitrary Quadrature Encoder

Quote:
Originally Posted by Ether View Post
Facepalm.


Well folks, I think the internet is over now.
  #18   Spotlight this post!  
Unread 04-05-2013, 17:13
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: Arbitrary Quadrature Encoder

Quote:
Originally Posted by PayneTrain View Post
Well folks, I think the internet is over now.
Age is catching up with me :-(


  #19   Spotlight this post!  
Unread 08-05-2013, 01:42
Bneufeld235's Avatar
Bneufeld235 Bneufeld235 is offline
Registered User
FRC #0585 (Cyber Penguins)
Team Role: Programmer
 
Join Date: Apr 2013
Rookie Year: 2011
Location: Tehachapi, Ca
Posts: 9
Bneufeld235 is an unknown quantity at this point
Re: Arbitrary Quadrature Encoder

We have now ordered the first round of circuit boards. Everything should arrive around May 14. These are for test and verification of the design, before we commit to making a bunch. I and several other students will be soldering the boards.

With the circuits we have ordered resistors with different values so we can do some testing and fine tune our encoder.The resistors that will most likely need fiddled with are involved with the voltage divider feeding into the first op-amp. We just don't know how sensitive the SMT phototransistors will be, compared to the through-hole version on the wire-wrapped prototype.
__________________
2013 - Electrical, Programming, and Mechanical; Las Vegas Dean's List Finalist
2012 - Electrical and Programming; Las Vegas Regional Chairman's Award
  #20   Spotlight this post!  
Unread 08-05-2013, 19:33
Levansic's Avatar
Levansic Levansic is offline
Registered User
AKA: Len Evansic
FRC #0585 (Cyber Penguins)
Team Role: Mentor
 
Join Date: Jan 2012
Rookie Year: 2008
Location: Tehachapi, CA
Posts: 185
Levansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud of
Re: Arbitrary Quadrature Encoder

For illustrative purposes, this is the current schematic of the encoder. The voltage dividers Brooke is referring to are R1/R3 and R5/R7, on the left side of the schematic. These dividers set the threshold for a high or low value.

Maybe now would be a good time to expand our in-team discussion to the wider CD community.

Initially, we had intended to offer this encoder as a completely assembled component, and as a kit. Our thinking was that the kit could be used for skill building, while a commercially assembled board should be more reliable for competition use.

Going to the Kickstarter forced us to be more pragmatic. I used to memorize Heathkit catalogs in my youth, but couldn't see the volumes for kits being worth the headache of confused parts or damaged components. The truth is, we just don't know if it is better to keep on the road that we are on, or re-think the option of offering kits. Any thoughts?
  #21   Spotlight this post!  
Unread 10-05-2013, 22:54
Levansic's Avatar
Levansic Levansic is offline
Registered User
AKA: Len Evansic
FRC #0585 (Cyber Penguins)
Team Role: Mentor
 
Join Date: Jan 2012
Rookie Year: 2008
Location: Tehachapi, CA
Posts: 185
Levansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud of
Re: Arbitrary Quadrature Encoder


I didn't expect crickets.

Well, we have some new news. Our SMT components arrived today, and my tracking info on the boards says that they should arrive tomorrow. This is ahead of our original schedule. We will post pictures when the boards arrive.

Unfortunately, this doesn't advance our schedule any sooner than assembling on Monday, With college placement tests, Special Olympics, and Mother's Day all happening this weekend, we have no confluence of students and time.

Looking at the size of the components we used to fit everything on the board, while not an absolute position, I've moved decidedly against offering kits. I can now see why Heathkit had trouble being reborn recently. It looks like successful assembly will take the skills of a dentist or a damond cutter.

That being said, if there is interest, we may add a lower award tier for a kit of parts, with one extra component of every type. I'm sure there are a few masochists like me around that would love the challenge.
  #22   Spotlight this post!  
Unread 10-05-2013, 23:00
calvin909090 calvin909090 is offline
Registered User
FRC #0192
 
Join Date: Sep 2012
Location: Palo Alto
Posts: 2
calvin909090 is an unknown quantity at this point
Re: Arbitrary Quadrature Encoder

Why are you guys using op-amps instead of comparators? Comparators output a direct digital signal. Response times will be better, since you don't need to worry about slew rate (not as if that was a concern in the first place)—something like the LM339 instead of the LM324.
  #23   Spotlight this post!  
Unread 10-05-2013, 23:49
nuttle nuttle is offline
Registered User
AKA: Allen Nuttle
FRC #4080
Team Role: Mentor
 
Join Date: Mar 2010
Rookie Year: 2009
Location: United States
Posts: 104
nuttle has much to be proud ofnuttle has much to be proud ofnuttle has much to be proud ofnuttle has much to be proud ofnuttle has much to be proud ofnuttle has much to be proud ofnuttle has much to be proud ofnuttle has much to be proud of
Re: Arbitrary Quadrature Encoder

This isn't a good fit for the Jag, but for teams wanting another way to interface an encoder, this part is a good choice and sets up an interesting software project.

This project is very good to see as-is, just wanted to offer another avenue in case it is helpful to anyone. Also, studying the data sheet enough to understand it can be a good way to learn -- possibly with some mentor or student discussion mixed in.

Last edited by nuttle : 10-05-2013 at 23:53. Reason: fixed link
  #24   Spotlight this post!  
Unread 11-05-2013, 01:49
Levansic's Avatar
Levansic Levansic is offline
Registered User
AKA: Len Evansic
FRC #0585 (Cyber Penguins)
Team Role: Mentor
 
Join Date: Jan 2012
Rookie Year: 2008
Location: Tehachapi, CA
Posts: 185
Levansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud of
Re: Arbitrary Quadrature Encoder

Quote:
Originally Posted by calvin909090 View Post
Why are you guys using op-amps instead of comparators? Comparators output a direct digital signal...
That's a good question!

There are several reasons that are tied together, but I'll start with the easiest first. Comparators are specialized op-amps. Our original circuit was attempted with comparators, and didn't "work". Switching to more general-purpose LM741 op-amps, which were available at the local Radio Shack, made it work, and the LM324 is a quad version of this op-amp.

In reality, the first phase probably worked fine, but we couldn't sink or source enough current to drive the second phase LED's for feedback. That's the problem with using comparators for this circuit. They are typically connected to high-impedance logic inputs and not driving current consumers. Using the LM339 for example, it sources nil current at high signal, and only sinks 15 mA at low signal. While this will light our indicator LED's, it would be at a much lower intensity. In our circuit, we source the current for the LED's from the op-amp, rather than sinking or switching a transistor.

There are comparators that can sink or source comparable current to what the LM324 can supply, but they are much more expensive than the LM324. We could have split the phases apart and used a dual comparator for the first phase and a dual op-amp for the second, but we wanted to reduce component count.
  #25   Spotlight this post!  
Unread 11-05-2013, 02:20
Levansic's Avatar
Levansic Levansic is offline
Registered User
AKA: Len Evansic
FRC #0585 (Cyber Penguins)
Team Role: Mentor
 
Join Date: Jan 2012
Rookie Year: 2008
Location: Tehachapi, CA
Posts: 185
Levansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud of
Re: Arbitrary Quadrature Encoder

Quote:
Originally Posted by nuttle View Post
This isn't a good fit for the Jag, but for teams wanting another way to interface an encoder, this part is a good choice and sets up an interesting software project.
Last Fall, we had a few discussions about adding a chip like this to this project. Looked at an Arduino-compatible chip, thinking we could find a scope to meet the creep. With the current control system, the only way we could see this as adding value would be if we also included a CAN transceiver. At that point, you're probably already using Jaguars, which have everything you need for a simple encoder without needing to have a counter chip.

If you use a chip like this, you would have to use I2C to make it practical. It would also need an easy way to change the address, so it does not conflict with the existing accelerometers that can use I2C. If you used SPI or RS-232, then you would only have one encoder per robot. You could hang more off of an onboard laptop or Raspberry PI, but that would probably violate current rules.

In the end, we figured we could expand in this direction if it made more sense in the future. I guess we'll find out in August if it would just be cool to play with, or more useful for the next system.

This is the engineer's conundrum of doing it because you can versus canning it because you should.

Last edited by Levansic : 11-05-2013 at 09:50.
  #26   Spotlight this post!  
Unread 12-05-2013, 18:55
Levansic's Avatar
Levansic Levansic is offline
Registered User
AKA: Len Evansic
FRC #0585 (Cyber Penguins)
Team Role: Mentor
 
Join Date: Jan 2012
Rookie Year: 2008
Location: Tehachapi, CA
Posts: 185
Levansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud of
Re: Arbitrary Quadrature Encoder

The prototype boards have arrived!



Boy are these things small. If all goes well, we should have the first one assembled tomorrow.
  #27   Spotlight this post!  
Unread 13-05-2013, 10:35
nuttle nuttle is offline
Registered User
AKA: Allen Nuttle
FRC #4080
Team Role: Mentor
 
Join Date: Mar 2010
Rookie Year: 2009
Location: United States
Posts: 104
nuttle has much to be proud ofnuttle has much to be proud ofnuttle has much to be proud ofnuttle has much to be proud ofnuttle has much to be proud ofnuttle has much to be proud ofnuttle has much to be proud ofnuttle has much to be proud of
Re: Arbitrary Quadrature Encoder

Looks nice -- have fun!

BTW, I think you could connect up to 8 of the encoder chips I mentioned over SPI, using something like a 74LS138 (and even more using a similar scheme with more/different parts to select which chip to enable). The datasheet for the encoder chip shows this in Fig 15. You'd hook the SS* line from each chip to one of the outputs from the 74LS138, and inputs to the 74LS138 would be three digital output lines, plus the original chip select line from the digital side car. You would use the three digital output lines to choose which encoder chip to interact with, one at a time. Other than this, the rest of the SPI usage should be unchanged. If someone out there is looking to try something like this, I just wanted to follow up.

Good luck with the project, it will be very useful I'm sure and to others as well. Thanks for sharing!

Last edited by nuttle : 13-05-2013 at 10:39. Reason: fix links
  #28   Spotlight this post!  
Unread 14-05-2013, 17:24
Levansic's Avatar
Levansic Levansic is offline
Registered User
AKA: Len Evansic
FRC #0585 (Cyber Penguins)
Team Role: Mentor
 
Join Date: Jan 2012
Rookie Year: 2008
Location: Tehachapi, CA
Posts: 185
Levansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud of
Re: Arbitrary Quadrature Encoder

Quote:
Originally Posted by nuttle View Post
BTW, I think you could connect up to 8 of the encoder chips I mentioned over SPI, using something like a 74LS138 (and even more using a similar scheme with more/different parts to select which chip to enable).

That sounds like a lot of work. It also sounds like a central interface for a bunch of encoders, rather than individual encoders. Nothing wrong with that, but that would be a bit more specialized than our plain encoders.

We kind of ignore SPI existing on the digital sidecar, as we've never got it to work correctly. This contrasts with our experience with I2C, which just works. Perhaps it is the programming environment and libraries that we use (LabView), or perhaps the implementation of SPI on the accelerometer. Sometimes should work and does work aren't in the same ballpark.
  #29   Spotlight this post!  
Unread 15-05-2013, 01:14
Bneufeld235's Avatar
Bneufeld235 Bneufeld235 is offline
Registered User
FRC #0585 (Cyber Penguins)
Team Role: Programmer
 
Join Date: Apr 2013
Rookie Year: 2011
Location: Tehachapi, Ca
Posts: 9
Bneufeld235 is an unknown quantity at this point
Re: Arbitrary Quadrature Encoder

First round of hand-soldered printed circuit boards work! For actual production we do plan on soldering the boards with a machine but for the prototype boards it will easier and cheaper to do it by hand. We have done minor testing; there needs to be a few adjustments to the values of some resistors but other than that it is successful.
[IMG]http://tehachapi-stem.org/images/First_born.jpg[/IMG]
__________________
2013 - Electrical, Programming, and Mechanical; Las Vegas Dean's List Finalist
2012 - Electrical and Programming; Las Vegas Regional Chairman's Award

Last edited by Bneufeld235 : 15-05-2013 at 01:38.
  #30   Spotlight this post!  
Unread 15-05-2013, 23:12
nuttle nuttle is offline
Registered User
AKA: Allen Nuttle
FRC #4080
Team Role: Mentor
 
Join Date: Mar 2010
Rookie Year: 2009
Location: United States
Posts: 104
nuttle has much to be proud ofnuttle has much to be proud ofnuttle has much to be proud ofnuttle has much to be proud ofnuttle has much to be proud ofnuttle has much to be proud ofnuttle has much to be proud ofnuttle has much to be proud of
Re: Arbitrary Quadrature Encoder

You have to pay attention to signal integrity when working with anything even slightly high-speed on the digital side car. We've had good success with SPI, but I don't want to take things off topic. Your project is great!

FWIW, here's a photo of a 6-encoder board we used for Lunacy, before it was legal to use CAN. This worked really well, it used the digital I/O lines as a bus to interface a similar (but non-SPI) encoder chip. At first, the digital I/O lines had enough bounce to cause occasional problems, one major source was the long round cable used to connect the cRIO to the DSC that year, at least if you went with the KoP solution. The ribbon cable connected to the digital I/O on the DSC and the other connectors were to encoders and coast/brake inputs (I think we decided this wasn't legal and left these off).

This type of thing is a good off-season project, it does normally take a while to get everything working well, including the software! Again, it is great that this is being done; thanks for sharing and good luck!
Attached Files
File Type: pdf encoders.pdf (242.6 KB, 39 views)
Closed Thread


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


All times are GMT -5. The time now is 20:17.

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