#help-with-hw-design
1 messages · Page 37 of 1
So the 5V and ground from the DFRobot red and black headers is going to the 5v and ground screw terminals on the servo FeatherWing?
exactly
are you using the USB connector on the DF Robot?
or the LiPo battery in terminals or socket?
but the ctrl pin had the blue GND, right @shrewd jackal?
The DFRobot is specifically set up to isolate the black ground terminal from the board ground. But that's not needed here. You want all the grounds tied together. So jumper the blue ground to a black ground pin.
we tried putting the lipo in the dfrobot jack, but we want to put it in the Huzzah, thru an INA219 (to be able to measure the charge current) . none of these work (turn on and of the 5 V output from the charger) once the PWM is connect via the doublers GND. the 5 V booster wont turn on/off with a blink on pin 12. just on.
did you try this, @shrewd jackal ?
Yes next to the enable pin
are you blinking pin 12 or holding it low?
No I haven't. Can give it a try later.
Blinkning
were blinking it to see if it works. (also, was required to put an extrenal pulldown for it to stay low during deep sleep. we now use an extra power boost from Adafruit, and that works, but we rather not have it)
all that the EN pin does is connect or disconnect the GND_VOUT from system GND. I do not actually see it turning off the DC-DC boost.
i'm confused, do you havea second LiPo connected to the DFRobot board?
how are you charging the Lipo on the ESP32?
No the Lipo is connected to the esp32 which it self is connected to the INA219 and PWM through a trippler. The solar charger is connected through the INA219s measuring pins.
Through the esp32s usb and a solar panel connected to the Dfrobot solar charger.
When you remove the servo wing from the doubler, that is removing a ground connection back to the DFRobot board. That's the only thing I can think of that is changing. I would also check the battery voltages to make sure they're nicely charged up.
I'll experiment with the things you suggested. Thanks for the help!
but otherwise I'm at a loss. I would draw up a schematic block diagram and study it.
just want a quick tech upgrade check, but a pi camera 8mp module v2 is still the best available at that price point in 2025 right ??
cuz the alternative is to buy a 1300$ iphone to take pics...
I think there are some more convenient things in between 🙂 , like a used phone or a regular digital camera
there are plenty of cheap digital cameras starting at $30 (US prices).
yeah but you have to hold them and Im shaky, a servo would hold in place to take pics of documents/bills
I have one of these for closeups: https://www.amazon.com/IPEVO-Definition-Document-Camera-5-880-4-01-00/dp/B079DLTG9F
V4K Ultra High Definition USB Document Camera is your premier presentation tool – its 8MP camera allows you to capture ultra high definition live images up to 3264 x 2448; its high frame rate at high resolution helps deliver stunning silky-smooth live streaming without latency; its fast focusing ...
but do they works ? cuz there are 2$ smart watches too on temu and aliexpress but doubt they work in any sense of someone definition of works
yes, $30 cameras work.
Sure they are not as good as $1200 iPhone, but they work well enough if you have good lighting.
With tariffs that will be a $1500+ iPhone.
I would like to design a buck converter with these requirements:
Vin: 36-48V
Vout: 5V
Iout: 6-7 A
May I ask your recommendations for an IC for this purpose?
-
I would like to design a simple circuit with least amount of components.
-
I would also like to minimize the BOM design, with least amount of pins for the IC that would make the PCB assembly easier for a DIY project.
Well, it's only one manufacturer but TI's got a great section on their site that will do most of the legwork for you.
That's beefy enough to be fiddly, tho.
If you’ve never designed a buck converter, I would highly recommend looking for a module from TDK/Lamda, Murata, or MPS. With such huge step down it is critical to have a well designed control loop.
Most module manufacturers will have a point of load converter for 48V to 5V.
Yeah, for that particular case it's better to get a module. But do try out making your own switching power supplies! It's fun and educational.
What do I need to watch out for when designing switching power supply i.e. for this particular design requirement?
TI has online designer for these kind of applications. How reliable are the designs when used in an actual application?
Can you suggest good references, tutorials, books for designing switching power supplies?
ok, looks like we need to become experts in taxes and customs...
as many have seen, it was announced today that some elctronics such as smartphones are no longer subject to the new tariffs.
The media, of course, is mostly interested in smartphones, but you can find exact list of excluded items in this note from CBP:
https://content.govdelivery.com/bulletins/gd/USDHSCBP-3db9e55?wgt_ref=USDHSCBP_WIDGET_2
among others it lists HTSUS code 8473.30
on the other hand, if I go to JLCPCB and try making an order, it asks me to classify whta I am ordering, and the list includes this:
(I am not sure that classifying all development board as 8473.30 is correct, but that's up to JLCPCB 🙂
so one might think that this allows one to order from JLCPCB tariff free. Of course, we will only know for certain after we try, but it does open a possibility
Doesn’t this list only show up for if you’re doing assembly?
yes.
But what prevetns you from ordering a board with assembly - put on it a 0ohm resistor?
🤷♂️
Not sure how to do that if I’m using fine pitched parts that I hand place. I could put it on the bottom side I guess
I ma not happy to be playing these games. But we have few other options...
PS. Reading these CBP notes requires special skills. I'd much rather be reading a 1000 page SAMD datasheet than this
What footprint should I use for a 3-pin transistor where the pins are bit further apart
Oh they have one in KiCad labeled Hand Solder, excellent
That's much cleaner
I'll put traces up tomorrow and then build it on a breadboard to make sure it works lol
Oh wait I'll need a pulldown on that button
Could possibly re-wire things to use a pull-UP on the button instead and then you can use the internal pull-ups on the nano?
Oh it has internal pull ups?
Most have either pull-ups or pull-downs, yeah, the Nano from what I'm looking online has internal pull-ups available?
Nano / ATmega328p only has Pull-Ups.
Very specific question:
I got a flex PCB with stiffener. I would like to remove the stiffener. Is there an easy way to do that? I tried earlier to just peel it off but it ripped the flex PCB a bit
maybe apply a heatgun to loosen the adhesive? or soak it in acetone?
Its not guaranteed there is an easy way as not all stiffeners are adhered the same way. If epoxy or lamination is used, anything capable of separating the two would likely damage the pcbs as well.
However, for the more common pressure sensitive tapes, many of them can be separated by adding heat or acetone.
im having some trouble with the 5v side of this project will the micro controller is booting its fine and stable but as soon the the controller boots i get a this any idays
What does the output of the switching regulator (which appears to be the input of the 5V linear regulator) look like?
this is the output of the switching regulator before the inductor
after inductor
zomed out on the time scale
I think your output capacitor is too small in value
Smaller value output capacitor is going to lead to a larger ripple voltage out the output.
Nearly a volt of ripple voltage there, easily 2V top of the ripple to the bottom
Your earth traces also feel a bit small for this application
got it ill put those in for the 2ed iteration
Just looking through the datasheet, it looks like they’re recommending at least 220uF for the output capacitor. That is about a 150mV voltage ripple they estimate so 5V should be 4.85V to 5.15V rather than swinging 3.6V to 5.2V
got it i can patch on on to test it
What software do you all commonly use to design PCBs? Something that is suitable for sending off to a manufacturer for small (< 10) batch.
KiCAD
Kicad
realistically, there are very few options. There used to be Eagle, which now became a component of Fusion360 - but it is not free in any sense of the word.
There is EasyEDA, from the same group that owns JLCPCB.
There are pricier professional tools like Altium.
And then there is KiCad - very mature, with a strong community support, and free as beer and as speech.
KiCAD is basically the only game in town since autodesk harvested EagleCAD for their organs.
Unless you want a monthly subscription and/or degrees of vendor lock-in to who you'd have make your PCBs, or you're eyeballs-deep in writing vector files by hand to build your gerbers manually in notepad. XD
I mentioned my recreational PCB habit at a ham radio meet to a guy who I guess does freelance work and he's like "OMG have you heard of KiCAD yet?" and I'm like ... yep, I got on that train early.
I'm one of those screwballs that can (and does) write PDFs from scratch in notepad and learned to write gerber files by hand back in the day so I can (and have!) actually made PCB files entirely that way a few times even. Even I preach KiCAD. XD
They kinda are all the same, they share the same concept/tools more or less, just the gui changes. Altium has an integration with octoparts which is handy. The latter has also a circuitmaker free program. Easyeda is also partially free, they also give you discounts on jlc
Then lately someone has made some edas with llms integrated, but outside of a slick gui, they tend to generate garbage. It would be handy if they were actually smart, or generate like resistance geometry out of traces to save on cost, or search for cheapest stuff or even use foss schemes as libraries to reuse easily
But it's easier said than done
I have an ATmega2560 on a board (Arduino bootloader), after power cycling it, it doesn't come back unless I unplug the USB for a few seconds and plug it back in, and sometimes holding the reset button causes it to lock up rather than reset requiring me to unplug it -- any ideas?
(U201 is a CH340N)
where does VCC come from?
(not an expert) does the reset line need to be held low on power up for some minimum time?
Quick test I guess might be to add a small cap to ensure the reset line goes high only after vcc stabilizes.
If I have a bunch of components connected to a GND thing in KiCad, will they be connected in the PCB editor?
Like this
Yes, generally. Signals of the same name are assumed to be connected on the same net, so the layout editor will expect them to have traces between them.
Awesome, that will let me keep this nice and clean
It's starting to come together
One random suggestion: it's common practice to assign meaningful names to nets even if you don't have to, for instance the lines from D4 and D5. It's kind of self-documenting your schematic for what those signals mean, and in the layout editor the trace will be annotated too, which makes it easier to interpret than NET_35.
And this time I know it works cause I have it sitting on a breadboard next to me :D
Is a net the wire?
Sort of. A net is the abstract "signal" defining what's connected to what. A wire on a schematic belongs to a net, but there can be many different wires associated with the same one, just like with multiple grounds. The same net might have wires on multiple pages of the schematic, for example.
Where would I add the name to the net? Not seeing it in the double click menu
I am very new to KiCad lol
I did find the highlight net tool though 👀
Am I able to connect pins via custom labels instead of having to draw tons of overlapping wires?
Documentation for KiCad, the EDA / CAD suite for Windows, macOS, Linux and more.
Yep, you can do that, but there's a happy medium. Some people just label everything in isolation, and the schematic becomes hard to understand because you lose the spatial arrangement of components for how they fit together. But it can definitely be appropriate to avoid a bunch of long, meandering, criss-crossing lines.
Right now I have this which is a bit hard to follow
If you scroll a little bit further down the doc page I linked, it'll also talk about "buses", where you can combine multiple related signals together into one thick line. 👍
Oh that'd be useful
This is much cleaner IMO
Pretty clear what it's doing since the labels are just named after the nano pins
Also, it is traditional to have all GND pointing down and VCC/3.3v/5v pointing up - not horizontal.
Makes the schematics much easier to follow at a glance
Oddly I always found that tended to make schematics more cluttered to my eye with randomly angled components or 'forced' u-turn wires compared to all components in a straight-up orientation.
What’s the point of Q1-Q3?
To drive the GND pins on the bargraph
What's gonna be hard is laying out this PCB. Forget tracing, I can't even figure out how I should organize it
How? They will never do anything with the base tied to ground.
Oh, these are supposed to be rotated lol
You're right
That's better
What I do know is I want the actuator out pins on the left, and the RGB LED and IR stuff on the right
Bargraph somewhere in the middle-left
Everything else can fit whereever
That's a tomorrow problem, it is past midnight lol
Thanks yall
Nope. That doesn’t work either.
Wait really?
GND is on the collector, no?
Oh do I have collector and emitter backwards
In order to conduct, an NPN needs ~0.7 volts to drop from Base to Emitter.
Isn't it PNP where the base needs to be lower than the emitter?
~ means approximately
Cause I have the 2N2222s on this breadboard with GND on the left pin with the flat part facing me, and output on the right pin, and those work
But maybe I have this backwards on the schematic
Oh I do have it backwards
GND needs to be on the side with the arrow
That should be right
Thanks for catching that
Oh right, cause it's going to ground, not ground being pushed to it
If you were using PNPs then that could be correct. You have NPNs in your schematic (NPN arrow points out toward away from the base, PNP arrow points in towards the base)
Oh yea I did have it backwards
Is there a way to select an element in PCB view and only see the traces it uses? It does it if I start to move it but I have to move it first
Oh, and the datasheet for this L293D says the GND should also be used as a heatsink.
How should I account for this?
Alright, is this a disaster?
Cause it feels like it, but I'm not sure how else I should do it
The IR, RGB LED, and Invert Btn need to be roughly where they are, as does the 7x2 header at the top, but everything else is pretty much fair game
Nope, doesn't look that bad. The traces on U1 strike me as suspicious, though: are they really supposed to be connected to each other like that?
Indeed. It's an L293D that connects the channels together to drive 1.2A max instead of 600mA
Gotcha. If you're carrying an amp on some of those traces, they should probably be thicker.
Hopefully it's like only 500mA but I have it just as a contingency
How thick should I make them?
And do I need anything special for heat sinking?
It's a calculation based on how much temperature rise you're willing to tolerate in continuous operation: https://www.advancedpcb.com/en-us/tools/trace-width-calculator/
Use AdvancedPCB's trace width calculator to find the ideal trace width for your PCB designs, ensuring optimal performance and reliability in your circuit boards.
Since you don't have a ground plane, you might not have a lot of options there. They do make little metal heat sinks that you can stick on top of a chip, too, but I don't know off the top of my head whether that sort of thing is warranted or complete overkill for your application. You might just end up building the first board and then give it the "lick my finger and see if the chip burns me" test. 😜
That little rectangle formed by the ground pins should be a filled zone connected to as much ground pour as you can fit on the other side as you can.
There is some room on the back for rearranging the blue traces to fit a larger ground fill for heat dissipation.
Hmmmm, I don't really know what temperature to shoot for
Should I go off the datasheet?
So a filled zone like this?
Or should I draw it right next to all the traces without touching?
That's almost certainly too big lol
Hi All! I'm a little confused as to how the Adafruit Feather nRF52840 Express does dynamic VIN selection. I see in the schematic it states:
JST PH LIPO INPUT - Dynamic VIN selection: VBUS (USB) will override VBAT (LIPO) via D5 when both are present.
https://learn.adafruit.com/assets/68545
However, I can't find DIODE 5 in the schematic. Can someone direct me? Does D5 not mean "diode 5"?
Likely a copy paste error. The diode D1 and mosfet Q3 work to do voltage selection. When VUSB is present, it acts as a diode blocking VUSB from back powering the battery effectively selecting VUSB to power the LDO
Awesome! I was assuming it was the mosfet... but the text threw me.
THANK YOU!
Feel free to submit feedback on the learn guide so they can update that 🙂
There is a voltage divider on the D5 pin so you can measure the battery voltage. This does not mean "Diode 5"
I've changed the board to this. Do vias impose any extra cost? Cause I added them to a few places to shorten the track a bit
I don't know if there's any major improvements I can make by switching some routes around and what not
The wording is talking about voltage selection so that doesn’t necessarily track with battery voltage monitoring? I think the wording could be clearer if that’s the intention.
Also the voltage divider goes to A5 on VDIV and isn’t connected to D5 it appears
OK, I think this was copy-pasted from a previous board like the SAMD21 Feather, where the voltage divider was on D5. On the nRF52840 Feather, there are enough spare pins that the voltage divider is on a pin that is NOT broken out.
Yes, I was trying to make sure that I showed that I put some effort into finding a solution. I know that some people get annoyed when it appears that no effort was taken to solve their own issues.
I DO see that there is a D5 pin on the board itself. I was unaware that this was not just a GPIO pin, but can be used to monitor the VDIV from the battery. I need to look at the schematic a little more carefully to figure this part out. @unique patio
HOWEVER, this is separate from the VIN selection, which @distant raven pointed out is accomplished by Diode 1 (component D1) and the mosfet (Q3).
so what I said about D5 was wrong. I will add a note in the Downloads page (but not the schematic itself) about this. It's
We can't see that link, I think you linked the internal editor view?
oops, fixed
Generally, no extra cost: vias are typically free up to some pretty high number, just included in the per-area board fabrication charges.
Oh cool and it shouldn't affect performance of the board at all either?
I mean I know traces are basically instant but wasn't sure if length actually changed anything
Typically only for very high speed (GHz) signals where sometimes you'll have to length-match pairs of traces, or special cases like placing decoupling capacitors close to the pins on a chip to minimize inductance. Most regular signal and power traces won't care.
Awesome
So then you were suggesting thicker traces for the L293D IC: where exactly do these thicker traces need to be?
I did make a zone for GND
I think I did this right
Basically the thickness of the trace should be proportional to the current it has to carry, so wherever you have high amps, you'd want beefy wires.
Tools will often allow you to define net classes in the schematic so that the DRC will check for minimum trace widths, but that's probably overkill here versus just manually thickening the stuff on your main motor-driving paths.
I'm hoping no more than 600mA, though I have the chip for 1.2A just to be safe
Yup, just remember that these traces aren't really "wires", but micron-thin strips of copper foil, so they don't have a lot of metal to begin with. It's probably not a problem for you as is, just something to potentially improve.
So just make the output wires of this chip and the 12V going in thicker?
And maybe some of the ground traces if it's carrying a return current.
hey, i have a board i designed a while back that has a 3v3 LDO (LM3674MFX-ADJ/NOPB), but it has failed for some reason. I was wondering if anyone know why that might have happened? Its a basic design. and the board has relatively low hours on it! im just confused as to what might have caused that to happen. Any input or help is appreciated. Thanks
The circuit attached to FB on the chip seems weird, as it has no connection to the 3.3V output to provide feedback. I would have expected something like the top part of the divider to be connected to the output, and the middle part to be connected to the FB pin.
BTW, that's not an LDO, but a step-down converter.
oops sorry, my bad
Yeah, the example design in the data sheet has a different FB connection topology:
LOl i dont know how i missed that. Thanks
Actuall, i found the actual schematics. I have it right. I had to dig around for the actual files. the above one was from another board that i reused the design, but never made
Great! That actually makes more sense, because the previous design probably would have produced a wrong output voltage and you would have noticed it. But unfortunately it means the failure remains a bit of a mystery. Is this a device that might be subject to static-electricity shocks or something like that because people are touching it?
no, its in a case
Any idea whether it might be getting overheated? Did you do the thermal power-dissipation math or otherwise try the wet-finger test after it was running for a while?
i had it hooked up to a PS and when i connected the jumper from 5V to the 3V3, it drew like 3.2 ish W and i had the 3V3 out to the rest of the board disconnected. Didnt have that happen initially when i made the board, it was a few years ago though!
How much power should the 3.3V downstream circuit normally use?
about 300mA
That should be well within specs. Looks like it's >90% efficient, so it's probably dissipating only about 100mW or so, and all of the ambient-temp temperature ratings are above that.
im thinking of replacing the IC. Have a few more. Do you think this will happen again in the future with this board? I have one more board that i am using. But that one seems fine for now
I just couldn't say one way or another, I'm afraid, whether it's just a random fluke or some kind of subtle design flaw.
I also dont see any physical damage to the board around that area. Like burn mark etc.
what does the PCB look like?
has anyone here used pyupdi with a ch340c chip? Not an sos question per-se but I was hoping to bounce some questions about impedence to folks with pcb debugging experience
I originally had some issues with trying to communicate with an attiny1614 when using a 10k pullup between the usb-rx line and vcc
but when I changed it to a 33k everything just worked
I wanted to glean some post-mortem feedback on how to debug/avoid this issue and perhaps improve my pcb design
happy to share schematics and details, nothing secretive at all
Hello, I'm planning on powering/interfacing with https://www.adafruit.com/product/1480 and https://www.adafruit.com/product/4632 + some other sensors using https://www.adafruit.com/product/5900. I'm afraid that I'm going to max out the onboard 3.3v regulator and do not want to use the stemma qt cable (everything will be on a pcb, so I want to keep it clean) and am looking for ways to get more power out of the feather v2. Do you guys think I could just hook up a linear regulator to Vbus (Vusb) to step it down to 3.3v and use that as an additional 3.3v rail? I am planning on everything being 3.3v power and logic.
You could do that, as long as grounds are connected. This can also provide more control over power distribution if you use a regulator with an enable pin.
Just ensure that the 5v supply you use is capable of delivering enough current to the rest of your system.
The other sensors barely require any power (https://www.adafruit.com/product/3660, https://www.adafruit.com/product/3660, https://www.adafruit.com/product/6049) and I'm planning on just powering everything through usb-c (using my computers usb port). Do you think thatll work?
It can be done with very careful management of measurement timing. With esp32 WiFi spikes of 250mA and the PMSA peaking at 100mA, the system will be fine if you keep those two peaks from overlapping.
Hm, i looked up the usb-c spec and wikipedia says 3 amps max current? Is there something im missing?
Thanks so much for helping btw, really appreciate it
USB-C requires negotiation to request current above a certain level from USB-PD compliant supplies. The PC USB ports can certainly deliver more current, but in this specific scenario I don’t know what the feather is actually negotiating for. Default for usb 2.0 is 500mA, so I know that would be the worst case, but I can’t say for sure you would get more.
PC usb ports generally support 3.0+, but most microcontrollers use usb1.1 or 2.0, the esp32 included.
uhg, I assume the esp32 pico mini 02 would be doing the negotiation?
Whatever is the main chip controlling the USB port that's plugged into the PC.
Yeah this is tricky, as the whole point would be to deliver more power than the 500mA that the 3.3v internal regulator can do and not have external battery/power supply
Ok I double checked, as long as the pulldown resistors exist, the host will deliver 5v at whatever its max current spec @ 5v is. With usb c ports, you should be fine.
I won’t say 100%, but the odds certainly favor you getting more than 500mA from that port.
Can you elaborate on this or provide a source? Im curious myself
What is the purpose of Rp, Rd, and Ra types of termination resistors in the USB Type-C connector? - A downstream facing port (DFP), such as a host computer, exposes pull-up terminations, Rp, on its CC pins (CC1 and CC2) - An upstream facing port (UFP), such as a peripheral, exposes pull-down term...
Rd is a fixed resistor in the context of 5v.
Nice. One last question (thanks again), since you've looked at my parts, do you think my power concern is valid? I just want to make sure im not doing this for no reason
Valid? Certainly. It’s not serious enough to really prevent you from building this, but power consumption is a very important factor to consider when it comes to systems design.
Hi, I am having trouble understanding what I should use to charge my lipo 3.7v batteries:
https://thepihut.com/products/1200mah-3-7v-lipo-battery
I want to have a charging option which allows me to charge the battery via USB whilst still allowing the battery to be connected/powering an arduino nano or raspbery pi pico whilst not charging.
I saw these but it wasn't clear how to connect it up or if they allow ouptut as well as charging:
https://www.amazon.co.uk/dp/B0CPBJ8G62/
I assume I need to connect up the battery +/- to B+/B- on the board and the OUT+/OUT- should go to the power/GND pins on the arduino/pico? What would happen if I plugged in the charging cable whilst the OUT was conneced to the arduino nano? Some of the amazon listings say to not charge at the same time as using the output, what would happen if I did this and are there variants which could support pass through in the scenario where the usb cable is connected?
LiPo (Lithium Polymer) batteries are a great way to power your portable projects (ideal for the Adafruit Feather!). Compared to other battery chemistries they're more compact, lighter and offer a consistent voltage output (rather than constantly dropping like other types!). They also offer higher rates of discharge whi
Also is the output voltage 5V on these as well? If not is there a similar board which can boost to regulated 5V?
The charge should disconnect the load OUT terminal on the positive and negative cannot be wrong, please according to specifications, otherwise it will damage directly.
Nope, no red flags with that board.... /s
Proper LiPo chargers monitor how the battery responds while charging. So connecting a load to the Vbat of a charge controller will cause problems. (Some will just shut down.)
Next LiPo charges up to 4.2 volts. So you won't get 5V out of a charge controller anyway.
If you look at how Adafruit does their Feather boards, the microcontroller is powered by 3.3 volts. The battery is (essentially) diode-OR'd with the USB 5V. Then a 3.3 volt regulator only gets powered by USB or the Battery, but never both.
tldr; it would be much simplier if you can run your microcontroller board off of 3.3 volts
Would the arduino nano be fine with 4.2-3.2V input? I was originally looking to power the arduino nano via the 5VIN pin, the other input states 7V-12V. I am also looking to power some neopixels which seem to want 5V as well which is why I thought to look into something which could boost the lipo output to 5V.
I found these as well which seem to regulate the output to 5V:
https://www.amazon.co.uk/TP4056-Lithium-Battery-Charger-Function-Blue/dp/B0DFKNT4RG/
This compact TP4056 5V 1A 18650 Lithium Battery Charger Module is a versatile and efficient charging solution. It features a Type-C USB charging port and a dedicated charging board with protection circuitry. The module can charge single 18650 lithium batteries at a rate of 1A, ensuring safe and r...
I suggest you look at the Adafruit Feather line of boards, which can be powered by 5V or a LiPo battery, and have built-in charging circuitry. They can charge while in use.
Alternatively, consider using a USB power pack. Power the board and the neopixels with the 5V from the pack
Makes sense, I think will look into the feather since the compartment I will be fitting all this into probably will be too small to fit a usb power pack into. thanks!
Driving 5v neopixels with 3.3V logic signals can sometimes work without a level shifter. Or if you have only a small number of neopixels to drive, you could drive them with 3.3V if you don't exceed the 3.3v current capacity of the feather. They will not be as bright but they are quite bright as is
are the neopixels external to the box?
You think this is good?
I made them 0.2mm => 0.4mm
I assume KiCad automatically would warn me of clipping due to increasing width
Although this is a lot
It should, yeah, assuming you have told it what the fabrication specs are for the board house you're planning to use.
There's no universal spec for how small of a trace you can make on a board, or how close things can be. It depends on the machines used to make the board and how much you're willing to pay someone to use better machines. So normally you'd have a rough idea of where you want to get the board made, and design to the specs they advertise for the price point you like.
Ah
JLCPCB has a default of 1oz outer copper weight
KiCad says only 0.6mm width?
Oh wait that's bigger than I have right now, I was thinking mils
that's a big boi
You could flip it around and see what the temperature rise would be for the width you are using. It may be acceptable.
140 degrees celsius???
That seems too high for just a 0.4 to 0.6 mm difference.
That was with 0.2mm
Good news is the other stuff can say the same, cause with 200mA (what I'd expect for these bar graphs) only needs 0.08mm
But 1.2A (hopefully it doesn't go that high) with a temp rise of 25C is 0.6mm
That's 77 degrees!
Also this ground plane is huggeeeee
But it should be right
Oh wait are these Xs wrong
Do I even need the traces? I just wanna connect those to the ground plane
Wait aren't these touching
If you mean the blue diagonal traces, those are "thermal vias", connecting to the ground plane only with spokes instead of solidly, so that you can solder the pins without heating up the whole plane. You can turn those off if you won't be hand-soldering stuff.
Yeah, that should really be flagged by the DRC unless it happens to be the same signal.
Oh I need to run the DRC probably
oh no
What are these arrows? Are these the errors?
yes, these markers show where the errors and warnings are
Might need to toggle some layers to see where the issue is, it might be a blue-layer exists on the Q1-B point as well, etc.
How can I get the trace mode to account for trace width?
The "autocomplete" of trace mode doesn't avoid clipping these traces
It's not that smart, think of it more as a 'get all the traces down' tool then you have to dive in and manually adjust stuff usually.
Dang
And can I not hook this trace directly into the ground plane?
Curiously, I think kicad did account for the trace width cause I replaced the traces and they moved just slightly and worked fine
All my errors left are due to this part
I changed it to the staggered pin footprint so soldering isn't awful and that seemed to fix it
Did something happen to JLCPCB? They no longer the cheaper express shipping. Minimum is $25.
Alright, gonna order these
Hopefully these work :)
small-packet stuff is all on hold due to tariff stuff
Dang
I ordered my boards 3 days ago, they are already in the mail.
But yes, shipping cost me about $35
TLDR: JLCPCB will pre-collect 175% tariffs on orders to individual customers
doesn't look like I will be ordering anything from them any time soon
But they say they’ll refund the actual difference.
if any
If there isn’t any, then it doesn’t matter that you used them.
The problem is that designing random fun PCB projects brings me joy?
I guess I'm glad that "all" I have to pay is faster shipping and the tariffs because I was half expecting to not be motivated to do any PCB designing at all because of the de minimis.
Have you checked www.pcbway.com who I have ordered from several times for work stuff but not since this tariff nonsense. Typically "normal" shipping make the whole order $26-ish and takes about a week total to the USA. But they also offered a cheaper option like $8 or some such for the slow package which might take a couple/few weeks.
I ended up finding a site to compare prices and went with elecrow or something like that
Cost about $8
including shipping???
I mean for most small pcbs there are other options that aren’t terrible. Haven’t looked at oshpark in a bit but DKred is a solid option.
Yah, I worry that everybody who is presently "cheap" is going to end up with people getting unplanned tariff bills.
most of my orders from JLCPCB were pcb+assembly, and oshpark doesn't do assembly 😦
Ah, that’s a fair point. I do have solder paste from work, but I should get myself a hot plate or modded toaster oven at some point…
Yes
I do the assembly myself cause they're very basic boards and all the parts are through-hole
Charges $25.60, but free shipping with 10 day lead time
Oshpark wants $21.30 and also offers free shipping
I'll keep that in mind if the overseas china option goes to crap
So I've been working on a soldering oven project, primarily focusing on the control board. I've gone through a few revisions. It's using 2K type thermocouper for redundancy that run on SPI. It's using a high side current sensor that runs off of i2c as well as a display that runs off of i2c. I was wondering if there's anything that anyone thinks that I should change about it
Wow that's a huge ground plane
some of the trace spacings seem to me uncomfortably small, like here
did you run DRC check?
Does your min track spacing match the fabrication capabilities of the vendor you had in mind?
I have never checked. This will be my my first board I expect I'll probably have to remake it with those parameters in mind and learn how to set up the software properly
it is done in KiCad, right?
do you mind sharing the actual KiCad files?
I can wen I get home
I already know a lot of changes to make. So it will be a full redazine but know mistakes I made in this one will help me avoid similar ones on the next rev
I am having issues with neopixels... the first pixel in my strip is intermittendly glitching out or turning off, it usually works but every now and then it will glitch then come back with the correct color. I have tried the following so far:
- level shift for 5V using 74AHCT125 (It's connected to the GPIO18 pin on a raspberry pi)
- Adding a 330 resistor before the signal input of the first pixel
- 1000uf 16V capacitor across the power input (It's being powered by 5V via a USB power bank)
The distances are tiny, it's running 10cm from the power to level shifter and 10cm to the pixels from there. I have checked all connections including common grounds and they look fine. The strange thing is sometimes it will work fine for a while then glitch out for a bit then be fine again. The strip has 8 pixels and the others work fine, only the first one exhibits problems. Would adding a sacrificial pixel help fix the problem? Could the issue be the pixel itself? I would imagine if the other pixels are fine it wouldn't be this.
Note that if I terminate the program sending signals to the pixels it will hold the correct color. The glitching only occurs when sending a signal down to the pixels.
Mmm... I just tried it again without the logic shifter chip and it works fine... do I run any risks by not using the logic shifter?
No damage is possible by not using a logic level shifter so you are fine there. Is the RPi 3.3V outputs or 5V outputs? Normally you use the level shifter to shift 3.3V up to 5V. And for your future knowledge, the sacrificial pixel is a poor man's level shifter so if you have a level shifter you don't also need a sacrificial pixel.
EDIT: just looked it up cause I couldn't remember. Pi outputs are 3.3V
I'm starting to think it might be something wrong with the level shifter itself. The GPIO pins run at 3.3v so theoretically I would need to shift to 5V for reliable behaviour. Removing the shifter and running the neopixels directly to the GPIO pin seems to work more reliably, I haven't seen the glitching behaviour since doing this.
Could be the level shifter. Where did you buy it? Thru hole 74AHCT125 chips are becoming extinct. Digikey only sell one model of Texas Instruments and everything else is Surface mount. And NO 74HCT125 (no A) through hole ICs. But with the popularity of WLED and the like, I wonder if a lot of the ICs sold elsewhere may be something other than guiniune 74AAHCT/HCT125 ICs, perhaps relabeling other '125 ICs from different families which will have the same pinout but different speeds and different logic level tolerances.
What kind of level shifter are you using, and how are you wiring it?
Yes good point. If only using one gate then standard practice is to make sure any unused inputs are not left floating/unconnected. And on a related note, they really want to have a decoupling cap (roughly 0.1 to 0.01 uF) across pins 14 & 7.
I was more thinking along the lines of making sure the grounds are connected well and none of the connections are simply flaky….
That too. 😃
Adafruit stocks them for individual sale still. https://www.adafruit.com/product/1787
Hey yall! Hope yall having a great day 😄
I'm slowly carring over a project from arduino(5v sys) to ESP32(3.3v sys). For Arduino I used a DAC(Digital to Analog module[12 bit]{MCP4725}).
While doing research I saw that ESP32 also supports DAC output 8bit(enough for me) .
Thing is Arduino is 5v so my analog output was 5v, which was perfect, but with esp32 its 3.3v tops. Any suggestions?
Should I...
a) Go back to DAC and try to use a txs0108e for the I2C comunication ( -# I heared that if I power the MCP4725 with 5v and try to control it with esp32 i2c pins, itll fry the pins, is that true?)
b) Stick with esp32 8bit output and somehow higher the output to 5v? ( if this how and with which components)
c) diffrent Idea?
Go with option A), use an I2C level shifter between the ESP32 and 5V-powered MCP4725
If I use the txs0108e level shifter Do i need to use any rezistors between the esp32 and level shifter?
or just any more resistors in general
the TXS has built-in weak pull-ups (and edge accelerators), so you probably don't need external pull-ups. If designing a custom PCB, I would add pads for them if you need stronger pull-up.
Arright this should work then schematically
should i add pull up resistors on the sda and scl lines from the ds3231? its a bare ds3231 chip
Yes, if that is the only I2C device you should be able to get away with 10k resistors
what if i also have a oled with build in resistors on those pins
If is on the same bus, then you only need one set of pull-ups. But as drawn in your schematic, the OLED and DS3231 are on different buses.
The RP2040's internal pull-ups are probably strong enough for a RTC (100 kHz data rate). However, if making a PCB, I'd still put empty footprints in the design just in case.
here is the updated design, i also forgot to enable the regulator lol
What battery are you using that requires a linear regulator just to back up the RTC?
I would connect the battery directly to the RTC and put the switch on the input of the of the regulator (or the enable)
I'm guessing the answer is no, but…I have a power supply that can (supposedly) output 3x3.1A @ 5V via three separate USB ports. Is there a way to combine these to get one 5V 9.3A supply (or at least more than 3.1A)? My guess is simply wiring the lines together would cause problems, but maybe adding in diodes would let it work?
Thanks to the RPi5 requiring that absurd 5V5A configuration there's dedicated USB-PD adapters that can convert normal USB-PD to 5V>3A, mostly for 5V5A but that's a safer and less costly bet than trying to merge multiple USB fast charge outlets.
Pichondria designed the one most commonly pointed at which also has some nice battery-input options in case that's needed: https://pichondria.com/usb-pd-2-0-3-0-to-5v-5a-converter-for-raspberrypi-5/
The outputs are not isolated, so you should not put them in parallel (or series.)
If you need 5V at over 9A then you need to buy a dedicated 5V, 9+A supply. Perhaps this one... https://www.digikey.com/en/products/detail/mean-well-usa-inc/IRM-60-5ST/7704697 which is a lot more compact than a lot of those metal frame ones.
Thanks for taking a look! Definitely a lot more compact, although I'm hoping to fit it into the base of an existing lamp, which gives me a maximum thickness of ~27mm in one dimension. I think I'm just gonna have to have and find a place to tuck one of these outside of it 😦
I was also thinking about trying to use one of these with a 20V USB-PD trigger, but I can't seem to find one in that shape that takes in 20V https://www.amazon.com/dp/B09SD7P92Z
hmmm not sure if i'm doing this right and how to effectively route the resistors and other components to each other thru multiple layers
How many layers are you planning for the board? And are you following the design constraints of whoever you're using to manufacture it? I suspect it's going to be very expensive if not impossible to get everything routed with your current layout and spacing.
I’d probably start by distributing components spread around the esp ic. From there, it may be a bit easier to figure out routing of components.
Yeah cramming that ESP in the corner like that seems like an odd choice?
That’s probably just the default layout after the parts are first imported from the schematic.
wanted to keep it as compact as I could but I guess I'll refer to the aforementioned design guidelines, forgot about those. thanks!
can someone overlook this for any mistakes before i send it off for fabrication?
Compact design can be tricky, and with that volume of resistors, fitting everything in that space will be difficult unless you populate both sides of the board. It’s very doable, but if you’re just starting off I’d start without space constraints and nudge everything closer to each other after you have a general arrangement of your components.
Not necessarily a mistake, but it’s always a good idea to leave a footprint for resistors on your i2c bus, just in case you need additional pullups.
The OLED has some
Also, don’t be afraid to add fun silkscreens or ground fills if you have extra space, they typically don’t cost anything extra.
One component with an unknown pull-up some wire distance away isn’t guaranteed to work once you start trying to drive things faster. If you’ve already tested it and have no plans for expansion, sure, but an empty unpopulated footprint costs nothing and can save a lot of headache later.
Assuming you’re able to solder them on yourself, anyways.
Yea i can
What pullups should I use? The other chip is a rtc that I want to be really precise
I'm guessing either you didn't run DRC or you ignored the "Silkscreen cut off" warnings ...
I did
It's nothing commercial, just a project of mine, and the PCB will not be visible
I didn't bring that up for either of those reasons.
What are you running where you need over 9A? Is this an WLED or or LED type project with LED strips or panels?
LED strips, yeah
I'm thinking about trying to cut the power to be able to do it in segments, but is the shared ground going to be a problem?
OK so not sure if it helps you. First off have you tried on the bench to see how bright it is and if you need full brightness? And second, as you just mentioned as I was typing this, you can do segments with a shared ground and then if possible to fit smaller supplies in the lamp base, you can split the power between the strips. For example a pair of 3-5A power supplies might fit where a single 8-10A supply will not fit.
Yes, bench is where I got the number from. I guess need is a strong word, but I would like to be able to use full brightness
https://www.digikey.com/en/products/detail/mean-well-usa-inc/EPS-65S-5/7703215 ??? 24mm height and 10A!!! 👍 And not a bad price.
Nice find! I guess it's time for me to put together a digikey order
And don't forget DigiKey carries most Adafruit products as well if you need some cart fillers! 😃
Yeah there are a number of things that I was thinking "I should get that when I place another order"…if only I was organized enough to have written those down 🫣
I always add them to my carts on Digikey as I look at stuff. Even without an account your carts usually stays there from visit to visit. Then when I am going to order stuff I have to make sure to remember to pull out the stuff I was only casually interested in and either changed my mind on or maybe want to keep thinking about it. I have a nice little Seeed RP2040 Xiao board that I accidentally ordered. Fortunately it was less than $5 so no biggie. But I am always filling my cart with "thoughts and ideas" to sort through later when I am ready to pull the trigger.
Help please 🙂
I'm using an ESP32 board to PWM control a small brushed DC motor and things work - As long as the ESP32 board is also plugged into the USB to my computer.
When I disconnect the cable, it seems to reset right after starting the PWM cycle.
Below is the schematic, but note that I added a 1000 uF to 5V and a 100 uF to 3V3 plus a 100 nF between the GND and 3V3 out pin on the ESP32 board. That seemed to help but not completely solve the issue.
What could I do more?
And of course, it also works when the motor is not connected, USB cable or not.
What is the battery?
20V Li Ion power tool battery.
And what 5V regulator are you using?
This seems like an important spec not to violate:
~~You're driving the motor with 5V? ~~
What do all of the regulated voltages measure when powered by the battery.
And is the battery REALLY 20V? Because that datasheet says max input voltage is 18V.
Oh, you connected VCC to the battery?
A slight oversight 😳
It does make 5.0V as measured with a multimeter, although I haven't put a scope on for when the motor starts running.
Perhaps this can be salvaged a bit by severing the input trace and jumping input to 15V reg output.
Not really sure what this means. The regulator mostly just powers the ESP32 board, I don't suppose that would be a high capacitive load.
but note that I added a 1000 uF to 5V
1000 uF > 220 uF
Haha, fair enough, that should be an easy fix.
I would monitor the regulator's Input and Output voltage on a scope. You need to see if its input is sagging enough to drop the output voltage
I will try it and fix the capacitor. Do you think this is the root cause of my problems?
it's possible. The reason DC-DC modules spec a max output capactiance is because too much cap trips their short-circuit protection when powering up.
Okay, I'll get to work on that. However, just as a note, if I plug the board and motor in but don't trigger the motor to run, the board seems to power up fine, red led on instantly and stays on.
Yeah, it's probably not too much capacitance, but you should still be following the datasheet's spec.
It's most likely the motor is either sagging the battery voltage too low and/or some other transient
Can't argue with that. Fixing problems starts with getting all known parameters within specs.
Are you programming in Arduino? Seems like 9 out of 10 times people report a board running great on USB and then not running on battery is because their code has a little while loop something to effect of while NOT serial which is basically saying, wait until the serial port connects before going on to the rest of the program. Guess what a battery connection does NOT have?
You’re asking a good question, but: they said the reset occurs AFTER removing the USB cable and before activating the motor.
Which really sounds like a power issue.
Yep, I agree, but the serial port connection is something that only takes a moment to confirm so thought I would throw it out there for the quick confirmation that it isn't the problem.
Yeah, definitely worth a double-check
Also sometimes people's recalled description of the order of events doesn't always match what they actually did. 🤷♂️ e.g. they say "code is running and then I unplugg the USB cable and after the motor starts the code stops" where as actual order events is "worked on USB so then I tried it on battery only and it didn't work after I reset it".
valid point
At my co-op job while in college, we had a sort of joke about anytime a problem came up on the floor with our instruments we made. Assembler would come back to our lab and the conversation went something like...
Assembler: Yeah, I plugged in the machine, turned on the power switch, and BOOM! it blew up.
Me: Blew up?
Assembler: Yeah.
Me: What do you mean ‘blew up’?
Assembler: well I plugged it in and there was a flash and then nothing.
Me: OK so a flash from inside? Like with the motor?
Assembler: Well no, the front panel display came on for an instant then turned off.
Me: Were the fuses in the power entry module blown?
Assembler: I don’t know.
Me: can you check?
[8 minutes later comes back]
Assembler: yep, they were blown but I also noticed the PEM was wired wrong. I fixed than and now it is fine.
Me: [thinking “Boom! blew up?”]
That's a great tip, however, when I plug the battery only and don't activate the motor, the board doesnt reset, which I suppose it would if this was the problem?
That means it's almost assuredly a voltage sag issue when the motor engages, IMHO.
So my custom PCBs came in...
I triple checked that my circuit on the breadboard, which I know works, matches the schematic on KiCad
The buttons and the RGB LED work fine, still have to test the actuator, but the bargraph is weird
The LEDs are super dim with varying brightnesses, and often the wrong LEDs are turned on
How do I even go about debugging this and narrowing the issue down
OH WAIT I'm stupid
The bargraph was upside down LOL
But the LEDs are still super dim. Any ideas on that? They weren't on the breadboard
I also agree it was a good point, but checked my code and there's no loop to keep the code locked indefinitely. Thanks for helping out 🙂
Brightness is directly proportional to current, and this is determined by the voltage and resistance of the LED circuit. If you have a multimeter handy, I’d check these two things for any differences.
They're all 150 ohm resistors (I did actually check individually before I soldered the rest in) driven directly on the output of the arduino
Let me check the voltage
It's 4.7V, as expected
And it was powered via USB before so it's weird that it's changing now. There's only about 2 ohms of resistance on the trace as well
Re: Powertool powered PWM motor controller, problem seems solved, thanks to @latent jungle for actually reading the datasheet for the Recom switcher.
After some thought during the day here, I decided on focusing on that particular issue, because it had a lot going against it.
I happened to find another, more tolerant, switcher in my drawer, a Murata OKI-78SR which tolerates up to 36V in and a more capacitive load and managed butcher the board enough that it would fit and presto.
Now the motor runs fine - At least until the main mosfet cooks off.
Thanks for your help, everyone.
Check that, only the first 8 LEDs are dim, the last 4 are full brightness
And coincidentally, one of the transistors is backwards too
But they're all wired in the same configuration...
Could backwards transistors cause them to be dimmer?
Check that, the LEDs with the correct brightness are controlled by Q1. They're all wired in the same way actually. Just a data pin flipping them on or off
I can't tell what makes Q1 unique
Voltage out of Q1/Q2/Q3 all the same, or which one(s) are different?
Also into Q1/Q2/Q3, etc, at this point start peeling the onion and see how far back the glitch goes.
It's hard for me to check cause it basically goes PWM. I guess I can edit the firmware to just drive one high at a time and measure that. Will do tomorrow.
I am looking for a sinewave generator 1kHz-1MHz minimum, maybe VCOs or maybe other kinds. ideally I would like it to be -15 to 15V ish or -12 to 12 but I can put opamps for that. Purpose is to make a rough impedence measurement device. (will feed the original sine back into an op amp in differential mode with my probe to get an attenuation)
Sounds like a great opportunity for an FPGA and a parallel DAC. Depending on how smooth you want the analog reference, 8 bits of Digital input might be enough. Or you can build a more resilient device and go for 12 bit DAC.
It could be fairly pricy though as the more bit depth tends to require more die space
Or go the classic R-2R ladder DAC with an FPGA
Use a pre-amp for smoothing and feed that into your circuit for boosting the voltage range
Alright check that, it's my firmware... somehow.
I manually drove Q3 high and turned all red LEDs on and it's full brightness
Q2 also works fine
And Q1 and Q2 and Q3 all one also shows full brightness
But the firmware worked fine on the breadboard...
And now it's full brightness??? HUH
Well I won't complain LOL
I changed nothing
smoothing from 1kHZ to 1MHz is a bit tricky
Might've been a typo in the firmware before and changing things back and forth fixed the typo by accident. I've done that PLENTY of times. XD
Guess I should be posting here
About as far as I can take it. Acrylic panel is now slid into extrusions snugly. Panels spaced out with steel rods across the back
If you use the magnet feet from Adafruit you will have to space it out an extra half inch or so. I found the perfect size magnets to shove into the brackets of the panels, pressure fit
But either way works. I was just running low on hardware so my mind was scrambling
The only thing left to do is put those little end caps on the extrusion ends. I got to get some of those
Also, with the USB sound card, you can just run it into anything with an RCA or 3.5 mm jack. I originally got this for a turntable serato setup but it came in handy for this project
I noticed the LED acrylic is out of stock on adafruit. All my suggestions are just to help everyone, ada included....my pics are using the 35% light transmission acrylic (correcting myself).
I ordered a 56% panel at 268x268mm, 3mm thick to test. I think it will pop better
256mm plus 12mm to fit in extrusion slot
The metal is the thing that will kill your wallet on this build but it's highly pro looking. I suppose steel backing isnt necessary since it's purpose was to add magnetization, and the acrylic panel now holds everything in
I want to provide a fairly wide range of DC voltage ~3.3V - 24V to an optocoupler. I can probably get away with a ~800-900 Ohm resistor which is barely enough to trigger at 3.3V but still under maximum forward current at 24V, but I was thinking a more robust solution would be a JFET/resistor current limiter. Anyone have any experience with that particular type of circuit? I'm shooting for ~5mA.
something like this:
220 Ohm resistor is just a placeholder until I calculate the required value
2 resistor + zener "clamp" is a lower complexity wider range option (and what we use in safety circuits).
I was thinking zener but I never circled back to say anything 😂 glad to know someone else with some applicable knowledge could chime in and also confirm my engineering degree was worth it half a decade later lol…
yeah, I had circled around the resistor+zener idea. Presumably the zener is between the two resistors? Any rules of thumb?
the ratios of the resistor impact the trigger / max voltage range.. i think the app notes for the hcpl-3700 go into it more detail then i can put here.
resistor -> zener + smol cap -> resistor
ok, I'll take a look. I'm having trouble finding a resistor+Vz combo that doesn't dump a boatload of power into the resistors
can just simulate it if you want to know how tolerances and what not impact voltages.
yeah, right now just looking at back V=IR calcs I'm dumping ~.25W in each of the resistors
not sure why I couldn't find it, but looks like I can source 10mA current limiting diodes which should take care of it for me
For the analog experts here: a bit curious about the purpose of that transformer connected to the output - what purpose does it have there? (Overall, this is supposed to bethe power amplifier stage of a small transmitter - the IC is an octal buffer, and used here effectively to buffer and increase the power of a signal applied to its CLK0 input. (overall schematic at https://github.com/IgrikXD/WSPR-beacon/blob/master/Schematics/Schematic_WSPR-beacon_2.0.pdf)
I am not an expert, but it sounds like it has to do with cutting down on interference and balancing the antenna
https://chelegance.com/archives/understanding-toroid-ferrite-cores-from-ft240-43-to-type-31-materials/
Alright I'm having some issues with the L293D part of my chip
Everything else works fine... except extending the actuator via the L293D.
I powered the arduino with USB so I dno't need to supply the 7V, and I put the 12V power in. However, between GND and the bottom left pin of the chip, I'm only seeing 4.12V as opposed to the 4.7V I'm seeing on the other side.
The arduino also gets a bit hot when driving D13 high
I know for a fact I'm putting 12V in
It's part of a matching circuit to match the impedance of the buffer's output (probably near 0 ohms) to the impedance of the antenna, (probably near 50 ohm).
Wait I'm stupid, my battery pack wasn't on lol. I'm seeing 12V now there at least
But I am only seeing 4.4V on the output as opposed to the 12V that I'd expect.
How much current does your actuator need? It seems like you should have much thicker traces for your lines from the L293D to the actuator
Uhhh hopefully under 500mA
Although I do see that now. I don't wanna order a new PCB and have to somehow desolder all this and wait like 4+ weeks for shipping
I don't suspect thin traces would make the voltage drop by 8V though, no?
Especially under no load
What do you see if you probe the L293D pins directly?
And how have you configured the pins you're controlling it with?
Well the output of these pins is tied to the pins I'm measuring, so 4.4V RN
Sure, but good to confirm the voltages at the chip itself too
I have 2A and 3A wired together, and 1A and 4A are wired together
Oh that's fair, one second
2Y and 3Y are also wired together (the output) as are 1Y and 4Y
yeah I see that. I was asking about how you're driving them via the nano
Oh, just via D13 and A5 as digital out pins
And what are you doing in the code 🙂 just something like pinMode(OUTPUT) and digitalWrite(HIGH)?
Yup, I have ```
pinMode(EXTEND_ACTUATOR_SIG, OUTPUT);
pinMode(RETRACT_ACTUATOR_SIG, OUTPUT);
digitalWrite(EXTEND_ACTUATOR_SIG, LOW);
digitalWrite(RETRACT_ACTUATOR_SIG, HIGH);
in `setup()` and that should be it. I commented out `loop()` contents
Oh wait I had commented out the pinmode stuff too.
So this outputs -12V which is right
However, if I try to extend it, I just need -6.6mV on the output. Let me check the pins directly
Huh... D13 doesn't actually appear to be outputting anything at all
How do I check if it's faulty? IDK if perhaps the chip is messing with the output
How did you attach the nano? Can you just pull it out of the headers or did you solder it in?
D13 is also connected to the builtin LED right? I think it should still work fine as a GPIO but maybe that's somehow affecting things
Did you definitely define EXTEND_ACTUATOR_SIG and RETRACT_ACTUATOR_SIG correctly? 🙂
It is soldered in, since the module was too tall otherwise lol
Indeed, just const int
It had worked when it was on a breadboard which is the curious thing
The number of times that has happened… 🫣
Is it possible something is wrong with the pin itself? I don't know how I would've killed it
Not sure how to check
To confirm, you do see a voltage on the other pin (A5)? Are you reading from the nano or L293D (or both)?
I had checked both, yes. I saw 4.7V on the pin of the chip that A5 connects to, and -12V on the output
And you see nothing when probing D13 on the nano directly? And you changed your code to write it high?
What are your actual pin definitions?
👍 thanks! With some extra help , I was also able to reason this out as a 4:1 transformer - so it's presenting a 12.5ohm resistance if the load was 50ohm
Yup, and yup
Just a constant 6.6mV so basically 0.
const int EXTEND_ACTUATOR_SIG = 13;
const int RETRACT_ACTUATOR_SIG = A5;
Oh wait
I have these backwards... lol
Hold on one second
Hmmm... 0V on both actually
Actually, D13 and A5 are showing what I think is corrosion... what
digitalWrite(EXTEND_ACTUATOR_SIG, LOW);
digitalWrite(RETRACT_ACTUATOR_SIG, HIGH);
So I see 4.79V on A5 and 0V on D13 with this. If I flip it, I see 0V on both
Is the LED on/off in those different states? If not, it seems like there's some sort of hardware issue
You can also try const int EXTEND_ACTUATOR_SIG = D13; just to be explicit about which pin you're talking about
Do you have another identical nano you can test with that's not attached to your board?
Indeed I do, let me grab it
I just don't know how the D13 pin would suddenly give up
Let me check real quick
Hmmmm, D13 doesn't exist.
LED does not turn on
Also the chip itself seems to get weirdly warm when I drive D13 high.
D13 is literally the only pin left too. D2-D12 are taken, as are A0-A5, and A6 and A7 are input only :/
Can you take close up pics of the solder joints on the nano and L293D?
Sure, though my camera focus is pretty bad. One sec
Best I could get
Oh lemme flip it over
Yes it's messy but they're not shorted
Clean. That. Flux. Especially with so much of it unactivated.
I tried using alcohol and a q-tip but it didn't work very well
What else should I use? Is a toothbrush too harsh?
You need rags to remove it from the board. Not tiny bits of cotton.
- Rinse with IPA.
- Soak a rag in IPA, apply to board, scrub it.
- Rinse
- Use clean dry rag soak up the IPA
- Repeat until clean.
Putting a little bit of liquid and pushing it around with a q-tip doesn’t remove it.
The rag is too big to fit in the little gaps :(
Would the flux explain the dead pin issue?
I'd desolder it and replace it but IDK how to desolder 30 pins at once
Nono, the IPA dissolves the rest of the flux so you don't need to drag the rag fully in between each solder point, a blotting motion and 'wiggling' the rag is what you should expect here.
But with that much, it’s going to be a dozen cycles… at least.
“Clean room wipes” (lint free) are amazing for flux clean up.
Agreed on both, and also the alcohol-only facial scrub discs can be great for smaller projects like this.
But shouldn't I verify I don't need to resolder something before cleaning?
I dunno how flux would somehow cause the D13 pin to break since I don't think flux is conductive
Clean the flux off first. It might be that that joint didn't adhere fully, and getting the flux off before you re-work things will help constrain whatever work you do to re-solder joints. Better to get all the flux off at once on something that small basically.
I checked the voltage from the top though, not the bottom
Also how should I go about desoldering in bulk. I need to get all the pins desoldered at once to take this nano off.
And what kinds of things in software control would cause corrosion?
Desoldering is always just alot of poking (desoldering wick like https://www.adafruit.com/product/149 and/or solder sucker https://www.adafruit.com/product/148 ) and patience for the cheap way, or some kind of 'hot air rework' is the other option to heat up more at once safely but those are quite expensive versus wick and a sucker.
I actually have both of those, and a heat gun somewhere in the basement
I could never get soldering wick to work though
And the solder sucker doesn't ever suck all of it out, just most of it, so it's still stuck in there
The wick just takes practice, and the iron might need to be a bit hotter than normal since you're heating the wick up to suck up the solder.
Mine is not configurable lol
with enough heat, flux will carbonize and conduct electricity. don’t burn your flux
I don't think I burned it, there's just a lot here
I just need to figure out how to remove all this solder at once so I can pull this nano out
But also what causes the corrosion in the first place? It's suspicious that it's only on these two pins
I don't think it's corrossion, it's flux.
have you isolated D13 yet in case it’s something it’s driving that’s causing weird behavior?
I have not, though it's really soldered in there so I'm not sure I can now
But I don't see why the control pin for the L293D chip would be somehow driving it low constantly
Unless something's up with the ground plane I put there...
But the ground plane is on the other side (D13 connects to the 2nd row from the bottom)
And that wouldn't explain why A5 still works with that same ground plane there
But on both of the pins that have to deal with the linear actuator and only those?
Might be the current draw was causing more heat cycling on those pins than others, possibly those two were a weak solder joint internally even if externally it looks okay, or, or, or... lots of possibilities, but corrosion that fast on a solder joint is less likely than alternatives and leftover flux can look REALLY nasty and/or like corrosion.
The stuff around A5 seems to be lighter and more matte than the shiny darker flux on the other pins. I'd grab a picture but this phone's focus/flash combine together to make some of the crappiest photos known to man
But it's also weird that I didn't have the "corrosion" issue on the breadboard, so I'm at a loss
Should I sever the trace and see if it's still busted? I don't wanna break the board if it turns out the nano is the issue cause then I need to desolder everything

do you have a clear photo of the corrosion? i’m not seeing it
And I mean that honestly, I don't know, I'd be tackling it incrementally and scrubbing everything clean to examine it better under a magnifying glass first.
yeah when prototyping stuff, cutting traces and soldering bodge wires is a thing you need to do sometimes
When they said 'rinse' with IPA they weren't joking either, literally pour a cup of it into a bowl, pour the bowl over the circuit board into another bowl, go back and forth a few times to really slough some of the flux off, it looks THICK.
Unfortunately I cannot, because my dinglehead brother insists that the lights are off when he goes to bed and this camera flash will not cut it. I can try tomorrow in the daylight
Oh dang, alright I'll give that a try tomorrow. I don't have a lot of alcohol to use but I'll see
I didn't have much luck using a washcloth dipped in alcohol before
Most phones have a way to set the light to 'on' instead of 'flash' it's just not well publicised, which can give a much more stable photograph of shiny stuff at times and let the white-balance adjust to the light better.
I must go to bed, but I'll try cleaning and getting a better picture tomorrow

Thank you guys so much though for helping me with this so far
I've got a gardening watering bot project brewing. Going to use an array of sensors + forecast data to decide when to water. I am going to run the whole thing off batteries, and so I've got a really nice latching solenoid valve to turn the water on/off. It's 12v, so I am powering it off a pack of AA's. The rest of the sensors and microcontroller are powered with a solar panel + rechargeable battery at 5v. My concern, is that if my AA batteries die with the solenoid latched open then I could end up in a catastrophic "water stays on forever" situation - so I would like to alert (via text, maybe sound) when that occurs.
Question to this group is - What's the best / most efficient way to ensure that the water has stopped flowing after I've triggered a "close the valve" command? Only thing I've come up with is a flow meter downstream (down pipe) from the valve. Close valve, check for flow of zero, if not zero then alert.
Is there a simpler solution I'm missing here? Maybe one that doesn't involve installing a big flow meter?
It occurs to me this must be a common issue with latching solenoids in the real world, and I'm wondering how people failsafe them IRL?
Depending on how exposed (or if you can expose) the solenoid from the housing, you might be able to use a limit switch or hall effect / other magnetic sensor to determine if it's in the right position, although I think a flow meter is the only way to know for sure
You might also be able to use a contact mic or accelerometer to determine if water is flowing, but that could lead to false positives as well
Alright, I got the heat gun. It has a 400C and a 700C setting
How do I use this properly to desolder this board without melting the board or components
what temp solder did you get? ideally you want to go just a bit over that but otherwise keep it as low as possible
The heat gun ended up making the board smoke, and my efforts to drag solder the nano off failed
So I'm desoldering everything else and calling this board a lost cause. Zero clue how to test if this chip and what not still work independently though
Need to check the nano I use too so I don't have to deal with this crap again
All because ONE freaking pin was dead. I'm upset :/
I got no clue what temp solder this is though, and my heat gun only has two settings
The resistors shouldn't be an issue with overheating
And the wires of the IR receiver are long enough
Hopefully the L293D is fine, but other than that that's really it
The RGB led is trivial to replace and I have lots of them, resistors should be okay to replace too (though I don't think I have many more 150R)
I just wanna know why the D13 pin worked fine on the board and fried on the PCB
Like seriously one freaking pin and the whole board is screwed
It's hard to say for sure, but my guess would be with it being so close to your 12V supply for the L293D that those got bridged somewhere along the way and that killed it, but 🤷♂️
The 400F setting would be more than sufficient, but sadly a heat gun is often not very stable for temperature since they're used for destructive work like paint stripping and are high-volume hot flow.
So when soldering up the new board, should I leave that pin unsoldered and connect it with a wire or something?
I mean the clearance passed the specs or whatever it's called
The clearance passed specs on an ideal perfectly assembled board, but a 'whipped cream peak' on a solder joint could get things too close, voltage jumps maybe, lots of possibilities that can't happen on a breadboard by comparison.
yeah, aren't most modern design rules meant for automated assembly rather than hand soldering?
Automated assembly was an option?
Or is that the really expensive option
It seems more likely that 12V would short to GND rather than D13 shorting to 12V
I was so dang close to this working first try :/
If there was another pin that would work I would've just soldered a wire in place, but literally every pin is taken
gotta use something other than a nano next time 😉
I didn't mean bridging in the PCB, more like something conducting between the pins during testing.
e.g. when probing with a multimeter it's easy to accidentally bridge adjacent pins on the IC
So I took the ICBP or whatever its called headers off this one (even though I soldered them on lol), but there's little bit of copper exposed, is that a problem?
I wonder if that's why D13 was failing before. The soldering left behind looks shoddy and I wonder if it was shorting to ground over there considering D12 would've been GND, and the chip itself was getting hot when trying to drive it high
It's definitely not ideal that that is exposed, but if it's not connecting anything it shouldn't be, it's probably fine. Might be good to cover it though.
Can you check continuity between that patch and the pins there?
Also check if D12 and 13 are bridged to ground?
I just checked with a program to drive D13 high and the LED turned on as expected
I'll check the patch right now
Looks like the patch is a ground plane not connected to anything except the ground pin itself right there (the top left one)
Out of curiosity I checked the other board and yea that was the issue
3 of the ICSP headers were shorted to ground
So if I had just fixed that before desoldering that, I'd have been fine. Nice one Felix
Sadly that's how troubleshooting goes on PCBs sometimes you don't find what you should have tested until you've dismantled everything possibly destructively. :S
Check that the ICSP are shorted in one spot
Top left to middle right
IT'S FREAKING D13 AGAIN
Wait it's only shorted when mounted inside the PCB...
I took it out and it stopped
Oh the pin hole itself is shorted to ground, even without the nano
It's not the board design, this other one doesn't do it
But there's literally no solder around the D13 hole, so I don't know how that's possible
Hold on let me check if the chip got shorted open or something when I tried to desolder with the heat gun
Alright yea the chip is dead. Took it out of the holder and my multimeter beeps between 2A and 3A and GND
I wonder if the chip was dead in the first place and that's what broke the nano before. I didn't even think to check the chip before desoldering everything... :/
great! I was waiting for that, thx.
I'm still thinking something got accidentally bridged while the 12V supply was connected. Those pins are max 7V and it's unclear what might happen when that's exceeded.
While it's a pain, it's generally a good idea to check all of your chips are working before you use them, but it's a tradeoff between time/effort testing up front vs diagnosing later, and potentially damaging other components in the process. 😬
Do you think I should sever the trace and manually connect it via a wire?
I mean briefly getting bridged while probing, or some piece of stray metal or other conductive material somewhere along the way. If you probe the board with nothing soldered in, is it still bridging between GND and where D13 should be?
No, the L293D was shorted
So when I plugged it in, D13 was getting shorted to GND
Even without the nano there. Just the hole for D13 was to GND
Was it shorted when you installed it though? And is it the IC itself or the board?
I don't actually know, but the IC itself is shorting a short
Right, but that could have been caused by something else shorting it initially
I placed an order without prepay to see what tariffs would actually cost and FedEx delivered it without requiring them to be paid in advance... -_-
so they do allow placing the order without prepaying tariffs? I thought JLCPCB requires prepay
Oh I see. But what kinds of things could cause that?
I supposed something had to have happened since it worked on the breadboard, but what?
Would shorting D13 via other means break the pin on the IC it was connected to? Maybe it was the heat from the heat gun? But that was after the pin already didn't work, so maybe it was the ICSP
nope, there are a few options with and a few without
FedEx + "DDP"
just FedEx
note the $20 carrier fee is added to the shipping cost, so prepaying doesn't appear to have any advantage (in terms of cost -- it could potentially save time)
Alright, I got a second board soldered up
I've verified D13 is outputting correctly. I am now going to feed it 12V to the chip, and if it breaks at that point, I'll know it's that
🤞
Anyone know of a touchscreen e-ink module? I'm curious about making my own e-reader like a Kindle (but not under Bezos' thumb)
WE HAVE SUCCESS
IT WORKS
IDK what the old board's deal was but it WORKS
Actuator is MOVING, bargraph is ON, LED is BLINKING, IR remote is CLICKY
If there are not, you can always buy touch screen overlays and put it over your eInk in your project. I recently took apart an old Garmin car GPS to recycle it and saved the touch screen and Adafruit makes a break out board to drive it. So if I even wanted to add touch screen to anything (doesn't even have to be a display; it could literally be a 4x6 piece of paper with icons drawn on it) I have a way.
Are microfibers safe to clean up flux with 70% alcohol?
Or should I spring for 99%
Are you asking about the fiber or the % alcohol? But either way most cloths are fine just some might leave behind more fibers than others but shouldn't harm anything. And 90+% is always better than 70% for electronics only because it is more effective but there is nothing wrong with 70% if it is doing what you want. usually for "alcohol" the percentage just means the amount of water vs. alcohol but when the bottle is labeled "rubbing" alcohol, that often implies some oils might have been added and you don't want that. But the ingredients label should make that clear.
Both, I suppose
Roger that, thank you. I was advised that cotton swabs wouldn't do the trick and was told to use a rag but these rows of pins are close together so IDK how I'll get a rag in there
What kind of module? Are you looking for the bare component? Or something in a housing?
The only device I've seen that's all put together but meant to be customized is this one
https://shop.m5stack.com/products/m5paper-esp32-development-kit-v1-1-960x540-4-7-eink-display-235-ppi
M5Paper ESP32 Development Kit V1.1 has a touchable 540*960 @4.7" E-ink display, which supports 16 gray scale levels. E-ink displays are easier on the eyes for reading or viewing for longer periods, having low power consumption. It can be used as an IoT Terminal, E-Book, industrial control panel and smart home panel.
I think some people jailbreak or otherwise mod kindles and other e-readers but I haven't tried that myself
Yeah Amazon unfortunately patched a lot of the mods :/
The bare component would be fine
You're not going to be wiping, so the ability to get the cloth between the pins when moving it isn't an issue. Think of the motion much more like cleaning up a mess with a sponge, where you press down and then wiggle it around a bunch and then when you let go the pressure you release soaks everything back up again.
I would use the cheapest rags you can, don't use nice microfiber cloths. Old torn up T-shirts are almost ideal, if they're cotton.
I have always been partial to these types of brushes: https://www.digikey.com/en/products/detail/mg-chemicals/855-5/949490 where usually they are a little too long out of the package (so too soft) so I cut them down shorter to make them stiffer. These and alcohol are good for scrubbing off flux and usually I can sort of rinse off the flux after scrubbing by using more alcohol and letting it (with the flux) drip off the edge of the board. $7.70 for 5 of them and I have found I can usually use ONE brush for years. And a can of air if you want to dry it off quicker than air drying.
Those brush types + clean room wipes = my strategy.
IPA + Brush. Then clean room wipe with IPA and brush. Repeat until clean.
I watched a video where a guy achieved pwm on a breadboard using oscillators
Which is entirely over my head but now I'm interested to look into it
I still get a little bit of ghosting/ random brightness pulses on select lines. This was totally remedied in the previous library by the pwm mod, which I've done to the bonnet
I had to Google it but yes this is the key to a lot of analog signal emulation
I also have to try the de-0 nano project if I can get it to work. Maybe I can apply that to some stuff on the de10
Alright, so I did this
Is it supposed to look like that
No idea what I'm doing just yet but I found the resource 🙌 now I have studying to do
You can make a PWM circuit with a pair of 555 timers (or if they are still made, the dual timer 556 chip). I have done it before for simple PWM control way back before you could just program a MCU to do it for you.
You just need to clean it more. If using alcohol, don't be afraid to literally drench the board, scrub, and more to rinse it away. Or some water works fine as well for a rinse depending on the type of component on the board (you want to be careful for anything that could trap water under itself).
I was dunking it completely and mopping it up with the towel but no dice
Pour overs, submerged, wipe, still there
I don't have a brush except a toothbrush sadly
That could work (assuming you aren't planning to use it on your teeth after 😬)
I got a collection of like 5 old ones so no worries lol
I hope you didn't use the one you brush your teeth with.
You’re telling me that you have flux in your toothbrush?
i am creating a pcb to control a strip of LEDs, does this look okay, and what are some improvements that I can do?
I'm working on an esp32 based light strip controller. I assembled the board and had some very odd behavior from the esp32. it seemed to boot loop unless bot the external 5v and the usb 5v were supplied. I have a feeling the problem is in my ideal diode power selection circuit. Could someone take a look at it and tell me if there are any glaring errors?
What kind of LEDs?
Are these addressable LEDs? Is the red thing a level shifter?
Do you know if it is fast enough for addressable LEDs? Many level shifters made for I2C type level shifting are not fast enough for many addressable LEDs.
Is the bottom right your input voltage and the bottom left for your LED strip?
What voltage is the strip getting since you didn't connect the RP board's red wire to the input wire I assume they are different voltages?
Yes! They are addressable.
The red thing is a 3.3->5v shorter.
Unsure, but I will try.
The bottom right is the ground, signal wire, and 12v from a barrel jack.
Hey, I've got a custom ATSAMD51G19 board and I've gotten a new bootloader and circuitpython .uf2 built for it. I've gotten all digital stuff working great, but I'm seeing some strange behavior with the DAC.
When I initialize DAC 1 just by defining an object
dac1 = analogio.AnalogOut(board.A0), the DAC voltage floats upward towards ~2.7V. When I write to the dac via dac1.value = 65535, the voltage drops to zero and stays there. Any further changes to value don't do anything on the scope.
Has anyone seen anything like this before?
Here's the schmatic if it helps
I've looked at the various hardware definitions in the firmware build, and it would appear to be well defined - the pinout is almost identical to the itsy-bitsy M4. The fact that when I try to initialize the DAC something happens is probably a sign that everythings wired up right.
OK so 12V LEDs then. Looks correct to me.
Cool. Thanks a lot!!!
As I mentioned, my only concern is the logic level shifter may or may not be fast enough for addressible LEDs. So if you have issues you may want to try something different.
Right right, I get what you're saying
That is peculiar 🤔 do you have your circuitpython files pushed to GitHub by chance?
Ah, I see you commented on the DAC issue on the circuitpython repo
For reference: https://github.com/adafruit/circuitpython/issues/7860 is the DAC drift issue
@distant raven No, I haven't published them - it's just a hobby project for a synth I'm making. As far as I can see, nothing in the board config has anything particular to do with the DAC, but this is my first custom board.
Can you just use their suggested workaround?
Yeah the workaround is just 'set the DAC value after initializing' so just... seems quick to fix in the meantime in your program init at least?
Unfortunately, it appears I have some other bug in my setup, as writing any value to the DAC in circuitpython appears to drop the voltage to 0, regardless of the value written. The DAC stays pinned to zero until I deinit() and then remake the object.
PCB wise, I don't think there's anything wrong with the actual traces.
Is there a reason for it being so dense? And with no gnd layers in between wouldn’t be surprised if you get some interference
It's smaller than a feather and my first time working at this scale. In retrospect, it should've been a 4 layer stackup.
Is there a good way to determine what layout/supporting components are needed for an IC when the manufacturer seemingly doesn't provide them? I looked through all of the docs provided here but couldn't find anything (or am blind, also possible). I did find one breakout board for it, but there's no schematic and the pics are too low res for me to determine what exactly is on there.
The only components there on that breakout look to be level-shifting related or common resistors used as part of the protocols like the I2C ones or pull- resistors the datasheet documents as recommended or required for certain pins.
AKA: The whole reason to use this chip is the lack of external components needed, which is also why it's fairly expensive.
Yeah it looked like mostly resistors and capacitors, but I wasn't sure which ones, what they're attached to, and how important they are. I also couldn't tell if that one 5-pin IC was for power or level shifting or what. Still not entirely sure
That 5-leg chip is a kinda dead giveaway of a very common level shifter, so I'm making an assumption sure but there's not a lot else seen in that form factor.
Level shifter? Did you mean voltage regulator?
Looked more likely to be a https://www.ti.com/product/SN74LV1T34 to me at a glance?
It's a common package for LDOs. It has thick traces and two caps on either side of it. Looks more like a regulator than a logic device. But, withouth more info it is hard to say.
Thick relative to the traces on the other IC
Also, the SC18IM704's max VCC is 4.6 volts with a nominal 3.3V
Ah, fair, I'm too used to seeing the 5-pin level shifters in breakouts lately, must just be a niche I've stumbled in that uses them. I hadn't noticed the thicker traces.
The first flags for me were the two caps then an LED with resistor. Yelled to me: "LDO"
Yeah I was thinking LDO as well, although still unclear which exactly
Hi folks. Im working on a robot which the head rotates and has 4 neopixels. the head can be easily removed and the connection I will be using between the main circuit and the neopixels is a 360 blind magnetic pogo connector (see bellow). There is one pin that is recessed which I think is good to connect the red wire (5v). My question is, will it be safe enough to disconnect the head while the circuit is hot ?
Well for only 4 neopixels that's ~.25 amps current peak if they're all bright white (assuming RGB), make sure there's the recommended resistor on the data line and a capacitor (on the neopixel side) to stabilize any voltage variance from the pogopin connector would be good ideas.
There is never a guarantee that it will be completely safe, especially if the only consideration is a single pogo pin connector. Ensuring 5v breaks before and makes after ground is the only thing the connector is able to do, and with a magnetic connector like that you also need to consider possible contact if the connector comes off at an angle somehow.
With that design the 5V pin being recessed like that avoids all but the most actively malicious angled detachments I think with that design, it's honestly a good form factor to my eye?
Additional design work is likely necessary to ensure hotswappability.
Clamping diodes and reverse polarity protection are probably good to add for additional safety.

Also consider how you would protect the exposed pins from a short circuit AFTER the magnetic piece has been removed.
Thanks folks ! resistor and diodes I have plenty, but capacitors I think I only have a couple from a basic electronic bundle. do I need anything special, how can I figureout if what I have is good enough ?
Clamping diodes are probably a bit different from standard switching diodes, you probably want to consider using tvs or zener diodes depending on the type of failure-causing event you’re trying to protect your circuit from.
As for resistors and capacitors, https://learn.adafruit.com/adafruit-neopixel-uberguide/best-practices has some tips to consider. As you’re only using four neopixels, I’m not too worried about adding a lot of capacitance, but having some (maybe like 10uF?) will help the stability of the bus some. Just make sure whatever components you use have the right ratings for the circuit in question.
@worldly schooner @timber wyvern thanks folks really appreciate it
Hoping someone can help me with this...
I have this adafruit 16 channel servo controller for RPi, it was working fine on all channels for a few weeks but today it stopped working on channels 4 onwards. I checked all the servos, they are working fine. I took the board off the RPi and noticed there is this white residue around solder joints on channel 3 (see photo). 0,1,2,3 seem to be working fine still. Anything beyond 4 is not sending signal/power. Is the board kaput or is there anyway I can salvage it?
Looks like flux residue. The residue can absorb moisture over time and become slightly conductive. When in doubt, clean up the flux.
Ah yes, I cleaned it all up now using 99% residue and it's still not working... channels 0-3 seem slightly glitchy as well. I think the board is done, lesson learnt I guess.
I doubt flux residue would have caused damage. It will cause funny behavior because it is only slightly conductive. (but not a 100%)
I'll give it another clean and try again, I can't see anymore residue at the moment though.
Ah something must have gone seriously wrong with this board, I can't figure out what it is. After some more testing I realised it also took out 2 servos, they are running really hot now and have a miniscule amount of torque, luckily the other servos are still fine.
I'm working on an esp32 based light strip controller. I assembled the board and had some very odd behavior from the esp32. it seemed to boot loop unless bot the external 5v and the usb 5v were supplied. I have a feeling the problem is in my ideal diode power selection circuit. Could someone take a look at it and tell me if there are any glaring errors?
I do see D1 ST wired to D2 CEn, and the ST pin pulls down when it’s on, so D1 will turn D2 on after seeing its own status active.
Does this application require the ideal diode? It doesn’t seem like the 5v goes anywhere besides the LDO.
im using the idea diode to swap between 2 5v suypplies where both could be plugged in at the same time
external 5v with a high wattage to drive led strips and a usb-c input
Well, for those ideal diodes, you definitely need a weak pulldown to GND on the CEn pins. Datasheet says do not leave that pin floating.
Heya, I'm designing a keyboard board and need a cool way to connect up a few different PCBs. I need at least i2c, vcc and gnd, but if possible a few more wires as well. Any suggestions? A short JST cable could work, but ideally I'd have something that lets me snap the boards together directly
I intend to use a series of MCP23017s to read button states of each board and a pi pico to control the whole thing. I also want to add at least one rotary encoder for volume or whatever
there is always the cheap and dirty way of just using 90 deg 2-row male/female headers
nicer but more expensive option is using magnetic pogo pin connectors like this one https://www.adafruit.com/product/5359
(Adafruit only sells up to 5 pin version, but you can find similar ones, with more pins, on digikey, AliExpress, etc)
Is it complicated to line up a 90 deg header thing?
Not really, although the angled female headers I've used don't (at least on their own) sit at the same height as the female ones. I was able to get them to line up by holding them in place and solder them using male headers already soldered into a board at the right height.
To (hopefully) clarify what I'm saying: the female headers I found don't have that plastic part that sits against the PCB to put them at the right height, so I attached the male headers then aligned the PCBs at the same height to solder the female ones.
Oh yeah, that's a good tip!
I'm conditioned by my work to try to make anything into something that can be reused as something else, so this keyboard will be usable as a 5x8 key macro pad, a 5x16 mini keyboard as well as a full keyboard
Do you have space for / are planning to put the headers only at the top, and inset from the edge? As you can see with my boards, if they're along the edge there's going to be a somewhat sizable gap where you can't have keys.
I was planning on having them on the top, hopefully I can offset them a bit so that I can minimize the gap
In my current draft drawing I've got 43x 25mm at the top that's available
Hi, I just received my order for a 12-Channel 16-bit PWM LED Driver (TI TLC59711),
https://cdn-shop.adafruit.com/datasheets/tlc59711.pdf
which I'm not planning to use for LEDs but to control four DC brushless motors which require a 20-30kHz PWM signal. This is to be used with a Raspberry Pi, so I have 5V and 3.3V supplies available. The board requires 5V to 17V (no problem) and can supply its own 3.3V output (Vreg).
What I'm trying to do is feed four of its outputs to PWM pins on the motors. Since those are 3.3V logic, I'm assuming that if I'm using a 5V supply for the TLC59711 its output will likewise be 5V. But looking at the datasheet it seems there's a "Direct power supply: 3.0 V to 5.5 V" which suggests the chip itself can operate at 3.3V, and therefore output 3.3V, which would make this all a lot easier and I can avoid voltage dividers, transistors, etc. I should add that the motors have a wider voltage range available, but in order for the IO of the motors (direction control and FG feedback) to be compatible with the Pi I'm supplying its Vcc as 3.3V.
So the questions are:
- is it possible to drive the board with 3.3V?
- if not, what does anyone recommend as the best way to get 3.3V compatible outputs from the board?
- any advice on obtaining 3.3V compatible outputs from the TLC59711 much appreciated
The IC itself uses VCC, which it seems can be 3.3V
V+ is for the LEDs/motors/etc. and can be up to 17V? Although the schematic labels it as 24V 🤔
I kinda agree but that’s not what I’m reading in the datasheet which lists the lower limit as 4V. I guess it doesn’t hurt to try though, I really want 3.3V compatibility across the board since it’ll be hooked up to a Pi and the motor’s logic is whatever you feed it as Vcc.
I guess it doesn’t hurt to try though
There are some devices where it could hurt to try, so good idea asking about it 🙂
The adafruit page says:
There's also a handy on-chip 3.3V regulator which you can use if you need a logic level regulator.
So it seems like it's designed for 3.3V control
BTW, what sort of motors are you looking to drive? It looks like these are max 60 mA per channel, which isn't a lot as far as motors go 🤔
Also they do make a bunch of warnings that this is not an optimal chip for servo use, since to drive higher currents you end up in that split VREG/VCC/VLED configuration. There is the nearly equivalent 12-bit 16-channel PWM that specifically is configured to support servos OOTB that might be easier to use?
I don't think servos are the use case here
The reason I'm not simply using the software PWM on a Pi is that the requirements for the motor are 20-30kHz. There are two hardware PWM pins on the Pi that can handle that frequency (actually four pins but only two channels) but I need to control four motors so that's not going to work. Most servos use pretty slow frequencies, whereas the two TI chips on the Adafruit boards (TI TLC59711 and TLC5947) can easily handle 25kHz. I've got the TLC59711, just arrived today in the post.
With that frequency requirement I'd immediately honestly be busting out a Pico 2 with the HSTX pins TBH at that point possibly, yeah. That's some spicy motor requirements.
It's a 25mm dia. 40mm length DC brushless motor (recently released by DFRobot) with its own internal controller that sells for about US$20, so I'm highly motivated to make it work. Makes a great upgrade from N20 motors for small robots. I'm hoping the Adafruit board is able to drive four of them over SPI, would be a great solution. I've spent the last few days writing a CPython motor controller for it, a bit trickier to work with than a normal DC motor but it's getting close to finished.
The 4v lower limit applies to the input of the internal 3v3 regulator. You can use 3-5v directly by supply power directly to vreg.
Thanks. I have to admit I'm a bit stymied. Usually the schematics and docs from Adafruit are really good, but in this one case it's a bit confusing. There's normally a "pinout" section in the how-to (missing) and the schematic lists Vcc but not Vreg. There's a Vcc pin and a V+ pin on the board itself. Maybe this is something that can be fixed in the online help pages, but can we safely assume that V+ is Vreg? I've plugged Vcc into 3V3 on the Pi and the green LED has lit up, but I'm afraid to take it much further absent confirmation. I feel like I must be missing something somewhere...
Oh, wait, doh. I'm looking at the TLC5947 schematic, not the TLC59711 one. I see Vreg on pin 20 but not that it's labeled V+. On the schematic it's labeled (on the TCL59711) as Vreg. I just don't see what V+ connects to anywere.
Here's my test rig with a Pi 3 A+, the brushless motor, a Pimoroni digital pot (for speed control) and the Adafruit TLC59711.
Oh, the adafruit board, right. Looks like V+ goes to the vcc pin on the IC and board vcc connects to IC’s vreg
That’s… rather confusing.
I have to admit I do feel a bit dense not figuring that out, but it certainly could be documented better.
In any case, you should be able to supply 5v to the board’s vcc and still use 3.3v logic
Uh, wait no, v+.
Okay, thanks. I have that fallback that Vcc is not Vcc but rather V+, and Vreg is Vcc.
Yeah this naming is twisted
So... using the nomenclature of the Adafruit board, not the chip, I can supply 5V or 3.3V to which pins, and use 3.3V logic?
...to confirm
Both? Can I just use 3.3V on Vcc? Or do I also need 3.3V on V+ as well?
I'd prefer not to worry that I might accidentally end up with 5V on a GPIO pin if at all possible, therefore driving it with 3.3V seems safer
Looking at this diagram, they have both connected so I’d probably go with that
Ah yeah, so "Vcc" on the datasheet, which is V+ on the Adafruit board, permits 3-5.5V. I frankly don't understand how Vcc and Vreg on their own datasheet are both connected to the same thing. Weird.
The diagrams at near the top of the TI datasheet make no sense, like there's no reason for the 3.3V regulator at all. Then further down is this.
As according to the TI datasheet, Vcc on the TLC59711 is an input, Vreg is an output, which of course makes sense in terms of their respective names.
This means that on the Adafruit board you should be supplying 3-5.5V power to the V+ pin, and only using Vcc (which is really Vreg from the TLC59711) as a 3.3V source, as it's actually an output from the chip. 😵💫 This really needs better documentation.
I at very least don't feel so stupid now.
As a whole the TLC59711 is a confusingly documented chip, yeah. XD Basically if you ONLY have a >5.5V supply? Then you wire up vreg and vcc separately, with vreg basically routed to GND through a capacitor. Otherwise vreg/vcc get linked together in every circuit example I see, running on the 3-5.5V circuit.
Yeah, I can totally see someone frying some of their hardware based on those errors.
It turns out the whole idea of using this board was misguided: I need a 20kHz to 30kHz PWM signal, and its PWM frequency is fixed and nowhere near what I need. Neither is the sister board, the TLC5947. It seems there's no I2C or SPI board available for the Pi that can generate that high a frequency of PWM signal. Hmm, back to the drawing board.
It's borderline on the low end, the TLC59711 runs at 10Mhz internally and chunks the 16-bit PWM value into 128 chunks to sort of 'dither' things between a bunch of smaller 9-bit PWM segments that only vary by 1, and then it does the 'global' brightness scaling on each 9-bit chunk, but only has to update it's internal latch states at the lower 10Mhz / 64K = ~152.5Hz frequency but gets 10Mhz / 64K * 128 = 19.5 kHz effective PWM.
That 20Khz minimum PWM frequency is what I meant by that servo being spicy, that's a high PWM frequency to achieve easily short of like... raw PIO or HSTX on the RP2040/RP2350 being the low-hanging fruit for that kind of task these days.
Are you saying I can actually get a 19.5kHz PWM signal off that board?
Yes.
The PWM data internally only updates at ~152Hz (when messing with the global scaling, etc), but it runs the PWM outputs at 128x that to get both high precision AND multi-kHz duty cycle rate.
For comparison, PWM on the RP2040/RP2350 can do up to half their CPU frequency for raw bitrate, so 60-75Mhz, with a flexible PWM counter that's based on an exact counter increment.
So RP2040 at 125Mhz so 62.5Mhz PWM? Set the counter wrap to 2,500, 0-2499 PWM range at exactly 25Khz without any fancy dithering.
RP2350 at 150Mhz so 75Mhz PWM? Set the counter wrap to 3,000 instead, range 0-2999, exactly 25Khz again, again with no dithering.
Their PIO (and on the RP2350 the HSTX) subsystems can do SIGNIFICANTLY higher frequency rates with more limits on waveform.
Like the RP2350 can do 300Mhz bitrate on the HSTX outputs, there's 8 pins they can be routed to (including inverters) but only 4 HSTX generators though.
Hmm, that was not remotely clear to me from the documentation. How would one set the PWM rate to 19.5kHz using the Python library?
I've considered using an MCU but then I'm in either I2C slave or UART territory, so if I can use this Adafruit PWM board over SPI that'd be great.
There's nothing to set, the PWM rate is always ~19.5Khz.
Basically it has 16-bit precision but it outputs 9-bit PWM pulses, so the effective PWM frequency you'd see on an oscilloscope is 10Mhz / 512 not 10Mhz / 65,536 for the PWM frequency.
And this is why so many folks are diving into the RP2350 because it's a whole entire micro-computer waaay beyond 'just' an MCU. Dual-core 150Mhz with almost half a meg of RAM to work with. With a couple dollar external PSRAM chip to give it ~8MB of memory you can run an entire Linux install on it even.
It's powerful enough to still be the 'brains' of something but has a bajillion powerful hardware I/O handlers for specific protocols and the much more generic PWM/PIO/HSTX pieces.
Even an Arduino uno at 16 MHz can easily output 4 MHz PWM. It’s just a task controllers with deterministic timing are better suited for vs a pi.
Then I'm pretty sure it's entirely suitable. The DFRobot brushless motor spec says 20kHz - 30kHz but we both know that motor specs aren't that precise, i.e., 500Hz won't make much of a difference. Okay, I'll give it a try then. It's certainly better than my other options.
...and yes, the RP2040 and now the RP2350 are very capable small computers. I've been partial to the STM32 but I've just recently started a robotics club at a local high school and have built an as-cheap-as-possible proposed club robot with an RP2040 Pico on it.
Hey, has anyone seen a USB-A male connector with built in micro SD card socket? I'm curious if I can source one somewhere without resorting to buying one of these to destroy it. It's been really hard searching for info on them. https://www.ebay.co.uk/itm/157033010908
What is the advantage of that one vs having the card plug into the back? That is not a pass through, right (there isn't a connector on the other side)?
not a pass-thru, I imagine that has a 1cm pcb out the back, but you could save a bunch of pcb space by using that dual connector, like a double height dual usb port saves space
I found this one on Aliexpress that looks to be the same type of thing. Plugs in the card from the back but from the photos (including customer photos) it appears the card goes well inside the USB connector so it doesn't protrude much out the back. https://www.aliexpress.us/item/2255799937950714.html
So you might be able to change your search a little to not specifically tell it which side the uSD card has to be inserted?
to be fair I'd take any way now you mention it, but a good idea to be specific, thanks
I just tried to search for "micro SD card reader flush" and that actually turned up a couple more options.
This is not quite what I want, because it looks like they've got the chip+pcb squeezed into the smallest form factor (partially in port). https://www.aliexpress.com/item/1005006956283299.html but only £0.80
On the otherhand this one is huge, and £1.80 but probably has exactly the combo connector I want:
https://www.aliexpress.com/item/1005008383932924.html
Is that extra £1.00 gonna break the bank? 😅
definitely not, just a question of how many I can face butchering, and whether I'll still have all the pins left 😂
I've got a few since they're so convenient, I actually prefer that style where you take the 'reader' out entirely to swap the MicroSD card, they're quite common on the US market and only a buck or two USD online usually.
They're all based on https://www.adafruit.com/product/6001 connectors, just swapping the 'spacer' out for a PCB that has the tiny adapter chip in the rear.
yeah exactly that, but wheres my SD pins. I'm just a bit surprised even with calling it TF instead of SD that a combo/dual thingy is so hard to find
Oh it's literally just a bog standard MicroSD connector soldered on one side of the USB connector riser with the metal housing replaced with the USB connector housing itself.
It's a case where the connector and parts and such are likely more expensive than just shucking the cosmetic shell on a cheap 2-pack type deal you can find for the MicroSD reader style on Amazon, if you're looking to repurpose it for a MicroSD you can stash in the USB port on a project instead of a separate MicroSD slot.
As in you'd likely have an easier time shucking than sourcing the raw parts TBH.
I had one of these going in from the back before at work, and the micro sd card goes all the way into the usb plug. Once they’re at that size, the difference is very small.
I've had difficulty getting anything out the TLC59711, ended up installing the CircuitPython support (Blinka etc., which I'd really wanted to avoid) and am now using the Adafruit TLC59711 library rather than Liriel's library at: https://github.com/Liriel/tlc59711.git
After beating my head against the monitor for hours I've fed back the output from R0 to GPIO 13 as a PWM input, and tried to read the PWM frequency on that pin. I'm seeing 800Hz, not 19.5kHz. Now this could entirely be my error, but I can't find anywhere that the fixed PWM frequency is 19.5kHz. Are you sure?
The internal oscillator runs at 10Mhz.
https://cdn-shop.adafruit.com/datasheets/tlc59711.pdf#page=18
That's where it describes how the PWM is segmented into 128 * 9-bit periods to support the instead of a single 16-bit period, the next page (page 19) shows an example waveform of output so you can see relevant examples of the '128 chunks of 9-bit PWM' it does and how it excludes a chunk to accomplish the global dimming and the chunks only vary ±1 PWM value to do the overall 16-bit PWM.
It's possible the library is setting the "EXTGCK" bit that's used for daisy-chaining multiple chips together in lockstep so it's using the SPI clock instead of it's internal clock? I'd need to dig into that code a bit.
The chip has no 'commands' really it just expects to be dumped data, it buffers 28 bytes worth and any overflow is passed out on it's SPI out port for daisy-chaining multiple chips together.
Then if there's at least 8 clock cycles worth of delay in the SPI clock it'll check if the 6 MSB are a key value (100101b) then it latches all the data into the current PWM registers.
If you can directly write SPI data try writing this out MSB-first then set the SPI clock output low and stop sending basically:
0x94, 0x5f, 0xFF, 0xFF, 0x80, 0x00, 0x80, 0x00, 0x80, 0x00, 0x80, 0x00, 0x80, 0x00, 0x80, 0x00, 0x80, 0x00, 0x80, 0x00, 0x80, 0x00, 0x80, 0x00, 0x80, 0x00, 0x80, 0x00
That'll set it to internal oscillator, full current, and 50% PWM on all channels, so it should be easiest to check the PWM frequency then since it will be 50% duty cycle on everything.
If you set it to full PWM brightness then the PWM wouldn't show up at the full frequency since most of the PWM blocks would be at 100% duty cycle then.
Thanks very much for the detailed description. While I was playing with it I noted data like that. Are all the 0x80 values for the different channels? As I'm currently just using R0, but will eventually want a total of four channels for four motors. And yes, I did try a variety of ways of just writing directly to the SPI bus.
For context I've worked with these particular chips off and on for years, they were one of my most common go-tos. https://imgur.com/qtVzcr6 That was back in 2015 about ten years ago.
16-bit values, so the 0x80/0x00 that follows is the 16-bit value, yes. 0x8000 out of 0xFFFF in effect.
I surely didn't expect to get into the weeds with this so quickly...
Well, I finally after many hours accidentally discovered what I think was the problem. I was hooking my motor's PWM up to R0 (OUT0), and never, ever even once got responses from the motor or the code, always returned zeros.
Then on a lark I tried one of the Adafruit examples from the docs online at: https://docs.circuitpython.org/projects/tlc59711/en/latest/index.html
The motor moved! I couldn't believe it. I have no idea why this is the way it is, but here's the code that works:
import time, board, busio
import adafruit_tlc59711
# define SPI bus connected to chip.
spi = busio.SPI(board.SCK, MOSI=board.MOSI)
pixels = adafruit_tlc59711.TLC59711AutoShow(spi)
MAX_SPEED = 65535
for red in range(0, MAX_SPEED, 100):
print('red: {}'.format(red))
pixels[3] = (red, 100, 10111)
time.sleep(0.005)
time.sleep(1)
for red in range(MAX_SPEED, 0, -100):
print('red: {}'.format(red))
pixels[3] = (red, 0, 0)
time.sleep(0.005)
# stop motor
pixels[3] = (0, 0, 0)
Note that it's pixels[3], not pixels[0] that makes the motor move on R0 (OUT0). I don't understand why but I'm not complaining. Relieved, mostly.
Oh... hrm I wonder if the library has the channel order reversed somehow?
But yay, it lives!
No idea. I've spent I think now six hours on this, I'm embarrassed to say. I'm now cutting out all the unnecessary code from the Adafruit library, from 1080 lines currently down to about 380. I'll then replace the CIrcuitPython stuff with spidev and make it entirely generic in that sense. But it's nice to finally see some brushless motor movement.
Honestly I generally controlled those chips directly myself with 'raw' SPI too, they're so simple with no 'commands' to do but tight timing requirements they're easier to manage that way, so yeah.
It's a bit frustrating to think that sometime during the day I might have actually had functional code but was likely pumping the data to the wrong channel.
I'd just arrange the 28 bytes in memory somewhere in the format the chip(s) expected and just blit them out.
Yeah... trust me when working with multiplexing/buffer chips you end up in that scenario more than you realize. One library counts in protocol order, the silkscreen might count in pinout order, etc.
I haven't figure out what this class is actually doing, but apparently pixels[3] rather than zero was the ticket...
class TLC59711AutoShow(TLC59711):
"""TLC59711 16-bit 12 channel LED PWM driver with Auto-Show.
:param ~busio.SPI spi: An instance of the SPI bus connected to the chip.
The clock and MOSI/output must be set, the MISO/input is unused.
Maximal data clock frequency for the TLC59711 is 10MHz
:param int pixel_count: Number of RGB-LEDs (=Pixels) that are connected.
"""
def __init__(self, spi: SPI, pixel_count: int = 4) -> None:
"""Init."""
super().__init__(spi, pixel_count=pixel_count)
def __setitem__(self, key: int, value: Tuple[float, float, float]) -> None:
"""
Set the R, G, B values for the pixel.
:param int key: 0..(pixel_count)
:param tuple 3-tuple of R, G, B; each int 0..65535 or float 0..1
"""
super().__setitem__(key, value)
self._write()
I would think index 0 would be red, or R0. But noooooooo
That's literally just creating the 'array' of pixel values and setting the SPI details associated with them.
Oh, I understand that, it's just that I'd have thought that index 0 would be the red pixel or channel R0/OUT0.
And yet: pixels[3] = (red, 0, 0) was what worked.
It should be, I'm wondering if it's a bug in that library that hasn't been noticed since nobody reported it before now.
Since yeah if you're wired up to R0 and you had to set pixels[3] = (red,green,blue) instead that's a bug I think.
Nobody has tried to use this board to run the new DFRobot brushless motor perhaps.
I don't think most folks have used a fifteen-year-old LED management chip on CircuitPython rather since there's NeoPixels and DotStars these days.
The library was written by two guys, copyright Adafruit, so I'm assuming they're employees.
And setting 'all channels to rainbow' type tests would work, nobody verified the channel order.
Oh... wait, I think I see what's happening.
Rummaged around, and yeah it's inverting the pixel order because it's using a simple buffer matching what it sends on the wire... but the chip has OUT[RGB]3 as the first channels on the wire, then 2, then 1, then 0 is the fourth ([3] in array terms) one, they likely noticed the RGB order and fixed it to match the buffer but nobody spotted that O0 = [3] and O3 = [0]
Until lil' ol' me.
Oh well, I'm off to the races now.
Thanks very much for all the info, was very helpful. And faith that the PWM frequency was compatible with the motor, which kept me going.
Yeah, there's two ways the AdaFruit library could be fixed, either re-arrange the channel order it pre-calculates in _init_lookuptable or they'd need to touch several set_pixel_* functions to xor the pixel index with 3 before the lookup.
As my requirements are simply to use four independent channels to control four motors rathern than RGB LEDs, my code will very quickly diverge from the original library.
Yeah you'd likely be better served using the 'channel' based instead of 'pixel' based functions, but at that point since you'll only use a single chip... might as well just make the buffer of 16-bit unsigned integers once, and just chuck that over SPI whenever you need to update the motor speeds, then 4us later the new settings kick in, done.
BTW, just out of curiosity I thought to find out where the other "red" channels mapped to, not a surprise but FYI:
# name channel
# R0 3
# R1 2
# R2 1
# R3 0
Since I only need four I'll just stick with red rather than deal with the green or blue.
Created an issue for it so it can get fixed in time for 10.0 maybe?
I mean they'll all be out-of-order in the same way, pixel[0] = (0.25,0.5,0.75) would assign R3 = 0.25, G3 = 0.5, B3 = 0.75, but it does also spread the pins around the breakout so it'll be easier to wire possibly.
So long as it’s documented, but fixing it is better of course
I just finished my motor controller for CPython on the Raspberry Pi: https://github.com/ifurusato/brushless-motor-controller
This motor controller includes support for open- or closed-loop control, stall-and-recovery, deadband control, and control by target RPM when operating in closed-loop mode. Given a wheel diameter this also provides for odometric distance and speed measurements. There are three PWM controller implementations: software PWM, hardware PWM, and using a TI TLC59711 PWM controller.
What could go wrong on this circuit when D8 is reversed?
if the circuit is powered from VBUS, it won’t work. if not, it could backfeed power to the host or hub port, possibly damaging it
Thank you!
The USB post on my SBC was protected from damage from this circuit by the USB hub.
hi! I've been revisiting a project I had for a while but never knew how to case it.
I've been learning a bit of KiCad to draw the schematics, but before attempting to draw the PCB I'd need to think about the casing.
I don't have 3d printing stuff or friends into it. I wonder if I should place all the interface parts in the top, and maybe the chips at the bottom? in 2 layers.
the thing with the components is that they have many different heights to laid in a front panel and share the same plane in the pcb.
I have the repo here, with a video https://github.com/redraw/euclid-16
any idea is welcome 🙏
Consider header sockets mounted 'upside down' on the upper board, then you can click the pico directly into the socket without needing the second board on the bottom, and just cut some (NON CONDUCTIVE!) padding to fill out the bottom of the case to taste? https://www.adafruit.com/product/5583
When it comes to panel design, I like to start with cut holes in cardboard or card stock, just to get a feel for heights and component layout. If that works well, project boards and boxes are available in a number of materials, and most of them can simply be cut with a drill and dremel.
Also, for a pi pico, there’s always the option to surface mount it for a pcb to save on height for header pins.
good idea testing in cardboad, a thin firm cardboard. yeah, might get some project box
I'm building a matrix of switches and want to simulate it before making the errors physically. Do you guys have any recommendations when it comes to circuit simulation software?
Maybe Falstad?
I'm so confused…
I have an existing light fixture based on an LED strip, and was hoping to add "smart"/wireless controls to it and possibly dimming capabilities. The light is connected to its power supply with SM JST connectors, so I bought some to attach to my controller and intercept the power delivery. I did this, but discovered that the transformer seems to whine even when 100% on (vs PWM).
While troubleshooting different scenarios, I decided to just solder two of these connectors together (essentially just a 30cm extension cable) and…it whines when I use that but not when connect directly. 😵💫 What is going on here? I can't imagine the cable being 30cm longer is the culprit.Might this be an issue with how well the connector is making contact? Or the gauge of the wire? The male side seems to be essentially physically identical, and as far as I can see inside the female connector, it's identical as well. Could it be an issue of the wire gauge? The external diameter of the wires seems to be the same, but it's theoretically possible that the insulation is thicker and the inner conductor is thinner.
I was hoping to stick with using connectors so this is easily reversible if need be, but do I need to resort to snipping and soldering?
@wheat notch how about here for solderless connector discussion. it's broader than NeoPixel connections
to summarize from #circuitpython-dev message
would like solderless connectors to NeoPixel rings, etc.
Wemos form factor requirement
More specifically, smaller connectors, typically on pigtails. There are already a few Adafruit products like the Prop-Maker FeatherWing and LED strips using JST PH 2mm connectors.
The Adafruit Feather series gives you lots of options for a small, portable, rechargeable microcontroller board. Perfect for fitting into your next prop build! This FeatherWing will unlock ...
but I haven't found any consistent sources for NeoPixel PCB Rings / Sticks / Grids etc with a pair of similar connector pigtails except occasionally the JST SM 2.5 mm connectors which are fine if you're running strings or flexible strips with dozens of LEDs, but a bit bulky for hiding the wiring to something like an 8 LED stick (which will fit through am 11x4mm hole - less than half what you need to squeeze the 3pin JST SMs through)
You're looking to make some custom one-offs with these things, or hoping to find something already made/sold in bulk with smaller but standardized connectors?
If the pads are on 0.1" spacing then I have found straight and right angle surface mount headers to work well enough for this kind of thing.
On the outward facing ones regular straight headers work fine...
On the right angles ones work great for turning them inward so your connector plug in under your board. Example (not soldered, just threw a header on the board to show an example)...
On one project I did I have two panels side by side and used the inward connectors to hook them up like this...
Only problem is the connector now cover the pin legend so make sure you take a photo or have another board to remind yourself which side is 5V and which is GND. The "Dupont" type connectors are typically rated for up to 3A so should be plenty for 8 LED strips and the like. These are two 64 LED panels, but I am running them at only about 20% brightness so lots of headroom.
If you plan for it a good idea is to 'key' the connectors then to have...
🔴🟡⭕⚫ (the hollow ring meaning a 'gap' in the pins and fill the corresponding pin in the 4-pin plug with a dab of glue)
...instead of...
🔴🟡⚫
...for example. Takes an extra 0.1" of space and a bit of work pulling the 'gap' pin out of the header spacer before soldering together but it can be a lifesaver not having to remember the now-hidden pinout label.
Sorry, should have made that clear... I'm looking for a source (bulk would be great) to buy a variety of NeoPixel/WS28128b PCBs with pigtails already attached. Ideally JST / Molex PicoBlade 1.25mm pitch connectors with red/black/yellow wires
as in the picture above. I've been personally using these for years in smaller projects, buying the cables and soldering them to the PCBs myself (occasionally even crimping connectors on my own custom cables). Even experimented with a variety of ways to speed up the process, like custom cast silicone blocks to hold the PCB with slits to hold the wires in place.
However, I want to find a source for something similar that people who don't want to solder can use.
The main goal is to add NeoPixels into a set of extremely beginner friendly "plug and play"-ish options suitable for people who would be too intimidated by anything requiring soldering, programming, etc. to even try.
Doesn't have to be the JST 1.25 connectors I've been using (although that would be ideal for me), but there are some requirements:
- small (anything with 2.54 mm pitch is way to big, even JST PH 2.0mm is chunkier than I'd like)
- but not too small - reasonably easy to connect, durable, and able to handle enough current for a modest NeoPixel chain
- not already in wide use for any other purpose - don't want anyone plugging NeoPixels into a StemmaQT socket
They do make a single-pixel Neopixel that uses the 3-pin JST connector since that's safely compatible with Neopixels. Power, Ground, PWM Signal, so worst case you do nothing to the neopixel and if you plug it into something else you'd just get a weird PWM-ish signal from the neopixel 800khz waveform.
And yes that's the 3-pin Stemma socket, which is available on quite a few boards to directly connect to without needing to do any soldering.
My primary initial goal is reducing the perceived barrier to entry for adding interactive effects to tabletop gaming terrain. There are a lot of creative, crafty, artistic terrain builders whose technical self confidence barely covers 3D printing, much less soldering or complex programming. I want to be able to provide them with some guides and a curated list of ready to buy options they can just plug together without worrying about soldering, polarity (oh yeah, forgot the connector MUST be keyed/polarized) or installing an IDE and learning how to write embedded control logic.
And they do make other form factors of the LEDs like that using the same 3-pin Stemma/JST PH connector.
JST PH 2.0mm is bigger than I'd prefer, although I'd probably be willing to bend on that if there were a wider variety of NeoPixel PCBs available with the sockets or pigtails already on.
There's individual LEDs that daisy-chain and a few different types of strips of coated LEDs, covers a lot of costuming/prop options that way.
If I'm reading correctly, that single NeoPixel PCB is JST SH 1mm 3 pin (although the controller in the picture uses a larger connector)
JST SH 1mm could work, but...
- its a liitle smaller than I'd prefer (not nearly as big a deal as the PH 2.0)
- could cause confusion when used together with StemmaQT/Qwiic (which is a HUGE part of beginner-friendly hardware recommendations) since they use the 4 pin JST SH 1mm (different, but not enough to keep people from trying to plug a 3 pin plug into a 4 pin socket, and it doesn't take much to bend those pins)
Still, these are rather minor issues. The BIG problem is availability - finding a source people can buy these from.
I have done very few (more than zero of each, but) projects which added NeoPixels to costume & props, so maybe single LEDs and flexible strips might cover most of what people need there. But for gaming terrain projects, the are several NeoPixel PCBs which I'd consider nearly indispensable. Certainly the ubiquitous 8 led sticks. And a variety of rings & grids comes in very handy.
FWIW it wouldn't have to be every possible variation - the goal isn't to make everything possible without bothering to learn to solder, just a wide enough variety for technically intimidated makers with creative ideas to see enough beginner friendly options to think "I can do this"
Basic soldering - enough for adding pigtails to NeoPixels - doesn't require a lot of expensive kit or years of practice, just a bit of instruction on proper techniques. I suspect that if these were available, some (many?) people who used them to get started would find their intimidation over soldering irons, breadboards, and the like fading away, and be far more willing to give it a try on their next projects. But that's just a guess, I could be wrong.
The problem with going smaller than that is that a lot of neopixels can draw quite a bit of current, and the smaller wires could be a weakness in that regard. If you want to keep the chaining ability of these, I don’t think you should go too small…
In theory you're absolutely right, the JST1.25 connectors are only rated up to around 1 amp. In practice I've often run 50+ chains, which in theory can draw up to 3 amps, without ever having any problems. That said, for the 50 LED WS2811 strings on my Christmas tree I'm using the full sized JST SM connectors with extra power drops and caps per run for the 1050 LEDS over 7 channels I've got connected to a 30A power supply...
And I'm considering adding some safety logic to my framework which would estimate the required total current on a NeoPixel channel and proportionally auto-dim if necessary to keep it below a configurable max. I don't ever recall doing anything silly like setting every LED in a 50+ string to 0xFFFFFF, but I could easily imagine a beginner getting curious about how bright they could make their project.
Current handling was a big concern for me back when I started trying out different options (long before I cared about finding pre-soldered options) and I was a bit skeptical about the JST 1.25mm, which is part of why I've been using and abusing them for years. I'm mostly convinced that they're "good enough" for the vast majority of projects out there using single and solid PCB NeoPixels (strings and flexible PCB strips, not so much...). Particularly in my "target market" where most projects are running off batteries or small USB power supplies that couldn't produce 3A if they wanted to. Even so, I'm sure if these got into common use, someday someone will find a way to let the smoke out, and I consider it a "con" for the 1.25 vs the PH 2.0.
I don't recall ever running across any prebuilt "Neopixel" PCBs with preassembled pigtails. The main problem and why you won't likely find this is that PicoBlade 1.25mm connectors are rated for only about 1A MAX so adding pigtails would only be appropriate for LED assemblies of about 16 LEDs or less (assuming a worst case current draw of 60mA per LED) . The ones in your photo fit that description, but many vendors of these are likely to make other larger sized assemblies it is simply easier to just offer them with solder pads.
Also the LED assemblies themselves can all be built automatically with pick and place machines and no human labor at all other than loading the machines. Start adding pigtails and the human labor costs really cut into your profits.
You'd need one female + one male to keep the chain oriented (really nice that you DON'T need to worry about this with StemmaQT) and SMD female connectors seem to be a lot less common in smaller pitches, but that should be manageable. I wasn't aware that pigtails aren't easily automatable - maybe the crimping is, but I can see soldering a wire to an SMD pad being more challenging. And I guess if I were a vendor looking at these being used in general, I'd be less comforted by "don't worry, nobody in our little slice of your market will ever actually exceed the current limits ... probably..."
You can find prewired WS2811x PCBs, but the only connector option with much variety is the JST SM 2.54mm connectors - same ones used for full sized strips.
That's actually a quite helpful trick - I've used it occasionally and it's quite a bit easier to solder a header on then three squirmy stranded copper wires. And there are a lot (easily >90% on the many I've tried over the years) of NeoPixel PCB boards with 0.1" / 2.54mm spacing on their SMD pads.
Some of the "cons" given my specific application is
- it means larger connectors, although Dupont and servo style 3 pin connectors are still pretty compact
- it needs to be keyed/ polarized to make sure power lines are in the right place and the data-in / data-out stay in order
- rules out a lot of common options like keyed servo connectors - at least for both sides
- makes it harder to keep things compact
although if you could find 0.1" 3 pin "combo" headers with 1 male + 2 female and 2 male + 1 female, I think that could keep both polarity and data orientation in line?
So I caught myself "doing that thing again"... I'm pretty passionate about finding "optimal" solutions, but I have minimal personal needs for acclaim and a high tolerance - even appreciation - for constructive criticism . But that seems to be an unusual combination, which has caused some problems in the past. When I get in conversations like this and start getting engaged, competent feedback, I tend to forget that while I might appreciate and even enjoy 90% of the feedback being "no, that won't work", that's not normal. And the more competent the feedback, the more I likely I am to get wrapped up in "progress", forget about "people" and end up with my side of the conversation becoming predominately negative, especially for things I've been pondering and tinkering with for a long time.
I've learned to recognize this over the years, and I usually manage to provide more balanced conversation - particularly when I sense opportunities to be helpful and maybe do a little mentoring. But sometimes I slip a bit. I just want to make it ABSOLUTELY clear that the significant proportion of "no that won't work"-ish commentary from my side of this dialog was not in ANY way meant to imply I didn't appreciate your feedback or considered myself "smarter".
Actually it's the opposite - I've already considered and or tried many of the things you suggested, so while I might have filed them in my "nope, that didn't work" bin, hearing those suggestions made me feel like 'hey, I'm talking with someone who gets it" which makes me more excited about the potential about make some progress beyond what I've figured out so far.
So actually its your fault, if you hadn't provide such insightful feedback I would have replied in a more calm and balanced manner... Just kidding. Mostly...
Look similar to the ones PiMoRoNi use for TinyFX, but they have two sizes of connectors on the TinyFX-W, the jst 3pin, for "sensors" (I used as neopixels), and then their super small LEDs (normal and RGB common cath/anode) using JST-SUR
I was able to buy the tiniest neopixels known to humanity pre-wired, but they were custom done at the factory for one of the employees who sold them on aliexpress. Said they closed their "store" but to contact any of the salesmen at factory for similar requirements, pretty sure they'd do your neopixels with any connector. https://czinelight.m.en.alibaba.com/
W.LED has that feature (max current of strip) built in, worth having a look if you haven't already
Smaller than 2020s? These can be wired instead of surface mounted : https://www.adafruit.com/product/4684
Not easily mind you, but I'm no soldering pro and I've managed to make it work.
Haven't tried hand soldering 1515s, but I have a few in a bag somewhere.
[WLED])(https://kno.wled.ge/) looks pretty slick - that's an impressive amount of functionality to squeeze into an ESP8266. Not sure how close I'll be able to get to everything they're doing with CircuitPython, at least without some custom compiled C/C++ extensions to speed up the math. When you start mixing overlays, current capping, gamma correction, group / subgroup brightness controls, etc. calculating the final RGB value for each NeoPixel adds up - and that's before remapping 2D/3D effects on a random set of LEDs.
they "looked" hand solderable, but my goodness I'm glad I didn't even try and just searched for pre-wired
also for esp32 as well as 8266
I don't do a lot of SMD, had to actually look this up before I realized that 0807 doesn't mean 0.8x0.7mm - that would be ludicrously tiny... It appears that at least for one example I found an 0807 is only slightly smaller than a 2020 and larger than a 1515?
I still use ESP866s to keep dust off the bottom of some of my parts containers.
I honestly lose my mind after the largest two smd sizes
Very wise! Also a good reason to use WipperSnapper (no-code iot platform/firmware)
I occasionally want REALLY small accent lights in some of my projects. That's one reason I'm so fond of the PCB sticks with 8 5050 NeoPixels on them - I can tuck one away in an interior space and 3D print some shrouds to funnel each LEDs output into an optical fibers(s) In some cases it makes routing a lot easier than wires. One fiber instead of four wires per "light", star instead of ring distribution, and MUCH easier to bring pinpoint sized lighting through to the surface.
I'm actually building a no/low code system in CircuitPython. There's certainly some overlap between my projects and WLED or WipperSnapper, and it may not ever match them feature for feature, but I have some different goals that AFAIK are outside the scope of what either of them are doing.
Interesting, what's on your must have list?
Also, wippersnapper is moving to v2 currently, and there is a python version for that (which I'll be making circuitpython compatible eventually).
First and foremost, I want it to allow non-programners to create ineresting, non-trivial interactive effects (lights, audio, motion, ...) without "learning to program" in a traditional manner
Wippersnapper in CircuitPython would rock... Only heard about it recently, and haven't tried using it, but the ability to "extend" it for more complex stuff in CircuitPython instead of C/C++ is a game-changer IMHO.
Don't get me wrong - I love C++ too, and I've built some substantial Arduino/ESP-IDF stuff. C++ and Python combined is even better - I've been using them together (i.e. Python interpreters embedded in C++ applications) for over fifteen years. But that's not necessarily beginner-friendly on the C++ side.
I had started thinking about trying to embed a full-blown Python interpreter in C++ firmware for one of the monster ESP32 variants, like an S3 with 8MB PSRAM, but I decided I ought to try CircuitPython first (for a variety of reasons) after which I put that idea back on the shelf for a while.
