Parallax Forums
  HomeLog InRegisterCommunity CalendarSearch the ForumHelp
   
Parallax Forums > Public Forums > Propeller Chip > RC Decay  Forum Quick Jump
 
New Topic Post Reply Printable Version
[ << Previous Thread | Next Thread >> ] | Show Newest Post First ]

Earl Foster
Registered Member



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Nov 2004
Total Posts : 171
 
   Posted 11/2/2009 8:23 PM (GMT -8)    Quote This PostAlert An Admin About This Post.
I have been troubleshooting an RC Decay problem I experiencing without success. I designed a servo controller board that will allow me to adjust 3 servos normal and active positions using a standard RC Decay circuit and code. It works perfect on my breadboard each and every time. However, on my PCB I get spikes and the servos shake constantly while trying to calibrate them so I don't know if they are positioned correctly. The servos work smoothly during operation so I have ruled out power supply issues.

Since it works on the breadboard I have to assume it has something to do with my pcb layout. I have reviewed my schematic and pcb layout many times and everything seems to be in order. I also tried connecting the RC Decay circuit on the breadboard to an unused pin on the pcb with the same jerky results.

I am looking for ideas of what could be the problem and possible next steps in troubleshooting.

Thanks
-earl

Per standard help protocol I have uploaded everything (Code, schematic, pcb layout, printout of normal and jerky decay). I use ExpressPCB/SCH if anybody wants to look over them.


WWW.HAPB.NET
"Don't ask yourself what the world needs - ask yourself what makes you come alive, and then go do it." - H.T.Whitman


Image Attachment :
Image Preview
PST-Breadboard.jpg
  81KB (image/pjpeg)
This image has been viewed 23 time(s).
Image Attachment :
Image Preview
PST-PCB.jpg
  64KB (image/pjpeg)
This image has been viewed 17 time(s).

File Attachment :
SCBv4.sch   33KB (application/octet-stream)
This file has been downloaded 2 time(s).

File Attachment :
SCBv4.pcb   24KB (application/octet-stream)
This file has been downloaded 4 time(s).

File Attachment :
AdjustableRCDecay.spin   3KB (application/octet-stream)
This file has been downloaded 3 time(s).
Back to Top
 

StefanL38
Registered Member

Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Sep 2006
Total Posts : 958
 
   Posted 11/2/2009 10:54 PM (GMT -8)    Quote This PostAlert An Admin About This Post.
if you want all forum members beeing able to help you easily provide PNG-graphics or jpg-graphics of ciruit and pcb-layout
if you have an oscilloscope it would be useful to add screenshots of the scope how the spikes look like

best regards

Stefan
Back to Top
 

Earl Foster
Registered Member



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Nov 2004
Total Posts : 171
 
   Posted 11/3/2009 3:30 AM (GMT -8)    Quote This PostAlert An Admin About This Post.
I started to do but I figured if somebody wanted to review the pcb they would need the pcb file to see the layers. JPG uploaded in addition to other files. thanks.


WWW.HAPB.NET
"Don't ask yourself what the world needs - ask yourself what makes you come alive, and then go do it." - H.T.Whitman


Image Attachment :
Image Preview
SCBv4-PCB.jpg
  99KB (image/pjpeg)
This image has been viewed 38 time(s).
Image Attachment :
Image Preview
SCBv4-SCH.jpg
  320KB (image/pjpeg)
This image has been viewed 30 time(s).
Back to Top
 

Cluso99
We live onboard



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Apr 2008
Total Posts : 2277
 
   Posted 11/3/2009 6:34 AM (GMT -8)    Quote This PostAlert An Admin About This Post.
Sorry, your pcb has basic design flaws. You MUST connect both sets of power pins on the prop and you must use decoupling caps. See the recent pcb thread for links to lots of discussions - it has been placed on the wiki. That will be your first problem to solve.


Links to other interesting threads:
Back to Top
 

Earl Foster
Registered Member



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Nov 2004
Total Posts : 171
 
   Posted 11/3/2009 10:01 AM (GMT -8)    Quote This PostAlert An Admin About This Post.

I can easily install a cap and connect the other VDD.  Interestingly enough I had never heard that before but it has been a long time since I last visited the forum.  Will try that tonight. thx


WWW.HAPB.NET
"Don't ask yourself what the world needs - ask yourself what makes you come alive, and then go do it." - H.T.Whitman

Back to Top
 

Earl Foster
Registered Member



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Nov 2004
Total Posts : 171
 
   Posted 11/3/2009 6:06 PM (GMT -8)    Quote This PostAlert An Admin About This Post.
Incorporated the circuit changes with no change in results. The RC decay is still jerky on the pcb but not on the breadboard.


WWW.HAPB.NET
"Don't ask yourself what the world needs - ask yourself what makes you come alive, and then go do it." - H.T.Whitman

Back to Top
 

BradC
Gronk



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Jul 2007
Total Posts : 1577
 
   Posted 11/3/2009 6:36 PM (GMT -8)    Quote This PostAlert An Admin About This Post.
I'm a little unsure as you your precise component placement on the PCB, but it *looks* like you have a pretty light VSS line circling the board. I wonder if your servo currents are causing noise on the VSS line. It'll be a self feeding loop. Your servo moves and changes the RC value, your RC value changes so you move the servo; lather; rinse; repeat.

Your RC value is _absolutely_ dependent on a clean, stable earth. I'm not sure that is what you are giving it. What is your track size?


If you always do what you always did, you always get what you always got.

Back to Top
 

kwinn
Registered Member

Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Sep 2008
Total Posts : 1100
 
   Posted 11/3/2009 8:17 PM (GMT -8)    Quote This PostAlert An Admin About This Post.
It could also be that the extra capacitance of a breadboard that prevents the problem showing up there.
Back to Top
 

Earl Foster
Registered Member



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Nov 2004
Total Posts : 171
 
   Posted 11/3/2009 8:37 PM (GMT -8)    Quote This PostAlert An Admin About This Post.
The width of the grounds are 0.20 and measure 0 ohms. Everything is measuring what it should. Oh well bite the bullet and redesign. Thanks for the ideas.


WWW.HAPB.NET
"Don't ask yourself what the world needs - ask yourself what makes you come alive, and then go do it." - H.T.Whitman

Back to Top
 

BradC
Gronk



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Jul 2007
Total Posts : 1577
 
   Posted 11/3/2009 8:45 PM (GMT -8)    Quote This PostAlert An Admin About This Post.
Earl Foster said...
The width of the grounds are 0.20 and measure 0 ohms. Everything is measuring what it should. Oh well bite the bullet and redesign. Thanks for the ideas.


Umm.. what is 0.20 ?

You won't measure a problem with your multi-meter. You won't see a problem until you have a nice current flowing, when you will start to see some voltage drop in the lines.

Grab some nice fat wire and tack *individual* earths in a star from your regulator to the Prop (both earth pins), the gnd of the RC circuit and the GND's of your servos. Leave all the existing tracks connected. I'll wager it won't solve the problem, but I'll sure bet that the amplitude of the variation is reduced significantly. It might also help to put some good, low impedance caps directly across the power pins of the servos.

If that helps at all, then it points to the layout as being the problem.


If you always do what you always did, you always get what you always got.

Back to Top
 

potatohead
640 Pixels... :)



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Sep 2006
Total Posts : 1340
 
   Posted 11/3/2009 8:48 PM (GMT -8)    Quote This PostAlert An Admin About This Post.
20/1000 Inch maybe?


Propeller Wiki: Share the coolness!
Chat in real time with other Propellerheads on IRC #propeller @ freenode.net
Safety Tip: Life is as good as YOU think it is!

Back to Top
 

BradC
Gronk



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Jul 2007
Total Posts : 1577
 
   Posted 11/3/2009 8:54 PM (GMT -8)    Quote This PostAlert An Admin About This Post.
potatohead said...
20/1000 Inch maybe?


.2 of a mm ?


If you always do what you always did, you always get what you always got.

Back to Top
 

potatohead
640 Pixels... :)



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Sep 2006
Total Posts : 1340
 
   Posted 11/3/2009 9:03 PM (GMT -8)    Quote This PostAlert An Admin About This Post.
That's really, really small!

From the scale of the image, it's inches.


Propeller Wiki: Share the coolness!
Chat in real time with other Propellerheads on IRC #propeller @ freenode.net
Safety Tip: Life is as good as YOU think it is!

Back to Top
 

whicker
Registered Member

Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Apr 2007
Total Posts : 79
 
   Posted 11/4/2009 1:07 PM (GMT -8)    Quote This PostAlert An Admin About This Post.
Is it just me, or is there a + intersection right at propeller chip pin #2?

That's actually tying it to pin #12, and pin #8 of the eeprom? (3.3V?)
Back to Top
 

Dr_Acula
Registered Member



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Dec 2008
Total Posts : 612
 
   Posted 11/4/2009 4:01 PM (GMT -8)    Quote This PostAlert An Admin About This Post.
Not sure if it has been mentioned, but I can't see some bigger supply caps at the regulators. Even battery powered equipment needs the caps. There are no hard and fast rules, but generally you need some big caps and small caps. Some might disagree with the values I use, but I got some job lots of caps and put them all in. At the input to the first regulator something like 470uF 16V electrolytic. You can leave the 0.33uF there as well if you like. Then after the 7805 I tend to put a 10uF to 22uF tantalum. And a 0.1uF. And after the 3V3 reg I also use a 10uF to 22uF tantalum. Then I put 0.1uf bypass caps physically next to every chip on the board between their power supply pins. Possibly it is overkill having a 0.1uF next to the prop and also next to the eeprom, but the caps are cheap.

Also I presume the batteries are >7V when almost flat, ie at least 7 cells? Or is it powered by a wall wart?

With shaking servos I'd be very suspicious of a non stable power supply.

For years I persisted with trying to debug mysterious faults like this. Then I went and bought a $110 CRO. It makes things so much easier. You can see the RC waveform on a screen. You can put it on a power supply and quickly click through all the timebase settings to look for waveforms at different frequences (eg 60Hz and megahertz instabilities). And you can look at the waveform going into the servos and see if it is a clean square wave. Can you get access to a CRO?

Post Edit - I was looking at the circuit again and wondering why you even need a 5V regulator as everything is powered by 3V. Then I noticed the 5V is actually powering the servos. That is going to get very difficult. Even 22uF on the 5V supply isn't going to be nearly enough. You might need to run the 3V reg directly off the battery rather than via the 5V reg. And you might want to have the earth wires from the servos going to the 5V reg and then straight to the battery -ve. Ditto the earth from the board, so the earths are a 'star' that comes from the battery. Even then you might not get it stable enough. I've pulled to bits many radio controlled cars etc and many use seperate supplies, eg a 9V battery to do the electronics, and 4 nicads to do the servos. With the prop running at 3V you could do things a bit differently, eg use 4 small nicads and a low(ish) dropout 3V reg. And power the servos directly off 4 AA nicads without even needing to regulate that supply.


www.smarthome.viviti.com/build

Post Edited (Dr_Acula) : 11/5/2009 12:14:46 AM GMT

Back to Top
 

Bobb Fwed
Registered Member

Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Apr 2008
Total Posts : 307
 
   Posted 11/4/2009 4:59 PM (GMT -8)    Quote This PostAlert An Admin About This Post.
I know it may be a bit late for this (seeing as you already have your PCB made up). But I have a bit of a fondness for using ADCs for inputs like this. Getting the current pot position would be a simple matter of getting the ADC's value: 50% of the max value is middle, and as you move the pot, the value swings between 0% and 100%. They are fairly cheep ($2.20 for an eight channel from my supplier), and you could put pots on all eight channels. You could then add a capacitor to reduce any jitter received from your PCB design, or just smooth the changes in the input.

As to solving your currently problem, other than some PCB design problems, and the lack of power planes, I think you might just need more capacitors as others have stated. When in doubt decouple the ICs, and for power (on either side of the regulators) err on the side of larger capacitors (electrolytic: generally larger capacity means less ESR), and smaller ceramic caps as high frequency low pass filters.


April, 2008: when I discovered the answers to all my micro-computational-botherations!

Some of my objects:
MCP3X0X ADC Driver - Programmable Schmitt inputs, frequency reading, and more!
Simple Propeller-based Database - Making life easier and more readable for all your EEPROM storage needs.
String Manipulation Library - Don't make strings the bane of the Propeller, bend them to your will!

Back to Top
 
[ << Previous Thread | Next Thread >> ]
New Topic Post Reply Printable Version
 
Forum Information
Currently it is Saturday, November 21, 2009 11:36 AM (GMT -8)
There are a total of 393,860 posts in 55,536 threads.
In the last 3 days there were 84 new threads and 711 reply posts. View Active Threads
Who's Online
This forum has 17692 registered members. Please welcome our newest member, old guy.
54 Guest(s), 14 Registered Member(s) are currently online.  Details
Siri, keith_kw, Jay Kickliter, Mike Green, Bob Lawrence (VE1RLL), Dogg, hover1, ErNa, Harley, Sapieha, Electronegativity, Tubular, Leon, MicroDirk