Another Arduino Clone (Powered by RP2040)-Opinion/Suggestions Needed - Page 1
Forum section: electronics / projects

author: atulravi
author_rank: Contributor
timestamp: January 24, 2024, 07:28:35 pm
content: Hello readers!For the past few months, I have been working on a design where the RP2040 is the main chip in the Arduino form factor which can act as a drop-in replacement for the UNO especially in Educational and Automation related projects and products.The board is in the Same form factor headers and all with the only exception being 2 mounting holes being made into one. Another thing I have done is add USB C.The keen reader might say that Adafruit has already made the board. The Adafruit metro rp2040. But there are some characteristic differences. Primarily being the fact that the Adafruit board exposes only the 13+7 GPIO while mine gives access to all GPIOs to the final user. Another would be cost. Also, literally a month after I started the design of the board, Adafruit released their own version of the board which is a damn shame on my part since I was not fast enough. But oh well!Shields exist, but having to solder something as a beginner is something that will be tense especially when the person using is a student. Also, expanders and shields that convert the Pico to an Arduino form factor lack the power supply pins which is an added negative for those who choose to power the board externally.At the moment, I am considering crowdfunding and getting each board out at 7-8USD a pop. But since the Pico itself is 4USD, I am not sure whether it is appealing enough. But my board does come with a 16mB while the original Pico comes with 2mB. So, the primary differentiator would be the cost, storage and GPIO count.If I choose to proceed with manufacture, I am sure, a price drop in the main PCB itself which is currently at 200INR (~2.5USD) can be brought down to maybe even 80-100INR (~1-1.5$).But I primarily want to know what the readers of the forum think about the board. Whether it would be something useful. And in general, do let me know regarding your thoughts and if possible, I am happy to make changes or even reconsider any decision I may make.Photos of the first version of the board and KiCad renderings of the second (which is currently being fabricated) are attached to the post.(PS. It is fully opensource and most of the debugging has been done in the "Microcontrollers" section of the forum with help from quite a few passionate engineers and hobbyists!)Github Repo:https://github.com/atulravi/picuno

author: tszaboo
author_rank: Super Contributor
timestamp: January 24, 2024, 11:22:32 pm
content: Your bypassing capacitors are way too far from the IC. You need to go to 0402 maybe even smaller and place it right next to the pin. (Aside from the obvious footprint issues, that you are clearly aware of)

author: SiliconWizard
author_rank: Super Contributor
timestamp: January 24, 2024, 11:57:11 pm
content: Yes. No need to go smaller than 0402 though. Well, even with 0603 he could have placed them closer...Apart from that, adding a reset button could also be useful.

author: abeyer
author_rank: Frequent Contributor
timestamp: January 24, 2024, 11:58:17 pm
content: Extending the pcb out under the usb connector seems not ideal.I'd be shocked if there aren't quite a few cases/mounts/frames/etc... that assume they'll have mechanical clearance there even if the connector itself sticks out a bit above the board, and would be nice to preserve compatibility.

author: m98
author_rank: Frequent Contributor
timestamp: January 25, 2024, 12:17:54 am
content: The layout definitely needs a clean-up. The USB connector situation also looks quite fragile.Some feature requests:At least one LEDReset ButtonFuses for USB and DC inA fewQWIICconnectorsAdd some markings for special function pins (I2C, SPI, etc.)An optional Wi-Fi/Bluetooth module

author: tszaboo
author_rank: Super Contributor
timestamp: January 25, 2024, 07:47:44 am
content: Quote from: SiliconWizard on January 24, 2024, 11:57:11 pmI've actually tried laying out an RP2040 and it's a mayor pain in the butt to layout that IC even with 0402. For anything that I would consider acceptable. It has like 5 power supply pins right next to USB and crystal, and other nasty pinout issues.

author: atulravi
author_rank: Contributor
timestamp: January 25, 2024, 09:25:38 am
content: Quote from: tszaboo on January 24, 2024, 11:22:32 pmSure, I shall modify the design accordingly and try moving them closer. However, it they have not caused any stability issue in the few days of testing I have done. However, in the hands of the consumer, nothing can be expected. So, I shall see what can be done about that. Also like one user mentioned, I will be adding 2 fuses and also a protection diode near the DC jack for safety.Quote from: abeyer on January 24, 2024, 11:58:17 pmThe thing is that this board is also going to be marketed to local automation designers (who build cheap farm and garden automation systems with the Uno and Mega. They usually have 2 holes for the USB B port and the power jack. Suggesting that they change the whole enclosure design is not ideal really considering that they build them out of metal which is casted out of steel for a steep price for sustaining harsh weather.Quote from: m98 on January 25, 2024, 12:17:54 amV2 as linked in the GitHub repo and the renders, has 2 LEDs. One for power and one Built in. Qwiic is proprietary and is not used much in educational institutions around here (where the board will be shown as a suitable Arduino replacement). So, implementing it will be more of a cost adder and will also lower no. of GPIOs that remain accessible (Or so I feel). But I could possibly map out GPIOs to both a header and a qwiic connector and add a remark that either qwiic or the GPIOs can only be accessed at a time. Special function pin marking is something I am adding for sure. I shall update the design in the repo once I have done so.Regarding Wi-Fi and bluetooth, I am not opposed to adding it, but like I had mentioned cost might increase by a lot. However, I was considering the ESP8266 as the Wi-Fi module, but I fear documentation will be scarce. But I shall consider it.Quote from: tszaboo on January 25, 2024, 07:47:44 amI am adding a reset button. The kicad files in the repo will be updated shortly with the changes.Regarding layout, soldering with hot air has proven to be a pain because of that exact reason. Also, accidental voltage spikes have killed a few RP2040s in the past. So, it is a sensitive chip for sure. Also having 3.3V and 1.1V lines right next to each other I feel is a huge mistake. I am also forced ot keep a distance between the parts because of the fact that the Fabs here will increase the setup cost by a lot if I were to place components right next to each other. I don't know why it's the case and I assume that they might be doing manual assembly. So that has been a main reason of aversion to placing components right next to each other.I have no problems adding features. However, the target price is 7USD with the profit margin included. And it already costs roughly $5 to make it. I am sure that price can be brought down. So, I shall try to add Bluetooth and/or Wi-Fi to the boards.

author: atulravi
author_rank: Contributor
timestamp: January 25, 2024, 10:10:28 am
content: Damn. The JST Connector on its own for qwiic from my local supplier costs like $1. A major cost increase if I were to add it. And importing is not ideal since customs will make the cost shoot up as well. Maybe, I add a hybrid footprint and let the end user decide to pay the premium of get a header in the Qwiic ports instead?

author: guenthert
author_rank: Frequent Contributor
timestamp: January 25, 2024, 10:52:33 am
content: There are some good thoughts, but I'm surprised nobody addressed the big elephant in the room yet: the RP2040 isnot5V tolerant, it's datasheet is quite clear about that. It might accidentally work, but I'd guess, it's not the way to make friends. Without level shifter it won't be Arduino Uno compatible (note that Adafruit's metro RP2040 is Arduino-shape).(while I appreciate that all is open at GitHub, the repo is a tad misleadingly named, I thought. With that name, I would have expected an Arduino compatible board based on a PIC)

author: atulravi
author_rank: Contributor
timestamp: January 25, 2024, 11:02:09 am
content: Quote from: guenthert on January 25, 2024, 10:52:33 amA level shifter is also being considered. Regarding the name, even I am not as happy. The issue is the term Picouno has been used by many, so I had to settle for Picuno. I should probably come up with a better name. Also, it will be marketed as an Arduino clone device and not as a direct Arduino per-se. I am considering adding 13 BSS138s for the level shifting on the Digital GPIOs alone.

author: tszaboo
author_rank: Super Contributor
timestamp: January 25, 2024, 11:28:57 am
content: Quote from: guenthert on January 25, 2024, 10:52:33 amYou are right. Also, the Uno has an IOREF pin, which all the shields are supposed to take into account.So the original idea was that the shield is supposed to level shift to 5V or 3.3V or something else. There was no clear specifications so almost nobody did, and it's not compatible in practice with most stuff in the end. The moral of the story is to write specifications.

author: atulravi
author_rank: Contributor
timestamp: January 25, 2024, 11:33:05 am
content: Quote from: tszaboo on January 25, 2024, 11:28:57 amInteresting point about the IOREF pin. The specs must be clearly stated and voltage potentials are to be mentioned properly is what I deduce for the end user. So I shall do that also, the idea of having level shifters in general does not seem that bad. So I will be implementing it mostly.

author: atulravi
author_rank: Contributor
timestamp: January 25, 2024, 02:16:55 pm
content: Ok, Update. I modified the deign in such a way that GPIOs 0-5 are level shifted to 5V. But I am not sure whether I will proceed or not. Would also appreciate if someone could confirm whether the level shifting will work or not. The design is based on Sparkfun's level shifter.KiCad files:https://github.com/atulravi/picuno/tree/main/v2/kicad/v2.1

author: abeyer
author_rank: Frequent Contributor
timestamp: January 25, 2024, 07:00:24 pm
content: Quote from: atulravi on January 25, 2024, 09:25:38 amI'm confused, not introducing incompatibility with existing enclosures was exactly my point. No existing uno form-factor board I've ever seen extends the pcb under the connector -- so any change to that ismorelikely to be incompatible with existing designs.

author: atulravi
author_rank: Contributor
timestamp: January 25, 2024, 08:43:43 pm
content: Quote from: abeyer on January 25, 2024, 07:00:24 pmAlright. I can understand your confusion completely. The enclosure that they use is nearly an inch thick. This leads to the USB B port and the DC jack to be nearly flush with the case when mounted. If I were to leave the USB C port towards the back without the PCB extension to overcome the loss of the USB B port, the C port will be stuck in the back and cannot be accessed with ease without having to annihilate a USB C cable. Hence the need for the PCB to have that outline that is the same width and length of the USB B port. The USB C port will effectively be at the same position as the USB B port with respect to that case. However in hindsight it's probably a better choice to place the connector in the back for better compatibility with pre existing cases than the one niche enclosure I am trying to specialise for.

author: PCB.Wiz
author_rank: Super Contributor
timestamp: January 25, 2024, 09:51:59 pm
content: Quote from: atulravi on January 25, 2024, 08:43:43 pmI've seen development boards with dual USB footprints or connectors. USB-C and something else (often USB-A)

author: tooki
author_rank: Super Contributor
timestamp: January 26, 2024, 09:02:18 am
content: Quote from: atulravi on January 25, 2024, 10:10:28 amOrder from JST directly. The prices are way lower than any distributor.

author: atulravi
author_rank: Contributor
timestamp: January 26, 2024, 09:28:01 am
content: Quote from: tooki on January 26, 2024, 09:02:18 am200 pieces, with each at $0.5 roughly. Comes out to 40INR. After customs and shipping cost will come out to roughly a dollar. That is my key concern. The PCBs that I usually order for roughly 5000INR, Customs+DHL duties later, it comes out to nearly 8000 INR. Similarly, even the JST connectors will come out to the same cost (assuming they ship from China). If they ship from Japan, it may be cheaper. However, shipping cost maybe higher. So, the trade-off is putting me away. Your thoughts?

author: tooki
author_rank: Super Contributor
timestamp: January 26, 2024, 09:44:54 am
content: Quote from: atulravi on January 25, 2024, 02:16:55 pmI dunno man, the work just seems… very rushed and without attention to detail. From the messy schematic to the erratic PCB layout, there’s a lot of room for improvement.-You can get important components much closer without causing trouble.-Follow your own schematic notes about layout: you have various notes saying to place things close, but then in the layout you don’t actually do it.-Standardize on smaller chip components rather than the random assortment you have now.-Using a smaller crystal would let you place it much closer. Note that it’s good practice to not route traces under a crystal (other than its own), so a big crystal means a big dead area on the other side of the board.-Clean up your traces: many take unnecessarily convoluted routes, and many have unneeded bends, tails, junctions, and width changes. Have traces exit pads straight for a bit before going into a 45 degree angle. Doing so right at the pad reduces pad-to-trace clearance significantly. (On your USB lines, it also causes your impedance to jump around. Use a controlled impedance differential pair to make kicad enforce it for you.)-Move traces and components away from the edge of the board.-There’s no reason to have everything bunched onto the one side of the board. You could easily move the MCU away from the USB side of the board to give your layout space near the power and USB connectors. That would let you restore the mounting hole you removed.

author: tooki
author_rank: Super Contributor
timestamp: January 26, 2024, 09:56:21 am
content: Quote from: atulravi on January 26, 2024, 09:28:01 amI think you should stop guessing and instead use the shipping calculator right on the website to see what your actual shipping cost would be. (You may be surprised.) Also, the gold-plated version of that connector is cheaper and actually in stock…I can’t predict what the customs fees will be, nor what FedEx (JST’s shipper) charges to process them. Presumably the FedEx fees are a flat rate, making it smarter to place large orders that spread the cost over more units.And of course you could always see if there are cheap clone connectors on AliExpress.

author: atulravi
author_rank: Contributor
timestamp: January 26, 2024, 10:07:31 am
content: Quote from: tooki on January 26, 2024, 09:44:54 amA lot of great advice. I shall change the crystal for sure. And if possible, even re-route the board altogether. I am sure majority of the issues will subside if I were to do so. I never considered impedance to be a major issue since I am relying on USB 1.0 speeds. However, doing so will probably be useful in the long run.Quote from: tooki on January 26, 2024, 09:56:21 amSurprised indeed. Shiping is free for over 100USD from JST. Nice. AliExpress is long banned in India. Majority of AliBaba's competitors as well. Taobao whatever you may think of. Temu as well. So that is a dead end. So, I don't think adding a Qwiic connector is not going to be a major cost increase after-all and I should go ahead.

author: tooki
author_rank: Super Contributor
timestamp: January 26, 2024, 10:24:07 am
content: Weird: when I checked if before (and again just now) that isn’t the shipping terms it gave me for India.

author: atulravi
author_rank: Contributor
timestamp: January 26, 2024, 10:29:48 am
content: Quote from: tooki on January 26, 2024, 10:24:07 amThe order total comes just shy of 100 USD for 200 pieces. So, shipping is pretty much free (according to their calculator atleast).

author: tooki
author_rank: Super Contributor
timestamp: January 26, 2024, 07:57:35 pm
content: Quote from: atulravi on January 26, 2024, 10:29:48 amWhat I mean is that I don’t know where you got the idea that $100 is the threshold for free shipping. As the screenshot I posted clearly shows, the threshold is $50 for shipments to India.

author: atulravi
author_rank: Contributor
timestamp: January 26, 2024, 09:53:33 pm
content: Quote from: tooki on January 26, 2024, 07:57:35 pmYeah, I could've phrased my response better. I admit. Since the fact that the cart total is over the threshold at 100 bucks, shipping is pretty much free is what I meant. My bad.

author: tooki
author_rank: Super Contributor
timestamp: January 27, 2024, 02:10:12 pm
content: Quote from: atulravi on January 25, 2024, 09:25:38 amIf your gross margin is only $2 of $7, then you’ll be selling them at a loss by the time you factor in all of the ancillary costs that go into selling a product. Things like packaging, warranty fulfillment, and overhead.

author: atulravi
author_rank: Contributor
timestamp: January 27, 2024, 04:27:42 pm
content: Quote from: tooki on January 27, 2024, 02:10:12 pmTrue. The cost breakdown is as follows:(Per board) -Components Cost: 148.21PCB: 197.78Packaging: 20.50Assembly- 150Is Roughly 560 INR.However, Since the boards will be made in bulk, (Production of 100-200 boards)Components: 110.10PCB: 62.5Assembly - 100Packaging - 20.5Which comes out to roughly: 293.10 (Roughly 3 bucks)And considering 7 USD is ~ 590 INR, It's a 300 INR margin. However, shipping will be on the customer's side. And the only warranty that I will deal with will be DOAs. But I'm sure pricing it at maybe 8-10USD will be a lot wiser. But it does affect customer base a lot (regionally especially). So, the ideal price I'm aiming for is 7 but it may stray to a few dollars more.(PS. these quotes are from one fab at the moment. I am still doing research parallelly to see who gives the best price: quality ratio.)I'm also applying to crowd supply to make use of their distribution facilities with Mouser (hopefully). So, another overhead that will be added if they were to accept would be the 12% (~0.84USD= 64INR) which will also add up.Then the 7-dollar goal will be a stretch, but I am sure, that I can somehow search upside down and get excellent quality at low costs. Manufacture in China is ruled out as of now since the import duties on their own will be enough for me to shut shop.

author: atulravi
author_rank: Contributor
timestamp: June 15, 2024, 09:28:34 am
content: After taking in quite few suggestions and upgrading the board. Here is the latest version V3.