Many of you know that I am working on a production robot called Rafiki. Because it is production, I have had to do some circuit board design to limit the number of wires that are strung inside of Rafiki. I decided that I would use USB type A wires for as many of the wire connections as I could for a couple of reasons. The USB type A cable offers 4 wires and is easy to break out to individual wires once to the wire destination. The max length that I need to run a wire is 3’ and the wire specs handle my needs. This also reduces the wire count by 4 times and is just enough wires to meet my needs. The USB Type A cable is a very common cable and allows easy and dependable connections to be made.
Most of the time, you will either have 2, 3 or 4 wires needed for a connection. 2 would be for things like sending serial commands to a device like a Sabertooth motor controller (ground and TX). If two Sabertooth motor controllers are in close proximity to each other, there should be no reason that two of these connections can’t share one USB A connection. Many times you will have Ground VCC and Signal for sensors. If the Amp draw is low for these, you would be able to use a USB Type A cable. I wouldn’t run servos through a USB cable as they are high amps, but a ping sensor, or IR sensor could use these cables easily. A 4 wire connections would be something like a Ground, Serial RX, Serial TX, VCC type connection. Anyway, you get the idea.
I have 8 subsystems in Rafiki, all of which monitor their own sensors and motors. Some of these communicate with other subsystems. For example, there are ground drop off sensors, car bumper proximity sensors and wheel control systems. These 3 systems are tied together so that if a drop off is detected or if there is an object detected within x inches, the robot will not start to move or will stop. After the stop command has been initiated from the motor controller a serial connection to the main robot computer is used from the subsystem controller to provide information back to the main robot computer. Inside Rafiki, there were wires connecting these sub systems together so that a really quick reaction to these situations could take place without needing to go back to the computer to then tell the motor controller to stop. As you can imagine, working on Rafiki got a bit confusing. To solve some of this, I built a PCB that would house 6 of the subsystem controllers. The other two are close to their associated devices which already used USB cables so adding these 2 to the main subsystem controller board was not necessary. The PCB is made so that the connections to the subsystems are built into the PCB and no longer use wires. I also placed the USB type A headers on the board so that the wires from these controllers would be accessible from the USB port headers on the board. This greatly reduced all of the little wires that are hanging off of the boards and placed them in one central location which helps to clean up the wiring issues. It would also provide more reliability.
I thought that building a PCB would be a difficult thing to accomplish. The design work had to be something that you would need an EE degree to understand, right? The software had to be expensive and the order process for ordering these boards had to either be a pain or would be very expensive. I thought to get a good board at a decent price, I would probably have to go to China, and then it might not be all that good, right? I was wrong and this is the real purpose for writing this. If you are still reading, congrats, you have gotten to the good part
In doing a lot of research online, I found a board manufacturer that had some great reviews. They seem to be the go to guys for small volume and inexpensive boards in the United States. Their reviews all stated how people were very pleased with the quality of their boards, so I started really looking into them. Their website is www.4pcb.com .
I wanted silk screening on the boards so that I could mark the boards with the appropriate information as my brain is getting old and information isn’t hanging out as reliably in there as it did 20 years ago. This was important to me. I also wanted a 2 layer board so that it could be simple and traceable using my eyes and not some crazy diagram that would get lost or accidently deleted. They have a package called the 33each board, which allows you to create 4 boards (60 square inches each) of the same type or design for $33.00 each. You can place multiple items in the same 60 square inch board. This allows you to build things like USB breakout boards for a lot less than what you would buy these for. This included everything that I wanted, but scoring would cost extra. I am going to be using some different tools for scoring/cutting these boards for testing the results and will post the results. They have other options for one off boards that cost more per board, but lower total price. For example, one board would have cost around $65.00 and 4 boards costs $132.00. The single board didn’t include silk screening though and as I said, this is important to me. I decided to give these guys a shot, but I had to do the design EE degree, right?
These guys make a software package called PCB Artist which ties in very closely to their ordering process. Eagle has a free version and there are many others also. I opted to go with PCB Artist in order to get this done and move onto other areas of my robot that need my attention. I am not an expert at these types of apps, but I found PCB Artist to be pretty simple. It has a large component library, is easy to use, is intuitive, allows you to design multi-layer boards, has tests that can be run to validate your design, has nets that can be defined so that you can associate pins to other pins and then have these nets connected using proper trace widths, and it has a feature that is pretty good for simple designs that helped me a lot. If you use nets, you can auto route your nets which uses the manufacturing rules to make sure that the routes are within the tolerances that are needed for production. If you have errors from the tests that you run, the location of the errors are marked for you to see the location of the error and to fix. This made designing the PCB simple really, once I understood the widths of the leads that needed to be used for different type of leads. This app also allows you to print your design (which could be used for etching if you wanted to) so that you can then verify that your components will fit on the board as you expect them to by setting them on the paper to make sure that the pins will align with the design. This app also allows you to use via's to transition between layers if needed. Use this sparingly as via's can cause some interference with communications signals. During the initial design, I had many of these on my board. I spent a day simplifying my design as much as possible and got these down to 2 via's on different signal connections placed a great distance from each other on the board. I wouldn't recommend getting overly complicated with your design as it will just introduce more complexity than is necessary and will probably introduce an issue that will not be easily fixable.
I finished the design, and clicked one button to order the board. I put in the 33each code so that I would get the deal I was looking for, and uploaded my design. Checks are performed by this software to make sure that there are not any issues that are not accounted for and you are alerted to any issues. The order went through without any issue. I did have a question for them and sent an email to them. 4 different people all checked to make sure that the answer to my question was received after a phone call from the production manager. I also cancelled an order without any issue. This was a test to see what I could expect from them.
I will post photos of the board that I receive. This isn’t the final board, but more of a test to verify that everything is as expected, but this got me thinking. This could definitely be used for the robot hobby and I plan on doing this for my larger builds. By doing this, I will be able to cut some of the cost of some of my simple electronic components by over 50%. It also should provide a cleaner install and more reliability. It is worth checking out if you haven’t. I don’t know what is available in Europe or other areas of the world, but in the US, this is a great option. I would suggest wiring your robot and making sure it works as expected prior to doing this, but it definitely has its benefits when you are nearing the end of your build.