Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
DaTroof
Nov 16, 2000

CC LIMERICK CONTEST GRAND CHAMPION
There once was a poster named Troof
Who was getting quite long in the toof

Luigi Thirty posted:

i got really bored and started writing a basic VERB NOUN text adventure parser in python

same but in ruby

Adbot
ADBOT LOVES YOU

Bloody
Mar 3, 2013

Base Emitter posted:

because then if and when the supply is backwards its effectively shorted and the diode is carrying the full current the supply will generate

in series the diode has no current when the supply is connected backwards, and normal current when connected correctly.

i guess i'm too accustomed to benchtop supplies where i can set the current limit on the supply to like expected operating current + 10%

Doc Block
Apr 15, 2003
Fun Shoe
OK, can I eliminate the 10K resistor in this circuit with no ill effects? I've always read that I should wire up potentiometers like shown, essentially like a voltage divider, but I have no idea why it needs to be like a voltage divider instead of just wiring the pot's wiper straight to the ADC. I want to get a PCB made, and if the resistor could be eliminated that'd let me make the PCB smaller.



I breadboarded it up on an Arduino both with and without the resistor, and the value read back was different. Turning the pot as close to halfway as I could without the resistor gave me 508 (p much halfway for a 10-bit ADC), but with the resistor gave me 406 (not having touched the pot or anything else).

edit: the pot is wired up so that one outside pin goes to VCC, the other outside pin to GND.

Doc Block fucked around with this message at 08:57 on Feb 26, 2014

theadder
Dec 30, 2011


a++ diagram doc block

Doc Block
Apr 15, 2003
Fun Shoe
:tipshat:

Sagebrush
Feb 26, 2012

Doc Block posted:

OK, can I eliminate the 10K resistor in this circuit with no ill effects? I've always read that I should wire up potentiometers like shown, essentially like a voltage divider, but I have no idea why it needs to be like a voltage divider instead of just wiring the pot's wiper straight to the ADC.

i think you're confusing potentiometers with variable resistors

a variable resistor needs to be connected the way that is shown there because it forms a voltage divider and varying the resistor varies the voltage going into the adc.

a potentiometer with three terminals forms a voltage divider on its own because you are wiping a contact across a single carbon trace that's connected on both ends. it's even better than a normal voltage divider with a single variable though because both of the resistances are the inverse of each other. imagine like this

code:
          carbon trace
===================================


       measured R = 10k
===================================
^                                 ^


      measured R = 5k
===================================
^               ^


  putting wiper in the middle = two resistances

5v -> =================================== <- GND
            5k        ^        5k
                      |
                  to arduino
                  v = 2.5v



5v -> =================================== <- GND
         3k    ^         7k        
               |
           to arduino
             v = 3.5v


5v -> =================================== <- GND
                7k            ^    3k        
                              |
                         to arduino
                          v = 1.5v

get it? so you get a divider that actually varies across the full range, instead of an abbreviated range like you would get if you had (say) a 10k fixed resistance on one side and a 0-10k variable on the other. cause then you would get this (this is where you need a separate resistor on both sides)

code:

      varistor at 0 ohms

          /
5v -> [  0  ] ----- [ 10k ] <- GND
        /       ^                 
                |
            to arduino
             v = ~5v

      
       varistor at 10k ohm

           /
5v -> [  10k  ] ----- [ 10k ] <- GND
         /        ^                 
                  |
             to arduino
               v = 2.5
with half the range right. you max out the varistor but it's still a 50-50 voltage divider. because you can never cut the fixed resistance on the ground side to zero, you can't actually probe 0v at the center terminal. you could sorta fix this by making it like a 10k varistor and a 100 ohm fixed resistance, so when the varistor is at max the 100 ohm seems very small in comparison, but then you have a 100:1 exponential action instead of the nice smooth linear thing you get with a pot

so anyway when you are adding the extra resistor to one end of the circuit, you're basically just biasing it in one direction by adding an invariant resistance to that side of the divider. which is why you get 400 instead of 500 with the pot centered.

code:

5v -> =================================== -- [  10k  ] <- GND
            5k        ^        5k
                      |
                  to arduino
                  v = 1.25v

you don't need the extra resistor.

Sagebrush fucked around with this message at 09:36 on Feb 26, 2014

theadder
Dec 30, 2011



irl enjoyed

Doc Block
Apr 15, 2003
Fun Shoe

Sagebrush posted:

you don't need the extra resistor.

cool, tyvm.

Sagebrush
Feb 26, 2012

actually wait the topology is different. what you are getting is this

code:

5v -> ========================= <- GND
           5k     ^      5k
                  |
                  |
                 2.5v ---[some resistance]--------[ 10k ] <--- GND
                                              |
                                              |
                                          [arduino]
                          
given that we know one side is 10k and you're reading 408 (which if 1024 = 5v means you're reading 1.95v at the arduino) you can determine that the unknown resistance is 2.8k~. that's weird, it shouldn't be that high.

Sagebrush
Feb 26, 2012

oooh right your ground is tied to both sides of the voltage dividers you're using and that's going to alter the effective resistance. 'm not going to dig out kirchoff's laws cause it's way too late and i'm going to sleep but basically yeah the topology is all hosed up and nonlinear if you add that other resistor. just leave it out, vcc to one side of the pot and gnd to the other, probe the center pin, you're good to go.

Doc Block
Apr 15, 2003
Fun Shoe
Thx man.

802.11weed
May 9, 2007

no
you guys wanna see some really fuckin janky electronic hack?



no idea how it survived the bumpy 50km ride home & still worked for months .. replaced it but now somethin else is hosed because of (less janky) hacks just expiring i guess

Socracheese
Oct 20, 2008

:stare:

those leads arent even insulated are they

Bloody
Mar 3, 2013

802.11weed posted:

you guys wanna see some really fuckin janky electronic hack?



no idea how it survived the bumpy 50km ride home & still worked for months .. replaced it but now somethin else is hosed because of (less janky) hacks just expiring i guess

:golfclap:

Sagebrush
Feb 26, 2012

802.11weed posted:

you guys wanna see some really fuckin janky electronic hack?



no idea how it survived the bumpy 50km ride home & still worked for months .. replaced it but now somethin else is hosed because of (less janky) hacks just expiring i guess

excellent

802.11weed
May 9, 2007

no
some of the leads most likely touched others which explains the game acting really loving weird sometimes. there's this sound after you've lost your last ball & the game is trying to get you to buy in for another, it's a lady moaning "ooh, one more time". for a little while it would play that sound clip for every sound effect. every bumper hit, every switch, every fuckin thing

it was great

Jonny 290
May 5, 2005



[ASK] me about OS/2 Warp

Base Emitter posted:

because then if and when the supply is backwards its effectively shorted and the diode is carrying the full current the supply will generate


In several of my radios this is exactly what they do BUT BUT BUT it's intended to blow a fuse upstream of the diode.

I found out about these little protection diodes when I hooked a gel-cell battery up backwards without a fuse inline and made a ham radio literally catch fire and billow smoke (it was the diode dissipating 100 amps or whatever stupid amount that battery could source)

(and yes I fixed the radio and it works to this day)

Doc Block
Apr 15, 2003
Fun Shoe
Welp, I sent off to have a PCB made for my fume extractor. It's gonna be a lot smaller than the protoboard version, so hopefully it'll be small enough to fit into an enclosure that isn't xbox huge.

Hope I didn't gently caress anything up!

Jonny 290
May 5, 2005



[ASK] me about OS/2 Warp
If I can figure out how to strap my dremel perfectly vertical in my drill press I can drill PCB holes and since I can etch I could then make finished boards at home, would be dope

med school head
Apr 17, 2012

Jonny 290 posted:

If I can figure out how to strap my dremel perfectly vertical in my drill press I can drill PCB holes and since I can etch I could then make finished boards at home, would be dope

i like the way you think jonny

Glorgnole
Oct 23, 2012

Jonny 290 posted:

If I can figure out how to strap my dremel perfectly vertical in my drill press I can drill PCB holes and since I can etch I could then make finished boards at home, would be dope

could you just put a tiny drill bit or grinding head in the drill press chuck and skip the dremel entirely?

colbylol posted:

i like the way you think jonny

Doc Block
Apr 15, 2003
Fun Shoe
my dremel wobbles way too much for me to ever trust it with precision work.

Bloody
Mar 3, 2013

Jonny 290 posted:

If I can figure out how to strap my dremel perfectly vertical in my drill press I can drill PCB holes and since I can etch I could then make finished boards at home, would be dope

pcb holes like vias? problem with them is they suck if you don't have a plater :-/ soldering lil bitty wires through the holes is a pain in the rear end. just get boards made imo, its dirt cheap anyways

Jonny 290
May 5, 2005



[ASK] me about OS/2 Warp
spoken by a man that doesnt enjoy hand-painting board etch masks with an ugly shade of his SO's nail polish that he's trying to get rid of

Sagebrush
Feb 26, 2012

Jonny 290 posted:

If I can figure out how to strap my dremel perfectly vertical in my drill press I can drill PCB holes and since I can etch I could then make finished boards at home, would be dope

3d print a mounting plate adapter cradle kind of thing

GameCube
Nov 21, 2006

i've got a drat computer engineering degree and i still don't know how to make my own pcb, at all. i'm pretty sure i'm not even using perfboard properly

Bloody
Mar 3, 2013

Werthog 95 posted:

i've got a drat computer engineering degree and i still don't know how to make my own pcb, at all. i'm pretty sure i'm not even using perfboard properly

install diptrace

Jonny 290
May 5, 2005



[ASK] me about OS/2 Warp

Sagebrush posted:

3d print a mounting plate adapter cradle kind of thing

I've got enough U-bolts and sheets of aluminum to make shims that I could probably honestly knock this out with a little bit of work

peepsalot
Apr 24, 2007

        PEEP THIS...
           BITCH!

Glorgnole posted:

could you just put a tiny drill bit or grinding head in the drill press chuck and skip the dremel entirely?
drill press rpm is like 10x slower rpm than a dremel, you need high rpm on smaller bits because the speed of the cutting face is directly proportional to the radius of the bit.

Captain Cool
Oct 23, 2004

This is a song about messin' with people who've been messin' with you

Werthog 95 posted:

i've got a drat computer engineering degree and i still don't know how to make my own pcb, at all. i'm pretty sure i'm not even using perfboard properly
back in the day a guy named sijosae got me to clean up my perfboard work http://www.headphoneamp.co.kr/ftp/sijosae/Gallery/

I remember him refusing to comment on how they sound, said he had a tin ear and just liked building the things

Only registered members can see post attachments!

Jonny 290
May 5, 2005



[ASK] me about OS/2 Warp
n o i c e

is that wrap wire?

spankmeister
Jun 15, 2008






oh yeah that reminds me i have a spool of 30AWG kynar from way back when i was modding ps2's :getin:

Captain Cool
Oct 23, 2004

This is a song about messin' with people who've been messin' with you

Jonny 290 posted:

n o i c e

is that wrap wire?
no idea, i always just used the extra leads trimmed off resistors

01011001
Dec 26, 2012

Werthog 95 posted:

i've got a drat computer engineering degree and i still don't know how to make my own pcb, at all. i'm pretty sure i'm not even using perfboard properly

quick and dirty pcb for giant babbys based on my half-baked memories of my packaging class 2 years ago:

-take some copper cladded board and ferric chloride from radio shack
-draw traces with a sharpie. there are less lovely ways to do this like printing the pattern from eagle on magazine paper and ironing on but gently caress it, point is ink-on-copper
-dip that poo poo in the ferric chloride for whatever listed amount of time it is, i dont fuckin remember. when ur done put some baking soda in that poo poo so it doesnt gently caress up everything wherever you dispose of it
-drill, baby, drill

any of you knowledgable fuckos feel free to add/correct

Jonny 290
May 5, 2005



[ASK] me about OS/2 Warp
nope thats pretty much it. except one thing to note is that agitation speeds the etch process a shitload. If you want your boards to etch clean and fast, do it in a covered dish that you sit on top of the washing machine as you do a load of clothes

just make sure you dont dump ferric chloride on your laundry :v:

Bloody
Mar 3, 2013

better yet just go here http://dorkbotpdx.org/wiki/pcb_order and pay like five dollars and get your dumb and bad circuit fabbed on surprisingly high quality 2- or 4-layer boards

GameCube
Nov 21, 2006

kewl. now i just have to make some circuits.

Doc Block
Apr 15, 2003
Fun Shoe

Bloody posted:

better yet just go here http://dorkbotpdx.org/wiki/pcb_order and pay like five dollars and get your dumb and bad circuit fabbed on surprisingly high quality 2- or 4-layer boards

Ordered my fume extractor PCB from these guys (via oshpark.com) and it seems like pretty quick turnaround for the price. Waaaay faster than BatchPCB, who were cheaper but only put your boards in a batch when they could find room on a panel amonst SparkFun's own PCB needs, and since the boards were made in China they had a long lead time and had to come back through customs, etc.

edit: but now that I've submitted my order I can't help but think of all the things I could've done differently.

Doc Block fucked around with this message at 22:25 on Feb 28, 2014

01011001
Dec 26, 2012

Bloody posted:

better yet just go here http://dorkbotpdx.org/wiki/pcb_order and pay like five dollars and get your dumb and bad circuit fabbed on surprisingly high quality 2- or 4-layer boards

well yeah thats the correct answer but the diy method is fun to do once or twice

Adbot
ADBOT LOVES YOU

Doc Block
Apr 15, 2003
Fun Shoe
So after the whole thing where the diode on my fume extractor was too hot to touch, I bought the biggest diode I could find on Jameco. A handful of them arrived in the mail today.



From looking at the data sheet I knew it'd be big, but holy poo poo it's huge. Those leads are about 1mm in diameter. According to the data sheet this bigass bastard will do 6 amps continuous current at room temperature.

(those are vanilla 1N4007s on the left)

Doc Block fucked around with this message at 03:52 on Mar 2, 2014

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply