What resistors should i use for this circuit

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • evilkitty
    Badcaps Veteran
    • Nov 2017
    • 299
    • USA

    #1

    What resistors should i use for this circuit

    I have 2N2222A and TIP120 on hand, assuming my 2N2222As i got on ebay are complaint with the spec they should be fine for this having a max of 0.5A sustained and i have a 1n5817 forward voltage should be 0.32v

    This circuit is for me light strip i use for my keyboard, where my PICO will control the light based on a photocell and my magnetic switch MC-38 will pull the base of the transistor to 0v if my keyboard tray is pushed in all the way, meanwhile i have my override switch, the switch has 6 pins i would use 2 of each pair of 3

    note that the GPIO pin i on the other end of a 25' (~7.6m) ethernet cable, i have 3.3, 5, and 12v Rails generated at this end of the ethernet cable, pico gets power via 25ft speaker wire with a micro usb plug on the end so vdrop on the main power lines is not a issue, vdrop on the 3.3v gpio pin may matter
    Attached Files
    Last edited by evilkitty; 04-27-2023, 10:37 AM.
  • eccerr0r
    Solder Sloth
    • Nov 2012
    • 8696
    • USA

    #2
    Re: What resistors should i use for this circuit

    2N2222A if you get a real one is probably acceptable, I'd call it marginal and if you decide to increase the LEDs it'd be bad. 2N4401 is probably better. TIP120 will work for more cases.

    For 2N2222A/2N4401, 120-150 ohms for either, closer to 120 ohms for R1, 150 ohms is okay for R2.
    For TIP120, 1KΩ should do it for either R1 or R2.

    Comment

    • evilkitty
      Badcaps Veteran
      • Nov 2017
      • 299
      • USA

      #3
      Re: What resistors should i use for this circuit

      Thanks, 27.5mA on the gpio pin... I'll go with a TIP120

      Comment

      • eccerr0r
        Solder Sloth
        • Nov 2012
        • 8696
        • USA

        #4
        Re: What resistors should i use for this circuit

        No, it's not going to be 27.5mA, it's a bit less than that...but yes the TIP120 will reduce current flow.
        If you want to really push your luck and depend on the characteristics of the individual transistor you can go up to 270Ω or so, but at this point you'll be depending on the transistor's specific characteristics. You might have a bad one and it won't work too well.

        Actually know what, think i misplaced a decimal point... 1K-1.2K should work for the 2n2222 but still have the pushing it caveat...
        Last edited by eccerr0r; 04-27-2023, 09:06 PM.

        Comment

        • evilkitty
          Badcaps Veteran
          • Nov 2017
          • 299
          • USA

          #5
          Re: What resistors should i use for this circuit

          Originally posted by eccerr0r
          No, it's not going to be 27.5mA, it's a bit less than that...
          when a switch pulls the transistor base down it will 3.3v GPIO -> resistor -> ground that would be max current draw
          Last edited by evilkitty; 04-28-2023, 08:08 AM.

          Comment

          • eccerr0r
            Solder Sloth
            • Nov 2012
            • 8696
            • USA

            #6
            Re: What resistors should i use for this circuit

            Nah it will be less than it because the transistor itself will not let all that current flow. However this is moot as I didn't do due diligence with units and tried to shortcut milli- and kilo- and it should work with 1K resistors for both R1 and R2, provided the 2N2222 is up to snuff and not fake (i.e. more like 2N4401 and less like 2N3904).

            Comment

            • evilkitty
              Badcaps Veteran
              • Nov 2017
              • 299
              • USA

              #7
              Re: What resistors should i use for this circuit

              Originally posted by eccerr0r
              Nah it will be less than it because the transistor itself will not let all that current flow. However this is moot as I didn't do due diligence with units and tried to shortcut milli- and kilo- and it should work with 1K resistors for both R1 and R2, provided the 2N2222 is up to snuff and not fake (i.e. more like 2N4401 and less like 2N3904).

              did you look how my override circuit works? that circut works by jumping the base to ground before the diode, that would be max current draw, if it gets to the transistor it would be lower, but at 1k ohm that is not a concern

              anyway this is how my 2n2222a shows up on my tester, useful?

              is there a way i can test for the hFE? figuring out the hFE is the part i do not understand in the base formula
              Attached Files

              Comment

              • eccerr0r
                Solder Sloth
                • Nov 2012
                • 8696
                • USA

                #8
                Re: What resistors should i use for this circuit

                ah I see now, thought you would just open the circuit if you want to disable it, seems kind of silly to short it to ground.
                and beta/hfe depends on the current flow so whatever you read in those transistortesters are likely wrong for the situation you're using it in.

                Comment

                • evilkitty
                  Badcaps Veteran
                  • Nov 2017
                  • 299
                  • USA

                  #9
                  Re: What resistors should i use for this circuit

                  Originally posted by eccerr0r
                  ah I see now, thought you would just open the circuit if you want to disable it, seems kind of silly to short it to ground.
                  yea only 8 wires for gpio as rather limiting... not sure if a mux IC would work with a variety of I/O types (also some of my stuff will be on different cores, and a everything on the mux chip would need to be on the same core)

                  my other 7 pins are allocated for use (fan, photocell, DHT22 data, DHT22 power, D18B20, LED, button)
                  • my DHT22s seem to glitch up and need to be power cycled


                  i could use hold times on the button for this... but i have interface preferences, and the MC-38 switch reads 1 when the magnets is near and i may not my keyboard tray fully extended to invert the logic, shorting the base to ground was the only way i could think of to use a closed switch to turn the light strip off, well i guess i could use a PNP transistor, but this seemed simpler
                  Last edited by evilkitty; 04-28-2023, 11:27 AM.

                  Comment

                  Related Topics

                  Collapse

                  • jinu_j
                    LED driver circuit. Burnt Resistors
                    by jinu_j
                    Hi Folks
                    This has to do with a LED light driver rated for Output - DC36-65V 300mA. This is used to drive a 15W LED panel light.

                    Now this does not work so opened up and found 2 resistors burnt to crisp. Sensing a learning moment, i looked around the circuit to figure out that it is built around the OB2538 chip. The circuit to a large extent follows the sample application circuit mentioned in the data sheet. I have traced the actual circuit and the same is also attached for reference.

                    But i have some queries on this circuit
                    1. The resistors that burnt to crisp...
                    08-26-2020, 01:24 AM
                  • TinkerTron
                    Schematic vs. Reality: Where Are the Resistors on My Sharp Clock Radio? Model FY-70CH
                    by TinkerTron
                    Hey everyone,

                    I'm currently working on a mid-70s Sharp Electronic Digital Clock Radio, Model FY-70CH. I found the service manual online, printed it out, and have been studying it for a while. My main reasons for tackling this are: (1) I want to learn electronics and figured I'd start with something I had on hand, and (2) I want to fix its issues. Right now, the radio sounds awful, has about 5V DC at the speaker terminals, and the alarm time setting doesn't work. But I'm not asking how to fix these problems.

                    Instead, here's what's been bugging me so far:
                    The schematic...
                    03-06-2025, 02:03 PM
                  • Astonished
                    Fixing the Charge Circuit of the Batteries of the DC Motor
                    by Astonished
                    Hi friends of electronics

                    What you see in the video and pictures attached is the circuit for charging the batteries of a DC motor.

                    The problem is that this circuit cannot charge the batteries (3 1800mAH NiMH batteries) any more. When the circuit was OK, its green LEDs lit up one at a time to show that the batteries have charged more. But now that the circuit is flawed, LEDs light up as you see in the video and at the same time successive beeps are heard.

                    Please help me fix this circuit.

                    (the datasheet of the IC: https://pdf.datasheet.live/28...
                    01-28-2025, 06:24 AM
                  • rddube
                    Lenovo L490 Ram voltage circuit malfunction
                    by rddube
                    Hello friends,

                    Looking for some guidance here. The RAM voltage circuit on this motherboard keeps burning out PU301 which is a RT8231AGQW. Copy of the board with the burnt chip attached with some voltage measurements and copy of the schematics also included.

                    I think I've checked almost every component in the circuit, but when I change the RT8231, the laptop starts I have 1.2V on the inductor for about 10 seconds and then the RT8231 goes south and no more voltage on the inductor. All other voltages on the laptop are good, this is the only one conking out for a reason I...
                    07-15-2025, 04:41 PM
                  • karatzdi
                    Denon AVR 1908, High pitch noise on Surround back Left channel after long overhaul
                    by karatzdi
                    Hello,

                    I know some might say... just buy another one. Sell it as parts..!

                    So had this AMP for quite some time. Recently I saw light smoke coming out of the AMP. Had my fire extinguisher close by. Just kidding. Turned immediately all devices off from mains.
                    Let things cool a bit, and opened up the amp device. I clearly saw on the main board which hosts the 5X amp (5.1), 3 10 ohms 1W resistors had their leads looking black, while the rest of the remaining 2 x 10 ohms were brownish as being installed from factory.

                    Spent some time downloading the Service...
                    06-11-2024, 08:38 AM
                  • Loading...
                  • No more items.
                  Working...