#help-with-hw-design
1 messages · Page 12 of 1
Lots and lots of single cell BMS boards available on eBay
Might take a month or two to get from China… but they’re there and cheap
Orrrr hear me out.. https://www.adafruit.com/product/1904
That’s just a charger tho — won’t help with overcurrent/undervoltage on discharge
LiPoly BFF is the full management package, but it’s also good practice to have a BMS on the cell
Mcp73831 has built in charge protection
Is that what’s on the MicroLipo? That’s only a charger tho
But the cell won’t have overdischarge protection still
Most lipos cut off at 3V
Are from supplies you probably shouldn’t trust anyway and should avoid
Or they’re raw cells meant to be used with a BMS
Modern and reputable LiPo suppliers can very cheaply add them.
And they regularly do
You don’t really need raw LiPo packs unless you’re building your own multicell setups
I use recovered LiPo cells from laptop batteries, which don’t have individual protection, just a shared BMS… maybe they’re doing the same?
Actually… @summer pier were you just looking for a small charger? Or do you want to have battery management as part of a larger project?
It’s either a single cell or a parallel cell battery based on the voltage given
Yeah. But there’s the question of if they’re trying to add battery management into a board, or design their own version of the MicroLipo, or protect a raw cell that lacks overdischarge or what
Harvesting LiPos from old laptops does get into the “don’t try this at home” category of fun lol.
In all seriousness, batteries (especially LiPos) are dangerous and should be treated like they could explode for no reason
Like my emotional state
Usually exploding into tears but that’s besides the point
Mood
Even inside of commercially available consumer products.
I’m looking at you, Samsung.
Though in all seriousness, I prefer to compare them to gasoline. Similarly hazardous, but it retains its utility if you think about how commonplace it is in modern society.
Yeah, very true
Like with high voltage AC… very dangerous if you aren’t careful. With knowledge and care, you can stay safe
I'm wanting to build a single board "simple" metronome that can run off a 3.7 lipo w/ a header for an oLed display. I'm thinking of going w/ a pico simply because it'd be easier for me to code - but I think I'm already in over my head
So yeah, a bms would be nice so it didn't over discharge
Ahh, gotcha. Well, if you go with something like a Feather, it has built in battery management; if you’re using batteries from the Adafruit store, they already have overdischarge protection built in as well. And the Feather line is CircuitPython compatible, so easy to program, and there’s even an RP2040 version
Cool thanks! 🙂
@summer pier a common protection chip is dw01 you can buy prebuilt tiny boards or chip itself and can combine with a charging circuit
I wanna make a USB that is actually a Linux SBC that runs GPT-J. I have a 16GB LPDDR4 RAM chip selected, but I need a processor and a storage medium. I was thinking of using an ARM64 processor and using an eMMc chip. Could anyone help?
You want to design your own miniature single board computer in a usb device?
Basically something like this? https://learn.adafruit.com/turning-your-raspberry-pi-zero-into-a-usb-gadget
The typical way would be to go to https://www.digikey.com/en/products/category/embedded/2012 and select a microprocessor/SoC IC or module, and use an appropriate component as the core of your design. Designing a board around a RAM chip makes little sense in the bigger picture, as it’s much simpler to select a RAM chip compatible with your processor, rather than the other way around.
So something like this?
https://www.digikey.com/en/products/detail/nxp-usa-inc/LS1012AXE7KKB/8134995
Yes, but that looks wayyy overkill for your purposes
I am attempting to run GPT-J, so I thought that this processor would be good. I haven't been able to find much info on how to run GPT-J, besides that using arguments and float16, you can minimize the RAM required from 48GB to 16GB.
If you’re not particularly clear on the technical requirements for your application, it’s best to start with a preexisting single board computer and evaluate your application that way. You’ll save a lot of time and money compared to jumping straight into custom hardware and iterating tens of times…
So I just find an existing SBC that has at least 16GB of RAM? I'm assuming that the model only needs 16GB of RAM to load itself, and actually running it doesn't need much processing power.
Why not run on a Jetson Nano or something?
I want to be able to plug it into a computer's USB port and it'll run. I may also have it emulate an HID, but that depends and doesn't matter at the moment.
Why not 2 separate devices? A simple mcu acting as hid, communicating with a computer running gpt-j as starting point
Watch out for USB power limits. A RasbPi4 can suck down 3A or so.
Max power draw, nominal is closer to like 700mA or something like that. Still 200mA over my 3B+ though lol
I take that back, they’re idling somewhere around 600mA
This 60W charging hub works perfectly for running Pi on
@distant raven charger with display , nifty !!
It’s a Chinese white label product I found on Amazon. Seems to work well enough
@distant raven i have a RP3B+ , i want to use to run a greenhouse ( simple setup ) , a power backup and solar panel would be good to use - exploring ideas
Ah neat, raspberry pi are great for niche applications like greenhouse management
i also want to have a indoor hydroponics so i can have cooking herbs freshh all the time
Oh nice!
some systems have so many sensors - it may not be necessary
Depends on what you want to achieve with your green house
i dont know about plant nutrition - so PH sensor may not be useful now , however can manage water and temp , add sensors as i learn
i think starting with automated irrigation should be the first step, everything else does not bring much of an advantage if your not a professional horticulturist
but can be fun nevertheless
adaptive lighting might be fun and maybe necessary for indoor setups
front room window will do for now , maybe use a light sensor to plot light , temp , then individual moisture of plants
hmm open to ideas
what kind of plants you want to grow?
invest in quality sensors, if you want to be more serious about it. they might be expensive, but cheap sensors do not produce reliable data
cooking herbs , fresh cilantro would be nice
at first i would be using dirt - potting soil , small scale
well, that does not sound to complicated
i have seen real hydroponics setups , and the plants died becasue no water for 3 days
growing them in soil or other substrate provides the advantage an some kind of puffer for moisture and nutrients 😄
well i did get ( free ) 2 old sprayer pump mechanisms , from .... ROUNDUP.... sprayer ...... may not use at all
hmmmm - open tiny solenoid - water drip sounds safer
ROUNDUP like in herbicide?
they might no be very use full for GROWING crops 😂
well wondered.... if i can pump massive amounts of water or a leeching fluid ) throug pump to clean it
slow drip - i have seen that here and there
drip irrigation with a soil moisture sensor is not that hard to build and program (you just use a threshold)
use influxdb for data storage, grafana to display data and maybe node RED and mqtt for control
was considering one plant and use a comparator and timer / x , to turn solenoid on
you mean a valve?
making notes on suggestions
ya , ultra simple at first then learn the pros/cons along the way
if you want a quality moisture sensor try this: https://pino-tech.eu/product/soilwatch-10/
water sensor - 2 pieces coat hanger and alligator clips and speaker wire to DVM to look at it
if i can see a pattern maybe just a comparator
when dry --- beep
dont know the feed back loop to water - i imagine overwatering a plant easy to do
depends on how reliable this is
my water sensor for now is my finger - want to update
easiest setup: have soil moisture sensor, read its value periodically (every 5 min or so) and see if moisture is below the threshold. if its not, do nothing, if it is, then open valve / power pump / whatever for a fixed amount of time. you might be going well over the threshold, but that is not bad, as long as there is enough time for the substrate to dry below the threshold before the next irrigation cycle happens
i have a 17 yr old orchid - i dont trust to automated watering
i would not trust that to a computer haha
i have a bunch of aloe vera i , ignore them - seem to do well
irrigation time muss be lower than sensor read intervall of course
low sample rate to allow - water to drain
they like it dry, dont they? 😄
aloe vera love crowded pots -- one vera in a pot withers
nah, as long as you are above the threshold, you should be adding more water. you should still read you sensor value
hmmm wondering..... have a data logging setup - then i do the human thing by hand - and refer to data to see if anything
hmm i can imagine - many configurations of water sensors , besides 2 coat hanger bits
humidity does have a correlation
and temp
i dont quite understand what you are trying to say?
i have a habit of making it , overly complex - im trying to simplify
pino tech , 75 Mhz - its a ANtenna ?
the water in the soil changes the permeability arount ANT ?
ohhh capacitive
its for arduino
might be c, might be c#
there are also other professional sensor, but the are waaaay to pricey for a hobbist:
https://www.metergroup.com/en/meter-environment/products/teros-12-soil-moisture-sensor
https://www.truebner.de/de/smt100.php
10 bits = 1024 ADC
yea, should be enough. I use mine with 16 bit adc i think
thats a new sensor - i wanna take it apart
3rd electrode is a ? , is this still capacitive
70 Mhz........ something
Hi All, couldn't find exactly the correct channel to ask, but this one seemed to be the closest.
Can anyone tell me what this type of interface connector is called?
I think that’s a mezzanine connector
Thanks for the lead, I think you're almost right. Mezz connectors ( IEEE 1386 ) appear to have the contact pins symmetrically mirrored.
A quick search and I haven't been able to find a mezz connector with those triangular keyed edges, and offset pins
Hmm… might be proprietary
That looks like a TPM module from a PC? A lot of the ones that don’t use regular 2x(n) 0.1” headers use proprietary connectors so you can’t just use any module
You're spot on there! It's a TPM from Tyan and I cannot find a supplier anywhere, so I was going to make my own "translation" board so I could piggy-back a TPM from another OEM
The pin-out for the Infineon TPM over SPI is super simple. The OEM's make it difficult to lock you into buying their AICs
I find the situations with TPMs to be infuriating... But personally I'm disabling fTPM on my devices that have it and not putting TPMs into ones that don't so Microsoft can't "accidentally" "upgrade" my computers to 11
The second the “accidental” upgrade happens I’m moving to Linux Mint
🤣 fair.
I'm building a new NAS and wanted to try out systemd's relatively new measured boot, cyptysetup auto unlock
Can't happen if the computer isn't compatible 
Yeah true
Ahh... that's fair
At this point I think I'll just test it out with my YubiKey
I need to disable fTPM at some point
I have a YubiKey for work, seems to work great
I disabled fTPM on my systems as soon as I found out Windows 11 had a TPM requirement
I know, which is why I don't wanna use a Pi. I can't even use it because it doesn't have energy RAM to load the model.
Same. Also Apple has enabled 3rd party FIDO2 (aka Yubi) associations on AppleIDs. So that's helpful when you don't want to get locked into PassKeys
I see what you mean. For example, The Linux on the USB could output GPT-J's output over UART, and the MCU could take that and output it over USB as keyboard input.
Apple doesn’t support hard tokens for MFA windows connections though which is sad. Not through the Microsoft RDP app anyway. You have to use some kind of VDI client like Citrix which is a pain
Yup! I know that pain also.
And Microsoft broke but won’t acknowledge they broke RDP on windows 11 with it randomly switching to UDP when my employer’s servers only allow TCP/IP sessions
It was kind of broke in 21H2 but then broke broke in 22H2
Found that out the hard way
And THAT kind of random crap is why I refuse to implement 11 in my environments
Same.
Working on a design for a PCB that powers some 24v fans (one of them is a bit of an odd fan) and some thermistors for a project I'm working on. It's meant to run on a kb2040/rp2040 pro micro/Boardsource blok. Before I get much further with the design, was hoping someone could spot check any obvious mistakes. First time using kicad, and not super familiar with electronics, but that's never stopped me before!
Looks good, but what’s going on with the weird zener thing with PWM on the roborock fan? (Also, it seems like you called Schottky diodes Shockley diodes (after one of the inventors of the transistor))
Could this do for the processor I'm looking for?
https://www.digikey.com/en/products/detail/nxp-usa-inc/MIMX8MN6DVTJZAA/10669045
Well, the usual reply to, "Is this 500-pin, gigahertz chip what I want to use?" is: "If you're even asking that question the answer is 'Oh god, nope nope nope!'..."
That thing has some insane specs and is extremely pricey
I would use something where you won’t have to brew your own VRMs, high frequency length-matched, loop-optimized, high frequency traces, a 12 layer PCB, and your own software support. And I can imagine soldering that thing will be a nightmare.
I would just get an SBC that has the specs you need. There are some powerful pi alternatives out there.
And it doesn’t seem to have a datasheet
I was tired when I wrote that. Felt wrong haha. The Zener thing for this. https://github.com/condottab/Roborock-CPAP
CPAP as in the therapy for sleep aponea?
Boards would be expensive, you could probably do 6, maybe 8 layers at most with via in pad and 3/3mil trace-spacing.
Length matching isn’t terribly difficult, just time consuming
Yup. Repurposed for 3d printers
Get the ones with the open patterns on the bottom of the die
By doing a low side mosfet switch on the fan, you won't have ground tied to that pwm circuit when mosfet0 is off. Could be an issue.
I'd tie it to gnd, not mosfet0/-24v.
Your motor snubber diode is wired wrong
Motor snubber diode?
The schottky, should connect across the motor leads, pointing up. Also known as flyback diode.
Its wired in series, no reason for that. The github link shows it wrong too.
It PWM's on GND and has to PWM along with the PWM signal due to how the fan board that connects to it works. It's intentionally disconnecting that for reasons that the designer of that bit of the circuit understands that I don't.
It fails when not switched, that's the extent that we know.
Your board has the luxury of a full time ground. Condotabb is applying some band-aids since his gnd is coming and going with pwm. When his pwm is off, everything tied to gnd will float up to 24V hence all those zeners and schottky diodes.
Plus he is bringing in a pin from a motherboard without a ground reference.
I'm guessing the motor needs a 0-5v pwm signal.
I forgot about flyback diodes. I'm not sure if brushless fans have them integrated (with the little controller IC), but it's good to have them so inductive current spikes don't kill your mosfets. I'm not sure what current rating to go for, but I would go for diodes with a continuous current rating of the current you're running the motors at to play it safe.
Diodes just need to handle the flyback spike, add a resistor to help clamp it, but a few amps should be fine, size up if it pops.
You will need a 5v regulator and a level shifter for the pwm. You need 3.3V, not seeing that in your schematic.
It's coming from the MCU
I've got a flyback on one section. I'll apply it to everything. Thanks.
Electrically it won't matter, but if you care about adjustment direction being CW vs CCW, it will.
How dangerous are LiPo batteries? Are they more dangerous than phone batteries?
Phone batteries typically are LiPo or Li-Ion
Phone batteries are typically also LiPo, so pretty much the same, give or take packaging and protection circuits. There's a spectrum of dangerous depending on the current rating, too... high-power LiPos designed for drones and airplanes can put out a lot of current.
And puncturing is bad regardless of capacity
Toxic fumes, fire, etc.. are common dangers of mishandled Lithium batteries
“Dangerous” also depends on what you mean. Aforementioned toxic fumes and fire are going to be similar risks between a phone battery and pouch style cells if both are safely inside a device. 18650 or solid cells like those are a bit more resistant to damage, but equally likely to burst from a short without protection.
So something like Adafruit's 400 mAh Feather-sized battery inside an enclosure connected to a Feather is as safe as a phone?
It will be inside an enclosure of some kind (I haven't decided how to build the enclosure yet, but it will have one), and a short is very unlikely because it will be connected directly to a Feather board.
It will be protected from punctures
Why would someone do that‽
It’s relatively safe then. Just always remember to treat batteries with respect and care. Don’t leave your project in the sun!
Okay, I'll do that. Would carrying it in a pocket be okay if the case is sturdy enough?
That’s hopefully fake, but some people have no idea how dangerous punctures are, and might want to see what’s inside…
Mhmm, if it’s nice and safely enclosed, it’s safe as a phone
I watch some RC channels and the cavalier way they handle LiPo batteries CONCERN me
Okay, great! I'll definitely be careful, but it's nice to know my ham radio pager won't randomly explode.
Chances of random explosion are about the same as any phone, generally — so unlikely
Make sure any battery you get has the appropriate protection circutry, some very cheap ones dont come with it
the adafruit ones do obviously
I'll be using Adafruit batteries
Good call, i bought a cheap one off ebay and then found out that it needed the circuit, by the time i bought and installed it i paid more than just buying the adafruit one -.-
If you watch Bigclive on YouTube he's got the explosive battery containment pie dish.
What is the best way to put a power switch on a Feather with a LiPo?
I'm fine with soldering
Are you simply looking to turn off the device as a whole?
Yeah, to turn the whole thing on and off
Behavior when the switch is turned off with USB connected doesn't matter
You can wire a switch between EN and GND on most boards
The en pin going to ground would turn off the regulator
So the switch would actually go "on" to turn the board off?
Right
Okay, that would be fine
hello friends! i'm super new to hardware design (i actually... don't know almost anything about circuits, even though i fab them for my internship). what i'm looking to do is to create a programmable LED matrix for a thomas bangalter daft punk helmet. are there any recommendations on what I should buy? having the display be see through is very, very helpful, but if there's no good way to do it, i could always be fine with not having that
Is there any power consumption when the board is off?
You could still charge the LiPo but you’d turn it off to use the microcontroller with usb
Turning the regulator off should just leave you with a small amount of quiescent current
So the LiPo would charge at either setting?
Right
Okay, a small amount is fine
The LiPo charger will also leak a small amount as well, maybe a few dozen uA
What would happen if you plugged it into a computer with the switch set to turn the board on?
So if the switch was open?
Yeah, with the switch open
The regulator would turn on when it got USB/battery power
So when it's connected to a computer or other power source by USB, the setting of the switch wouldn't matter?
No it’s going to matter
The regulator powers the micro
So if it’s not enabled you’ll only power the charger
Oh okay
So for charging it can be on or off, but for reprogramming it needs to be on?
There are transparent OLEDs (HUD and pixels), but they are expensive and they're not really fit for a matrix with big dots. A gas discharge tube matrix would be cool, but it would require custom <pretty much everything>, and it would put high voltage very close to your face.
Yeah, the regulator needs to be on
https://learn.adafruit.com/3d-printed-daft-punk-helmet-with-bluetooth/overview might be a good place to start haha
I have a question, assuming the fault with this ESP32 feather v2 is that the usb-uart bridge doesnt work, is there any way to bypass that and program it anyway?
could there be a way to make multiple strips and a program to program each?
Assuming that is the case, you can solder some wires to the tiny pins on the ch9102f chip to connect to an external usb uart converter or other serial-capable device.
spicy
You wish to program each strip independently? A single microcontroller can handle pretty much as many of these addressable neopixel LEDs as you can power.
ah, i mean to link all of those strips into a grid haha
maybe i could just twist and turn the strip a bunch and see if i could make it into a grid?
worried about the flexibility of this, though, as flex boards are really rough
You can arrange them in a grid, sure. Probably easiest to just use horizontal rows and connect the ends.
With wires or something
This project uses two rows, but theoretically you can use as many as you can fit in the visor. Hopefully you can still see between the rows, though.
i could definitely do something like that! is the connection just two copper bits?
(as in, like, how many traces are there to connect?)
Three. Power, data, ground.
Direction matters for data, make sure not to connect two data ins or two data outs together.
Is it normal for a Raspberry Pi Pico PWMing a pin to make a very quiet, high pitched hum? I have to hold it to my ear, but I can hear it.
It's underclocked to 18 MHz
got it. may i send a garbage ms paint diagram of what i'm thinking?
Sure, why not.
It only happens when underclocked
perhaps the underclocking is the issue, then?
If your PWM frequency drops to an audible range as a result of your underclocking, a hum would not be surprising.
The know! So it's not any cause for concern?
*thank you
Not usually a concern, it depends on what you are sending the PWM to.
Set your PWM freq to 20khz (or anything above 16khz, depending on your age), you will no longer hear it.
that was like one of the first project
determine my range of hearing and my fps range with an arduino 😄
Cheap gadgets sometimes have a very low pwm freq (like 1-2kHz or maybe even lower). The noise is very annoying when you try to dim the pwm controlled thing
No. I think that would be pretty normal
Otherwise every single led light would appear to flash
Mains powered
Can’t see individual frames at 60fps, so that’s more than reasonable
eye fps is limited by the speed at which the receptors reset (since it's all chemistry), which leads to persistence of vision
A lot of LED projects recommend 400hz since there’s little chance of anything audible compared to motors or inductors
I need an 80mm (preferably) or 3 inch round display without an octagonal backlight and bulk. Can anyone find that? I've looked all over aliexpress.
dang, only one i can think of is 2.1
That’s an oddly specific request. Does https://www.aliexpress.us/item/3256804678255758.html work?
That's 3.4 inch
I see 3.4 and 2.8. If you need something exactly 3.00-3.15” you might need to custom order…?
There are a lot of 1.28” for smart watches, and a lot of 3.5”-5” for VR applications, anything in between has far less demand to have significant market share.
I’m surprised 2.8” even exists off the shelf, to be honest.
Okay. I might have to
3 Inch Round Ips Tft Lcd Display High Brightness 432x432 Resolution - Buy 3 Inch Round Ips Tft Lcd Display,High Brightness 432x432 Resolution For Small Size,3 Inch Round Ips Tft Lcd Display High Brightness Product on Alibaba.com
Too large of an outline
What exactly is this for, anyways? Do you need these in bulk for a product, or is this a personal project?
Personal project. Basically trying to replace the Gamecube jewel with a video display
Smaller with a border might do fine
Was thinking this https://m.alibaba.com/product/1600477213243/2-8-Tft-Display-2-8.html?s=p
2.8 inch 480x480 round IPS LCD high brightness all viewing angle tft module screen LCD display panel, You can get more details about from mobile site on m.alibaba.com
But I need a controller board. Any suggestions?
What are the rectangular holes in the bottom of the Feather cases for?
And why are the cases quite a bit wider than seemingly needed?
Oh it looks like it's to allow connecting a battery cover?
A Feather with a 400 mAh battery should fit inside https://www.amazon.com/Zulkit-Project-Plastic-Electrical-Junction/dp/B07Q11F7DS/, right?
(I know the mounting holes won't line up; I'll use hot glue or two-sided tape)
I just thought, the charging port will be hard to access.
Although I could have the board raised up in the lid
A way to plug it in without opening it would definitely be better
Probably not, but would sandwiching the Feather and battery between sheets of styrene and wrapping it in electrical tape be enough protection?
https://www.adafruit.com/product/4218 might be useful.
Oh, wait, those enclosures are tiny.
Hm.
I could use a larger enclosure if necessary.
Oh, that cable is a bit too expensive.
I'll look to see if I can find anything comparable cheaper.
I really only need charging; it's okay to take it apart for reprogramming. A dedicated external adapter for charging is okay. Does that simplify anything?
Is the "USB" pin on the Feather 5V USB power in?
You may need to specify which Feather you mean, since there are a number of boards by that name.
It's the Feather RP2040.
Yep, from the schematic the USB pin is connected directly to VBUS 5V on the USB connector.
Okay, thank you! So if I use some kind of connector to connect "USB" and "GND" to the positive and negative wires of a USB cable, that will charge it?
I mean, it should, but if you're using a USB cable already, is there some reason you wouldn't want to just use the existing USB connector instead?
A round connecter would be easier to get through the case because then I could drill a hole
Ah, gotcha.
I'm thinking about using https://www.adafruit.com/product/368 held in place with hot glue
I'll probably do that; it's made for panel mount use and only $1 more
It looks like all the connectors I need are available in panel mount versions fairly cheaply
Other than the case and a 3.5 mm to 2.5 mm stereo cable, both of which are cheap on Amazon, everything is available from Adafruit
Does it hurt Adafruit LiPo batteries to drain them to the point where the protection circuit shuts them off?
Where can I find an extended ribbon cable for this? What would even be the technical term for it? https://m.aliexpress.us/item/2255800358721473.html?spm=a2g0n.shopcart.0.0.5d9838dashq9gZ&mp=1&gatewayAdapt=gloPc2usaMsite&_randl_shipto=US
I think it's a 40 pin 0.5mm pitch but idk
Would this processor work for my needs?
https://www.digikey.com/en/products/detail/nxp-usa-inc/MCIMX6Z0DVM09AB/9687787
I recommend looking at AllWinner SoC
They come in packages that are actually usable for the average person
BGA tends to requires lots of advanced techniques in routing and expensive board manufacturing processes
Imx6 is a solid processor with a lot of support, but I don’t think off the top of my head I could tell you if it could run a chatgpt instance.
Plus they tend to have lower yield because it’s harder to fix electrical issues under the chip after it’s soldered
It’s pretty common in commercial devices, but not exactly accessible to hobbyists.
I know they have system-on modules available for this processor though. Doesn’t help with your unusually high memory requirements, but could ease development costs otherwise.
Definitely look at Octova I think is the brand
They have very nice SoM with big pitched BGA
Octavo iirc
Yeah
Do they do MPU sips?
Not ChatGPT. I'm talking about GPT-J. It can be ran offline.
There’s raspberry pi 3 A+ in stock
If you want to grab one
30 right now
Just above 10 now
I need a minimum of 16GB of RAM. This won't do.
I'd use my Pi if I could, but I can't. Besides, I plan on making this a USB that plugs into a computer, so the power draw wouldn't be ideal.
GPT-J
Is that what they suggest?
I think he’s trying to load the full model into memory
I think most applications use gpu ram though
I think he’s misunderstanding the requirements
16GB VRAM
Many models want 32GB or more of RAM on top of that
You’re not going to get that in a PCB that’s easily designable or manufactured
Just being realistic here, you will need a GPU, CPU, etc..
I believe I can use CPU RAM. This is only after adding an argument to the model and using the float16 branch to get the model's requirements to 12.1GB.
All that is going to take months to design a USB ready device assuming you’ve done the design to get that
My understanding is 12.1GB is just the size of the instance not the resources needed.
I don’t see a capable cpu being able to operate as a bus-powered device. At least not with our current generation of hardware.
Yeah
If you find something that can do PCIe over USB C and have a host that can do that as well, sure maybe
Why would I need PCIe?
Not trying to be a killjoy but something like this would take a team of 2-3 experienced engineers a couple months to do.
Because of Hem’s mention above
So I can use a processor capable of running the model?
I would find a small gaming PC with a dedicated graphics card
GPT-J appears to heavily rely on GPU power
udoo bolt comes to mind
I just checked coral dev board, even that only goes up to 4gb
And that’s designed for machine learning
Yeah
We’re talking an application that traditionally requires a cloud hosted server to run properly
I don’t mean to be a Debbie downer, but I think this needs a lot more research before you start shopping for hardware
Even most standard PCs wouldn’t be able to do this, and you’re trying to squeeze this into a thumb drive haha
It would probably get thermally throttled right away
I think the biggest issue is the number of constraints you’re setting for yourself right from the get-go. Before jumping into MPUs and RAM, start with some feasibility studies. See if you can run this on your home desktop before trying to go smaller. Approach this as a multi-part problem and go one step at a time.
What hardware do you have that successfully runs this model? How much memory does it use in practice? How much power is it drawing? How fast is it running? How can I reduce the hardware requirements with minimal performance impact?
I admit I didn’t really think about what you were trying to do when you first brought it up, but these are all important design steps that all contribute to a successful design.
And also evaluate how your own skill level in designing things to.
Some of these parts require quite a bit of experience to route and use in manufacturing. Plus the cost for a few one off boards might be more expensive that simply going with an off the shelf solution
… NVidia Jetson? I dunno what the whole project is, but I know Jetson can come with large amounts of RAM for training models and stuff, and the Nano can be had for under $200
Right, but the nano doesn’t go up past 4gb ram. Jetson Orin might manage, though.
Only 721 for the module.
Yeah
Looking, a lot recommend running GPT-J in VRAM because it tends to be better optimize for the tasking
Add a minimal carrier board and we have something that might meet the specs and is only a little bigger than a lattepanda.
LattePanda ahhh such a great board
Someone shoved a Zynq 7000 on a feather so maybe Pi Zero W sized if you really know what you’re doing
Still uses like 10W min, not something you can provide to a USB peripheral. Maybe usb-c or thunderbolt…
Oop, I thought it had 8 and 16GB versions… might have been thinking of the Orin
So where should I start? Build a gaming PC? Get a Linux SBC?
What’s your end goal?
Like, what do you want to do with ChatGPT-J that you were thinking of building your own SBC?
It's only GPT-J, since it's not forked from ChatGPT. I was hoping for something possibly like a portable assistant. It could write code, generate essays, etc. I'm not completely sure how to put my end goal into words.
Ahh. I’d say if you want to do any software development before deploying, start on your PC; but for portable, I’d just find an existing SBC instead of trying to create your own
There are USB neural accelerators like https://coral.ai/products/accelerator
My PC isn't capable of doing so.
I'd consider the USB accelerators that madbodger mentioned; then you can use it on a smaller/cheaper SBC like a Pi Zero
Would I need multiple?
Probably just one would do it? But more is faster
I have access to one. How would I set it up with GPT-J though?
That's a bit past my knowledge -- but usually the configs for such models allow selection of accelerators
Or some automatically provision and use available accelerators and GPUs
@worldly schooner new idea, clear me on this if i'm wrong, but could i grab a bunch of those old red dot leds and address them by writing some arduino code?
Is it possible for me to use a Raspberry Pi 4 (8GB) and a Coral USB Accelerator to run the model?
Should be able to!
How would I write the script? What all do I need to do?
Like I said, past my knowledge -- I haven't used GPT-J or USB accelerators
The matrices? Sure you can, but I don’t know if that saves you money or time.
not the matrices, just pure old school dot leds
Regular LEDs don’t have “addressing” so you would need extra hardware to control a large number of them
A lot more wiring and complex design, too. The LEDs themselves are cheap, but you’re on your own when it comes to controlling them.
ah, i see
At some point, I plan on getting a laptop I can use for development (e.g Unity, LFS, etc.) and maybe some gaming. Once I get one, I can possibly get the model running on it.
You can address them by putting them in a matrix, or more of them (with more difficulty) by "Charlieplexing" them. You can also use an outboard chip to do either of these for you.
TL. DR. Do i need to worry about how much power this type of shunt resistor dissipates?
I am building a soldering iron, pretty common thing hakko 907 clone iron controller. I want to measure current, to simply calculate power. I want to use this shunt resistor (combination with a low pass filter to average out PWM), and couldn't decide on value. I am using 20V supply so full-on peak current is 5A, and when hot it's close to 3A. With 50m shunt peak power is 1.25W. According to conversations we had before here, I also need to consider signal to noise ratio. I will have to use low pass filter so I don't think there will be issues about that. What power should I aim for shunt resistor dissipation?
My choices are 2m, 5m, 10m, 20m, 30m, 50m, 100m, 120m, 150m, 200m, 300m, 500m. Open to suggestions but I would like it more if I learn to make decision myself.
Quick question regarding RGBW-Neopixels. If i just want to run one of the colors or white on full power, but no mixes of colors, is a JST XH-Connector (max 3A) safe to use for the NeoPixel Matrix (64 LEDs)?
Are the 80mA / pixel-figure mentioned in the Überguide on the website for ALL colors and white on full blast at the same time?
20mA per color.
yes, and should be fine.
For reference, Estimating Power: https://learn.adafruit.com/adafruit-neopixel-uberguide/powering-neopixels
Thanks! You’re retro rebuilds/repurposing has given me some ideas for my SEGA genesis
I have no idea if it works in its current condition though ha
They’re pretty robust. Start with a recap and clean the cartridge port.
I plan to convert the power supply to USB C in the process
Make it easier to power in the future since I don’t plan to re home it
That would be cool to see.
I need to find some games too, all the ones I had from years ago are long gone
You seem to understand the tradeoffs: lower value = less heat and more efficiency, but a lower level signal out. Higher value gives a stronger signal, but more heat and lower efficiency. For a 3-5A range, and the 50mΩ value you mention, that would give 150-250mV signal, which seems workable.
Thank you!
Thank you!
thank you
What do you mean by efficiency? I thought that a resistor dissipates all its power by heat, and therefore is 100% efficient at producing heat or energy that ultimately becomes heat.
just started researching this, tysm
Probably meant system-level efficiency.
Maybe. That would make sense
The heat will be dissipated on shunt resistor away from soldering iron's heater core
For some reason I was thinking it was a shunt and heating resistor. But in hindsight that really does not make sense
It makes sense but you have to know temperature coefficient of resistor. Not really reliable way of doing for a no name Chinese clone
That's why I was thinking of skipping the shunt entirely and just measuring the drop over the heating element instead. Granted, it's going to be a higher temperature range and would likely require correction, but it's simple enough to measure the values to build the coefficients.
resistance does increase with heating, so it could also be possible to measure the temperature that way
you could tap the heating element to effectively create a shunt
That too. However, a tap wouldn't add much information if the entire element was at the same temperature.
a tap could measure current though. And wouldn't require a hot shunt
Maybe you can measure it. But that would take some precision equipment
although I think it's just based on material, so you could make an educated guess and see if it works out
I don't really see how a tap could measure current in this situation, but just measuring the voltage across the element could, once you'd determined the thermal coefficient.
hey everyone, looking to buy a couple of pico w's but im not a fan of the micro usb port, im either looking for a clone of the product or a usb c connector that has 5 pins to work in place of the micro usb port
i found these online but idk
Since it doesn't have a datasheet or any such, there's ultimately no way of knowing entirely other than purchasing them and testing them out
yeah
when i go to order them, there is no where to change country
and its set to india
if anyone knows of another website with them give me a ping
Here’s a very similar board to the Pico with a C port https://www.waveshare.com/rp2040-plus.htm
RP2040-Plus, A Low-Cost, High-Performance Pico-Like MCU Board Based On Raspberry Pi Microcontroller RP2040
Oh, wait, you said W, oops…
no worries
As much as I would agree on the micro vs c, I’d be skeptical of using a 5-pin usb c connector unless it somehow handles the cc resistor terminations internally somehow.
that's not impossible, though
No, but I expect them to be decently expensive haha
you make a good point
and i cant get the ones i linked above
they only sell within india
For Wi-Fi with RP2040 you could use the Challenger RP2040
Raspberry Pi Pico board with 8Mbyte Flash and integrated WiFi
Somebody with an RP2040, could you please run the following snippet in order to find out which pin combinations support PDMIn: https://learn.adafruit.com/adafruit-pdm-microphone-breakout/circuitpython#wheres-my-pdmin-3038798
I think you are more likely to find help on some other channels. Maybe #help-with-circuitpython
The project I'm taking inspiration uses mcp602, but I have access to some mcp6002 in my uni lab so thats what i will be using. But this made me think, is there any reason to use mcp602 instead of mcp6002? It looks like almost virtually every aspect is same or better with lower cost, am I missing something in comparison between two?
https://www.microchip.com/en-us/product/MCP602
https://www.microchip.com/en-us/product/MCP6002
its almost like one is successor to another
I want to use the value from a 4-wire load cell to a comparator, can the SIG- be bridged to ground? Assuming excitation + and - are used as normal, and SIG+ goes to the comparator.
If sig- is gray wire on the picture you shouldn't. you would effectively put R2 between supply and GND which could damage the resistor. Even if it doesn't damage anything, there is no reason to connect it to ground. It is useful for using differential amplifier as front-end for the sensor, otherwise leaving it floating shouldn't have any consequences.
makes sense, i ask because most ADCs designed for load cells (ie HX711) have specific inputs for A+ and A-
By leaving it floating, would there be any function loss? I would think maybe measurement of negative force???
(Not that I need it)
IDK what hx711 is but normally you put a differential amplifier between green and gray (R1 or R4 is strain gauge, doesn't matter too much), and use opamp output for your task. Could be MCU ADC could be comparator or sth.
I don't think so. The idea at rest green wire settles at 2.5V. If you apply force 1 side you observe that green wire voltage increase. If you apply other side green wire voltage decrease.
With differential amplifier you measure voltage difference between green and gray, and amplify as needed or if needed. (more advanced explanation would be R2 and R3 creates common mode voltage and opamp measures difference to common mode.)
If you don't use differential amplifier (assuming 10 bit ADC) at rest you would read 512 and when you apply force you read more than 512 one way and less than 512 other way. If you remove 512 from read value, you virtually made same thing as differential amplifier. I don't expect you to read 512 on rest, due to how voltage dividers work.
I think all pins support PDMin through PIO
RP2040 has no native PDM interface, but it can be accomplished through PIO
MCP6002 has a lower gain-bandwidth product than the 602
I'm hoping to get some suggestions on a soldering station. I had a cheap soldering station that had an iron, and a hot air rework tool. The fan in the hot air tool bit the dust, so I'm looking for a replacement. I want to get a quality replacement, and I'd like to be able to solder through hole, and smd parts. I did really like having a hot air station, but if it's hard to get a combo tool, I could go for just an iron and hot air separate. I want something that will last, and don't mind spending a bit of money.
Probably a Hakko
They sell decent irons and hot air stations from my knowledge
I use the Chinese cowboy brand Yihua
(It sounds like Yee Haw lol)
Seems to work well enough for me
I've been looking at Hakko, they're pretty spendy, so I was hoping to get feedback on if they are worth it. Thanks for the input.
I highly recommend the pinecil. It's portable, USB-C powered, reasonably priced, and open source. It also somewhat outperforms my RadioShack soldering station.
by Pine64
Whoa, I didn't know such a thing existed. $26 seems super reasonable.
They are hard to find though unless you want to wait for shipping from Pine64
I have a Yihua hot air station. Works well. Hasn't broken yet
Mine makes weird noises but a good tap usually gets it back acting right lol
kinetic maintenance lol
would be cool if an open source version existed
or a handheld, portable one
Interesting, It looks very similar to the station I have. The hot air tool started making some awful noises, and wasn't moving air. I might have to try the kinetic maintenance.
You can see where the nozzle is all blue because the heater was just going crazy without any airflow
I would definitely second that recommendation.
If you don't mind spending some money go for a Weller station
are there any templets for EASYEDA of a bare bones rp2040 board with power, flash, and module? Just like a templete that has all that taken care of that I can use to build on the other functions i need?
Pick one with everything integrated into tip heater, sensor etc. Like t12. There is minimal gains buying name brand sleeve like tips.
@dry pelican yesterday, I've reviewed your schematics in show and tell and I've got a question if you don't mind. I've noticed you haven't put any denouncing capacitors. How was the real life performance? Was it noticable, any shadow clicks? Especially concerned with rotary encoders which I decided to use myself too
I also don’t put denouncing capacitors in my design 🙂
They’d rise up and take over!
Lol
Any real world feels?
I put debouncing on some buttons
I feel like I have to put them for rotary encoders because they are interrupt controlled. I think polled buttons are generally fine with no hw debounce.
I just wanted to take opinion when I saw someone doesn't use them, maybe I am being in my head and parts and tolerances got so good that it doesn't need anymore. 🤷♂️
It’s not so much debouncing that you get but smoothing.
True debouncing would need like a Schmidt trigger
It’s pretty close to the same thing though
True but cap is like 20 pennies and Schmidt trigger ic is more than 50 times price
A cap in high quantities is like $0.001 🤓
Yeah but I'm not buying 1k caps or buying from bulk salers
hi so do u know any templets for rp2040 barebones EASYada?
alr thanks
ooh they have kicad stuff, ima try to import it into easyeda
The debouncing would just be done in software with a rotary encoder library because I'm lazy. The project isn't completed (No board, and I still have to do a proof-of concept and a redesign in KiCAD)
Does that library work for Arduino or is it micropython?
I have a concept and almost a full design but i am second guessing some aspects of my design i think there might be too many interrupts. That main loop will be empty.
I'm pretty sure that someone has written a good library for CP or MP
Hey. My kicad footprint associations somehow lost. I cannot chose footprint while adding new symbol. Do anyone know why that might be? Turns out its only some of the footprints missing not all the parts. Eg. atmega mcu footprints are there but not connector_generic footprints. Already tried to uninstall and reinstall with and without deleting my documents folder and %appdata% folder(s).
I was able to get the rp2040 basic into easyada, all goes well, but i get a warning when i check connections warning is for 1.1V. That is not required r ight due to the rp2040 regulator
iirc it says that in the manual
Vregin takes 3.3V and spits out 1.1V on VregOut
VregOut feeds DVDD pins
So three pins total should have the label 1.1V
It would help if you told us the specific error you are getting. In most cases, it's worth digging out why any errors or warnings occur, many of them are important clues for getting your board implemented correctly.
good idea
it just says incomplete connection please check for the 1.1V
for context this project is exactly the same as the official demo
i imported the project directly from their website. and also in the manual it said something about like not needing the 1.1 due to regulator
It might be a pin definition problem. Most of these programs have notions of pin types like "input", "output", and "power", so in this case the 1.1V in pins would be "power/in" and the 1.1V regulator would be "power/out".
It would be annoying if the official demo had the pin types wrong, but not unheard-of
i was thinking it was some error, but then i saw this in their manual so im now confused if its legit or just software being software
"At its simplest, RP2040 requires two different voltage supplies, 3.3V (for the I/O) and 1.1V (for the chip’s digital core).
Fortunately, there is an internal low-dropout voltage regulator (LDO) built into the device, which converts 3.3V to 1.1V for
us, so we don’t have to worry too much about the 1.1V supply."
It is correct that the on-board regulator is sufficient for the required supply, which is why I'm positing the error occurs because the software does not understand that this is the case, possibly because of a pin definition problem. Normally the ERC (electrical rule check) tries to verify that every input is connected to something, every power pin is connected to a power net, etc. But the details of what a power net is, and where the power source for one comes from, can be subtle.
In this case, the 1.1V net would be a power net, and connected to all the 1.1V supply pins. The wrinkle is where that 1.1V comes from: in this case, it's an output from another pin (the regulator output) that constitutes the 1.1V supply.
@supple pollen so its a false alarm?
We don't know that for sure.
what would be the way to figure it out if any?
these files are from https://datasheets.raspberrypi.com/rp2040/hardware-design-with-rp2040.pdf chapter 2
My usual approach is to check all the pin definitions and assure that they are correct (to the extent that the software supports the pin types required). Then check net definitions (in particular, that the 1.1V net is declared as a power net). Then chase down what the specific error means ("incomplete connection" seems fairly vague to me, but hopefully there's documentation as to what it refers to). If you can remove the error by correcting the pin and net definitions, that's ideal, because then the checking is working for you. If you can't (because the software doesn't support your specific situation), then you're stuck going through the netlists by hand and verifying that they all do what they need to do, and manually doing any other appropriate checks (for decoupling, impedance, or whatever).
ok
also im getting this error now
wonder if they are related?
nvm thats a application error
another thing, its making me update a lot of footprints, for like resistors and stuff, how do i make it use parts from JLCPCB store?
Does an “8-channel ADC” mean there are 8 separate I/O pairs that execute simultaneously?
i was able to update footprints for all of them except the rp2040
which is slight problem
Not necessarily. Some are not differential (in other words, just 1 input pin per channel). And many have a single internal ADC converter and switching logic to connect it to different inputs, so you can effectively only digitize one input at a time.
Thank you! Are there phrases I should look for that would indicate full parallelism?
I'm not clear on exactly what you're looking for here, but for example, the DigiKey parametric search includes a selection named "Ratio - S/H:ADC" which may be useful. Presumably a 1:1 ratio would have a converter per S/H channel (what I don't know if there's a S/H channel per input, or what it means to have multiple converters per S/H channel)
what do i do if i need 3 3.3V and pico only has 1?
If other limitations (current draw, noise propagation, etc.) allow, you can connect multiple loads to a single voltage source.
hmm didnt know that. What is the difference between 3v3en and 3v3 out
"en" often refers to an enable input to switch a regulator on or off. "out" generally refers to a voltage supply.
ok
so i cant connect to en if i just want power?
also can i just make pin X high to output 3.3V and make many 3.3V pins,, or should i look for external power
"en" is normally an input, not useful as a source of power.
While you can get 3.3V out of an I/O pin, the available current will generally be quite low, so it's only useful as a very low power power source. Normally, I connect the 3.3V regulator output to all the things that need 3.3V power (again, subject the the limitations of the regulator)
ok
do u know if the regulator in the pico can handle 2 3v3 things
adafruit gps and adafruit bno085 IMU
You'd have to look up (or measure) the current draw of each one, add them all together, and compare it to the current available from the regulator (which should be specified on the Pico data sheet)
@supple pollen srry noob ? current draw is amps?
Yes, current draw is measured in amperes
Just an FYI, you can no run the RP2040 off a coin cell, the startup current is more than coin cell can deliver if you’re considering one.
No i am no
only 1 does as seen in this schmatic
i only see 1 though
wait is dvdd also 1.1
Yes
so that error thrown by program is possible false error
I’m not certain but maybe
ok, yea i was using their sample project as kinda like a shortcut to get a basic version, but then when i uploaded their KiCad files into EasyEDA, it is asking about footprints over and over again...
in that one layer only is on part of it
is this normal
if im using the MKT3339 chipset, what do i absolutly need, there are like 11 ports on the chip
Would anyone want to review my design? last minute preflight check?
Looking for a voltage regulator for 3.3-5V up to 5V, would there be a universal pinout with a few options in case one or a few are out of stock, or do they all have different pinouts and packages?
They usually list rated voltage after part number as 3.3 5.0 or adj for adjustable
I guess lt317 is industry standard part
A bit old but should work
Does it allow for a varied input or would the output need adjusting according to the input?
There's an allowed input voltage range, but the output would be the same.
okie :3
Which coincell did you try?
I'm going off people who've used like 2032 coin cells and had issues
What about a coin cell and a capacitor…?
You’d need to store enough energy to supplement 15mA max draw of a coin cell, so at a minimum 10mA. I think startup current can be as high as 30mA though
So probably a 200uF or better cap
Might get away with a 100uF
Assuming startup was just a few ms, maybe something as small as a 47uF cap might be suitable.
Top google result for max current draw of a coin cell suggests a 47-100uF capacitor in parallel with the battery if your circuit exceeds 15mA draw
22k LED series resistor seems like very low current in the "Driver" section
It's aimed for 1mA, i want it to indicate not blast my eyes out so 1mA seemed fine
Brilliant 🙂
Well i still don't know if 1mA enough to even light 5mm led but can always use spare 10k ones
1mA lights most LEDs fine. You'll get visible light even with a hundred microamps (as it happens, LEDs are more efficient at low current)
Just make sure they’re low test current LEDs 🙂
I’m fond of ones with 1mA of test current because they turn on pretty brightly like you mentioned
Though I usually end up getting 2mA and 5mA one
As mentioned I don't want an led shies bright at 1ma
I want 20ma led to light with 1ma and give me 1/20th or even less light
Brightness isn’t really perceived linearly and some 20mA actually have minimum “turn on” current so be aware of that
That's the part I'm worried but it's tht so should be hard to botch another resistor
Yeah
In the past, the smallest resistor I’ve used is like 6k8 resistor and it just barely “turned on” (with 5V) so you might be okay at 24V
Very few have a minimum "turn on" current like that. Ordinary 20mA LEDs generally light just fine at 1mA. And due to their greater efficiency at low currents, as well as non-linear perception of brightness, they seem much brighter at 1mA that 1/20 of their brightness at 20mA. To get 1/20 brightness, you may need to run them well under 1mA.
I try to say “turn on” loosely because as long as the forward voltage is fine, it’ll be “on” it’s just a matter of visible
Which I guess 6k8 resistor is ~310uA for a 2.8ishV LED off a 5V supply
And it’s kind of “on”
Which I understand I’m preaching to the choir here lol
Put some provisions in for caps across the negative feedback line
so parallel to R11/R14
@balmy tide basically like this, but you dont have to have values for them yet. Its to save you a potential revision as sometimes Op-Amps can oscillate.
C6 on my diagram is the simple way.
C10 Helped too IIRC (its been a while)
C3, C5 and R4 formed a filter to stop oscillations.
that reminds me: I should really finish that project 👀
That's like active low pass filter right? I don't think power one needs it. Also my configurations are non inverting yours are inverting for C6 opamp if that changes anything.
Look again. Yours are non inverting too. You are taking the input on the + side of the op-amp and you are using negative feedback. Its still worth making provisions for it, just in case. You dont have to populate them, just put them in and dont solder them up.
Ohh right sorry my bad thought net label was input. It was common mode
I've done some research before going back to my GPT-J Linux USB. So what if I make it a standalone portable device? Possibly powered by a battery, it could work by itself and accept user input. You could also connect it to a computer for additional capabilities, such as outputting GPT-J's output as an HID keyboard.
What hardware would you need to run GPT-J? Whether you can make it portable depends on its requirements relating to its power consumption and available resources.
Well, in terms of processing power requirements, I haven't found anything about it. At minimum, the system needs 16GB of RAM. Depending on the weights used, the system needs 16GB or 64GB of storage at minimum.
Would your desktop or laptop run GPT-J?
Unfortunately not.
Those are some hefty specs. There are a few SBCs that have 16GB RAM, but they all require like 4A at 5v. If you're trying to make a USB stick with a self-contained low power SoC, then uhhh that's going to be hard
I don't think I'll make it a USB anymore.
Google has an accelerator stick that can plug into a USB port
But maybe they killed it
Or maybe it doesn't have the specs
Not sure
They still offer the Coral USB accelerator, along with a few nifty boards with built-in accelerators https://coral.ai/products/accelerator
Hey! Would someone mind doing a quick review of my design for a keyboard PCB? 🙂 See if I'm missing something obvious.
What do you mean by hole? Are you referring to this?
@vagrant cairn If so, that is just a void in your top and bottom copper layers, not the PCB itself.
is that a problem??
Not necessarily. Just make sure everything is still connected and not separated by the "voids".
ok
If rotary encoder is readable in that configuration, everything seems fine to me. Good luck with it. :)
@vagrant cairn the hardware questions you're asking are better suited here. 😉
cool
so how would i write it
cause these are the events that need to happen when switch is flipped
SCL is cancelled
SDA rerouted to RX
P0 is shorted
those multiple complicated events need to happen
1.
Board 3V to sensor VIN (red wire)
Board GND to sensor GND (black wire)
Board SCL to sensor SCL (yellow wire)
Board SDA to sensor SDA (blue wire)
2.
Board 3V to BNO085 Vin (Red Wire).
Device GND to BNO085 GND (Black Wire)
Device RX to BNO085 SDA (Blue Wire)
Board 3V to BNO085 P0 (Purple Wire).
give me a little bit to think about it.
ok
alr, ill try too
If we keep the scl connected for the rvc mode, even though its not required, will there be issues?
is the BNO the adafruit breakout board or a standalone chip?
ada
which one because there are 2
bno085
4754
if the scl can stay and it will be benign, then it will make it super easy to do
oh nvm there's an 085 and 055
yes
085
is this to change the operating mode?
so you really only need to pull PS0 high to switch between I2C and UART
are you against an external switch or is this for a custom PCB?
custom pcb
but dont u need to reroute sda to RX too?
iirc thats what it says
the pins in red are UART RX/TX
on the pico they share the same pins sometimes as I2C and SPI
so you just have to use one of those pins, and flip it in software
but that doesnt work
cause sda lines up with Tx not RX
but even with these 2 changes only, i guess switch is prob easier, how does the wiring for the switch work??
the diagrams look kinda complesx
yeah easyeda's diagrams for switches are kinda horrible and confusing
can sda pins be used as slc?
like are they interchangable, or not?
that i'm not sure, i haven't experimented with the pico enough to know for sure.
hmm i got it from a 3rd party site and looks old, might be outdated.
ok yea
but as long as the scl can stay connected, its just a matter of rediction which is not that hard,
how does wiring for this work?
actually it's the official adafruit reference card
god i hate the way switches are laid out in easyeda
the direction the latch is pointing is normally closed for 5, normally open for 1
so what i want down is 1 and closed is5, what abt 2,3,4
so do i connect 3v3 to 2 3 and 4
Ok that makes sense, and where do i connect the common stuff??
5 can go to sda and 1 to tx if you want
oh oh oh
where does input lead go
prior to switch
and then i would need 2 switches right??
also if you can spare the GPIO i would use a separate pin for sda from the pico and tx from another pin
will make your life a little easier if you have spare GPIO to use for whatever you want so you don't have to try to use 1 pico pin dual purpose.
yea thats what i want anyway,
but this switch where does the input go
input as in prior to direction ing
oh right you're not just switching data lines you have a power cut involved too
That's an odd diagram, but my guess is 2 and 4 are the coil, 3 is common, 5 is NC, and 1 is NO
yeah the way easyeda has switches is horrible even for something simple like spst
are there any fork switches
that just take a common and route it depending on the toggle
maybe a transistor would work automatically but i don't know how to do transistors yet :/
Yes, that's known as a SPDT (single pole double throw) switch
oh ok
isi tlike this
That's not a switch, that's a relay. It's what is known as a "Form C" type, in which the switch portion corresponds to a SPDT switch
ok
so is this an spdt switch
That does appear to be an SPDT rocker switch
That appears to be an SPDT toggle switch
You can use the common terminal as either an input (with two switchable outputs) or as an output (with two switchable inputs). Switches can be thought of either which way, depending on what they're doing in your circuit.
hmm, how big are those by chance
i need something to fit on the PCB
Those pictures don't show a scale, so anything I would say about the sizes would be guesswork.
one thing i usually do is go through lcsc to find a part i like then input the manufacturer part # into easyeda
kinda like browsing digikey, it's very similar
and sometimes you can find the same exact part on digikey, order the board from jlcpb, get the part from digikey, and assemble it yourself.
The manufacturers provide nice diagrams (this is a C&K 7101 series PCB mount SPDT switch)
You may want some other style of switch if you need something smaller.
How about this Alcoswitch DIP mount one?
this could work
actully really well
i would need 2 of them right, one for sda and one for 3v3
Would you want to switch them together, or individually?
Then you might want a DPDT switch instead (double pole, double throw), which operates two electrically separate sets of contacts with a single actuator
that would work
That's not a very clear diagram, so again it would be guesswork
problem is easyeda parts library doesn't even recognize spst or dpdt finding switches is a nightmare
so are battery holders because china has a completely different naming convention
yea also i think these dpdt thigs are too big for a pcb
what we know as AA or AAA batteries they call like size 4 or size 5 kind of thing
so i usually shop on digikey for parts. the manufacturer part number is usually the same if lcsc carries it
oh wow. Also do u k now any small dppt things like u sendt for sp?
and if lcsc carries it then they'll have a footprint you can more easily use inside easyeda
on lcsc?
yeah i'm looking for you
alr thanks much!
through hole or smd?
Here's one SMD possibility https://www.lcsc.com/product-detail/Slide-Switches_C-K-AYZ0202AGRLC_C221564.html
AYZ0202AGRLC C&K US$0.9562 - SMD Slide Switches ROHS datasheet, price, inventory C221564
wdym
are you going to have jlcpbc assemble it or will you?
me
i dont wanna pay them
cause they cant even do it
through hole it is then
ok ..
Dimensions on that one
inches?
Inches, followed by mm in parentheses
k
So it's 0.283 inches or 7.2mm long
Great, thanks! 😊
is that a user?
yes it's a user contributed part but the footprint is good and you can buy the part from digikey to assemble on the board yourself
cool!
i've contributed many adafruit footprints of parts. 😉
not all user contributed footprints are good though, you kinda learn from experience which ones are going to work and which ones people just guessed while trying to make.
so that's how i design with easyeda, make pcb's with jlpcb, and use digikey parts to assemble myself 😉
notice the manufacturer part # on digikeys website is the same as the part jlcpcb and easyeda use
sometimes might take a couple tries to find one that both use
can i leave the 3v3 blank for the non short, or do i need to ground it
any pin that you're not going to actively use you green X as non-connect (NC)
the X should be in your wiring tools panel
yes, needs to exactly be on the end of the pin or it'll show up as an unrouted net when you go to make the board file
it'll complain if it's not actually connected to the end of the pin
here's a recent design where i didn't use a bunch of pins
i didn't have to fork like you do
for p0 short, even though its done
drag the one connected to the SW1 to the right a little
when connected properly a green line should automatically drag a little
still an i ssue
i always drop the nets onto the pins then drag the label out to ensure it's connected with a green line
nvm gopt it
just a matter of figuring out what makes easyeda happy 🙂
it should show in the left pane with yellow exclamations which nets are not connected that it expects to be
if you click on them it'll zoom you into the spot that needs attention
ah ok in board view do an update, that'll import the changes you make in schematic view into board view
design>import changes
in schematic view doing design>update pcb is the same as when in board view doing design>import changes. both do the same thing just from different places.
just had do do it 3 times i n each place???
in schematic view you want to ensure all your nets are completed first before trying to update pcb. it won't let you update the pcb with disconnected nets, so it forces you to fix stuff in schematic view first. it's honestly a better way to go so you know the stuff you're working with in pcb view is good to go.
Maybe all I should need is a decent processor and 16GB of RAM. I still can't find anything about the performance requirements though.
There might not be a strict requirement, it'll just... run slower on a slower CPU.
Usually such things are run on TPUs or GPUs. If you want to run it on a CPU, I'd suggest a pretty powerful board such as a BarrelEye or Raptor.
Would anyone have recommendations on a smd MCU that can send UART and have 4+ (i think)PIO? I'm wanting to use it as an in-between for controller buttons & a bluetooth module. Unfortunately the IO on the BT I'm wanting to use doesn't support what I need, so UART is the only solution. I'm trying to keep everything as small, low profile, and low power as I can in order to reduce battery drain.
The controller has a 3.3v or 5v pin I can use
inexpensive is a plus, too
What Bluetooth module?
ideally the FSC-BT802 https://www.feasycom.net/Content/upload/pdf/202013049/FSC-BT802-datasheet.pdf?rnd=728 or something similar at that size
UART is the circuitry that does it, the protocol is asynchronous serial
The nRF52840 can handle buttons just fine
Has a good ADC if you’re doing joysticks
Fairly easy to solder modules available (you need a stencil and solder paste)
This is actually for bluetooth audio. How difficult would that be to set up?
NRF52 support Bluetooth audio
I take it that Bluetooth module uses serial for control and gets the audio stream separately, as I doubt squirting audio over an asynchronous serial link would work well.
Yeah, the FSC-BT802 does have separate input for audio
Attiny 2-series
I thought the only module that supports BT classic is the ESP32 classic?
Supposedly BT classic might be coming to the Pico W.
What's bt classic?
I presume bluetooth before the low energy spec, stateful connections!
BT classic is BT streaming audio. Otherwise BT is mostly BLE data only. BLE doesn't have enough bandwidth to do audio so there's a big distinction.
Any BT that can stream audio is referred to as BT classic and pretty much everything else is BLE.
There are only like 2 microcontroller types out of thousands that will actually do BT classic and they come with caveats like you have to disable Wifi on the module to do BT classic. It's all in the fine print.
It's why DIY headphones using microcontrollers aren't a massively popular thing. Like you can build your own BT keyboard and that's a very popular thing to do but those use data only and only need BLE. Audio is a whole different ballgame because BT classic is a heavily licensed technology, kinda like HDMI has licenses but BT is locked down much harder. It's why the Pico W possibly getting BT classic support is such a major deal, like that's a big deal for makers. 😉
If Pico W gets BT classic support and it works well the amount of DIY headphone projects will be off the charts. Makers have been waiting like a decade for it. Yes there are BT classic boards out there but not easy to work with like the Pico W is.
Maybe. The docs say that loading time on 16GB of RAM is about 3 minutes, 1 minutes if stored on disk, and about 8 seconds if saved and loaded with torch.save() and torch.load().
So I think an NXP i.MX6 ULZ would work for the processor. What chip would work for RAM?
Looks like it supports DDR3.
Now that I think about it, power also has to be taken into account. A high-power USB Device can receive a maximum of 5V at 0.5A, so I'll have to power the processor, the RAM, eMMC or microSD Card, etc.
You can get more with USB-PD if the source supports it.
I'm not sure if a normal computer would though.
Also, where can I find DDR3(L) chips on DigiKey?
Search dram
Note that to get 16GB you're going to need to use a bank of multiple chips.
And also keep in mind that these require matched length routing
And probably at least 6L
And likely controlled impedance
I would need 16 of these to get 16GB of RAM though.
Better than 64 of them using the cheaper modules
There’s these but they are $45 for a single
So you’d spend.. a lot of money
This means that I'd need 21.6V to power them all.
Generally they'd be connected in parallel, so the same voltage as one chip but more current.
The imx6 supports only up to 4GB of RAM too because it’s 32Bit
So be mindful of that as well
So is there another processor I can use?
Probably an iMX8 since it’s 64bit
I would definitely suggest not trying to go this route. It’s going to be extremely difficult and expensive, especially compared to other options. I understand the ambitions (I’m working on a phone that’s using the iMX8 currently) and it’s hard. The routing especially is very critical to these things operating properly. The mistakes are expensive too. When people develop SBCs, they will usually spend $1000 or more just for a working prototype because of how hard this is. Not to mention the time needed. Experienced teams of 3-5 people spend months working on these.
I’m not trying to be a downer, but there are better, cheaper, and less frustrating routes to go than building an SBC from the ground up
What existing SBC could I use?
The goal is a portable, battery powered ChatGPT box?
how much power can a VBUS pin on pico put out?
Probably something made for AI and ML like an NVidia Jetson
Or doing what @supple pollen suggested and using an accelerator with a raspberry pi like the Coral
No. I was hoping to build something that could be plugged in like a USB into a host computer, running GPT-J locally. I'd be happy to make something like this if a USB isn't possible. I'd like it to still run GPT-J locally though.
can it handle 2 servos? If not how do i provide extra power to the pico
It depends on what it's plugged into. You can probably get a couple hundred milliamps out of it reliably, after that, it starts depending on the upstream source of power.
is a usb power bank good?
It depends on the USB power bank (and the quality of the USB cable). Some of them will supply a couple of amperes.
I guess I'll move to something else then.
I just want to make sure you manage your own expectations properly. It’s definitely possible to make an SBC for this but it will take a lot of time and money to achieve. More than you’d spend configuring your own local server that you can interface with over your home network for instance.
Plus you’d likely need to spend a bit of time refining the skills necessary to route the high speed signals for the RAM and other interfaces.
No, it's fine. I'll move on to my Small PC projects. I'll finish the Xtensa PC and move on to RISC-V64 or ARM(32) next.
Now that I think about it, does anyone know any Xtensa processors besides the ESP32 that can run Linux?
Do you think i could run 4 servos from the pico?
small servos
also will JLCPCB assembly put adafruit stuff on my PCB?
Where can I get any? I should probably ask that first.
You might get away with that, but it's reaching the point where you'd run the power to the servos and the Pico separately, instead of trying to funnel the power through the Pico for no particular reason.
I don't know, but I've had other assembly houses put AdaFruit stuff on my PCBs.
so just like 9V batteries?
I’m not sure you can buy them directly
Looks like they’re mostly used by companies like Espressif
Actually it looks like Espressif is the only company to have used the Tensilica Xtensa architecture in a widely available product 🤔
Also TIL that Cadence owns Tensilica
You'd probably want a voltage the servos would be happy with.
Jlc will only install parts they have in their stock, see https://jlcpcb.com/parts
Search for components from JLCPCB in-stock parts library and top global electronics distributors, and pre-purchase components for quick PCB Assembly at JLCPCB.
I think they've recently expanded their options where they can use parts from some distributors too for an extra fee.
I'm going to at least attempt my project. What i.MX8 processor would be best?
Wait, you weren’t able to run it on your desktop, so you’re going to design a single board computer instead?
Have you tried a smaller variety of GPT? I believe it’s possible to run GPT-2 on a Pi 4.
That's not the reason.
I haven't thought about GPT-2. I'll try it.
I'll still make an SBC, but I can start with GPT-2 and move onto GPT-J later.
Thanks.
Just curious, @twin hedge how much pcb design experience do you have?
A bit.
Ever work with 6+ layer pcbs, high speed signals, or emi/emc prevention?
No, not really. If I need to do so, I'm willing to learn.
How much budget do you have to spend on SBC development?
I'm not really concerned with budget. I know that prototype and the final SBCs will be expensive, so setting a budget is useless (that's how I see it).
But you know how expensive this endeavor can be?
Yes.
Alright, if you have that much financial liberty, I guess I’m not in any place to tell you otherwise. Just make sure you hit all the bases with running GPT locally on a traditional computer before scoping out a board layout.
The single-board computer design is mostly uncharted territory for most of the professionals here, even.
Yeah, you likely will need to use the application’s engineering support from NXP if you want an evaluation of your design
Will NXP even provide application engineering support without a company and a sales forecast behind the project?
Maybe not
Could try their support forums
I also have serious doubts that an SBC could offer the performance necessary to effectively run these AI work loads.. GPT-2 maybe..
Gpt2 has been done, technically anyways. Anything more than that probably needs a dedicated server or cloud hosting.
I guess I should say on an IMX8 specifically
Ah, right. Pretty sure that doesn’t match the pi 4 performance.
I know GPT-2 can run on Broadcom chips but those are heavily restricted under NDA and minimum purchase requirements
I had read somewhere someone wanted to purchase $1m in Broadcom chips and that wasn’t enough to get access to documentation
It makes me wonder what the minimum order is to get access to their documentation and support
It might have been an anecdotal story
I've found datasheets for the broadcom peripherals and the GPU