Registration Notice

Due to increased spam, forum registration must be manually approved by a moderator! Please see this post for instructions.

*

Offline Lotuswins

  • 152
    • View Profile
  • Roseburg, oregon
Re: Testing TCB Firmware with Stock Arduino Mega
« Reply #195 on: April 29, 2020, 12:40:28 PM »
Hi Luke,

Thanks for answering.  My shield does not use the 5v output from the Arduino reg, but the digital pins do output a 5v signal, so too many outputs for the little reg they installed?  However unlikely that is, I did rob an old reg chip off a parts arduino and both new ones are now working fine (it is an 800ma output also), so as you surmised, it is probably the chinese made issue.

Oh well, I've ordered from another source so we will see if they will be more reliable.  I have two Robotdyn ones functioning okay, from older manufacture, and these two new ones failed in one week.....only discernible difference (to my humble observation skills) are the 5v reg stampings.

Jerry


Re: Testing TCB Firmware with Stock Arduino Mega
« Reply #196 on: July 09, 2020, 07:38:56 AM »
Hello everyone!

I have been following the Open Panzer project for a while and in my education as a electronics technician I made a "shield" that fit on an arduino mega 2560 R3 board, with most of the functions of the Open Panzer TCB and the Open Panzer sound card onboard, plus some extras.

Instead of the L298 motor driver as the onboard drivers I have opted for 2 x VNH5050 chips which are similar to those found on the OP Scout ESC, but in a smaller package. They can draw 30A each and therefore should be adaquete to most aplications. I have also added 2 additional H-bridges to power the turret elevation and traverse motors, they can draw 3A each.

The high-current drivers have current monitoring which I have implemented into the TCB code so that throttle commands corrosponds to engine wattage instead of a PWM setting, this makes simulating a models scale power a lot easier, resulting in realistic slow down when going uphill or through rough terrain.

All in all this makes Open Panzer a stand-alone board with all the necessary components onboard (except for a radio recaiver I suppose).

It has been tested in so far 6 different tanks with great results.
 
I have attached the schematics and a pinout rendering for those interested.

 
*
MCU V3A4.pdf
(393.4 kB ~ Downloads: 25)
MCU V3A3 pinout.png
Testing TCB Firmware with Stock Arduino Mega MCU V3A3 pinout.png
Views: 81
IMG_20200325_142716.jpg
Testing TCB Firmware with Stock Arduino Mega IMG_20200325_142716.jpg
Views: 85
IMG_20200325_211209.jpg
Testing TCB Firmware with Stock Arduino Mega IMG_20200325_211209.jpg
Views: 77
IMG_20200325_211259.jpg
Testing TCB Firmware with Stock Arduino Mega IMG_20200325_211259.jpg
Views: 79
IMG_20200326_235035.jpg
Testing TCB Firmware with Stock Arduino Mega IMG_20200326_235035.jpg
Views: 73

Re: Testing TCB Firmware with Stock Arduino Mega
« Reply #197 on: July 10, 2020, 02:42:55 AM »
I could however use some help making some additions to the OP config, to implement some of the changes I have made, a little better.
In order to use 2 sets of onboard motor drivers I have had to "hi-jack" the code of one of the selectable ESC's, I chose the Sabertooth, but it would be neat to have an actual parameter that was called "Build-in driver (Motor C)" and "Build-in driver (Motor D)" or something like that.

I have also made some exspansions to the Forces of Valor IR library, defining ammo types with different armor penetration, and on the receiving end definitions of armor thickness (I'm also working on a directional IR receiver, making side and rear shots a possibility, with a higher chance to penetrate as a result). This is also something I wish to have implemented in the menues.

I know I am asking a lot, but I really wish to keep this project alive and we are a 1/16 rc tank club with about 20 members testing my creations out and the enthusiasm is high.

Best regards Kim Olsen Panzer Club Denmark.

*

Offline LukeZ

  • 978
    • View Profile
  • Edinburgh, Scotland
Re: Testing TCB Firmware with Stock Arduino Mega
« Reply #198 on: July 12, 2020, 09:08:47 AM »
Hello Kim! Your design is extremely impressive and interesting. Thank you for sharing! It is very educational to see the design choices you have made and the components you have chosen, I think a lot can be learned from this design. I see you have changed some of the pins in order to manage the onboard main motor drivers, it looks like you had to sacrifice PWM on the Hit Notify and Aux outputs? 

I may be willing to make some changes to OP Config on your behalf but it is something I will want to think about and I may not do it right away. Of course it would benefit you and your club but the extra options in the documentation will only confuse all the hundreds of other people who already have a TCB, so I have to weigh these things carefully.

In the meantime it would be great if you could make your project open source, including the firmware for the Arduino Mega, and board files and bill of materials for your shield. This could be hosted on GitHub. If you are able you can make a fork of the TCB firmware with your changes on your own GitHub, or if you prefer you can provide me the source code and I can fork it myself and host it on the Open Panzer GitHub page.

You may be interested to know that in fact all the functions could be simplified onto the Teensy 3.2 alone, eliminating the need for the 2560 altogether. In other words, we can combine both the sound card ability and all the rest of the TCB functions onto just the Teensy, including onboard main motor drivers as you have done, so that in the end we have a complete single board product. The 3.2 has barely just enough pins if we use some shift registers! I have started writing code for this but it is not yet complete and I don't know when I will have the time to finish it. I haven't even started on a board design. I am not spending much time in development this year due to other commitments, but if the project were to be revived someday I think that would be the way to do it. But for now it is just an idea.
NO SUPPORT THROUGH PM - Read why
Need a forum account? Read here
Open Panzer FAQs

*

Offline Lotuswins

  • 152
    • View Profile
  • Roseburg, oregon
Re: Testing TCB Firmware with Stock Arduino Mega
« Reply #199 on: July 12, 2020, 02:41:46 PM »
Hi Luke,

I'm just about finished with my shield, but am having difficulty with the airsoft.  I measured 1.7 amp max on my DVM for the airsoft unit, and I don't think the BC337 is up to the task since it won't even start the motor running.  BC337 is rated at only 0.8 amps, and the surge must be too much on motor start.

Would you have a recommended TO92 replacement in mind?

*
FatFingersOPTCBRev2.pdf
(45.81 kB ~ Downloads: 15)

*

Offline Lotuswins

  • 152
    • View Profile
  • Roseburg, oregon
Re: Testing TCB Firmware with Stock Arduino Mega
« Reply #200 on: July 13, 2020, 01:48:38 PM »
Hi Luke,

I just ordered these up to test...should work?  I hope not to have to modify the boards/submit a new board request since it took 3 months last time from Seed  :'(

jerry
*
ZTX650.pdf
(67.43 kB ~ Downloads: 14)

*

Offline LukeZ

  • 978
    • View Profile
  • Edinburgh, Scotland
Re: Testing TCB Firmware with Stock Arduino Mega
« Reply #201 on: July 13, 2020, 04:47:48 PM »
Hi Jerry, sorry for the slow reply. The ZTX651 looks like it should work fine, though I note the order of the pins appears to be reversed from the BC337, so you will just want to double check and probably flip it around when you install it.

Also, to get the full 2 amps out of that transistor you will want to reduce the base resistor to around 200 ohms, this is R4 on your schematic.

Let us know how it works!
NO SUPPORT THROUGH PM - Read why
Need a forum account? Read here
Open Panzer FAQs

*

Offline Lotuswins

  • 152
    • View Profile
  • Roseburg, oregon
Re: Testing TCB Firmware with Stock Arduino Mega
« Reply #202 on: July 13, 2020, 09:22:47 PM »
Thank you Luke, especially for the advice on the bias resistor. 

I hope to finalize everything soon if this works, all else seems okay.   I plan to share the eagle/gerber files along with BOM and details on assembly.  It should be a much easier build than the original, but same footprint and connectors though without some of the frills which I have never used in any of my 12 tanks that have OPTCBs.....

Anyway, hopefully it will help your awesome design continue on.  I cannot thank you enough.   :)

Jerry

Re: Testing TCB Firmware with Stock Arduino Mega
« Reply #203 on: July 14, 2020, 03:02:34 AM »
Hello Kim! Your design is extremely impressive and interesting. Thank you for sharing! It is very educational to see the design choices you have made and the components you have chosen, I think a lot can be learned from this design. I see you have changed some of the pins in order to manage the onboard main motor drivers, it looks like you had to sacrifice PWM on the Hit Notify and Aux outputs? 

I may be willing to make some changes to OP Config on your behalf but it is something I will want to think about and I may not do it right away. Of course it would benefit you and your club but the extra options in the documentation will only confuse all the hundreds of other people who already have a TCB, so I have to weigh these things carefully.

In the meantime it would be great if you could make your project open source, including the firmware for the Arduino Mega, and board files and bill of materials for your shield. This could be hosted on GitHub. If you are able you can make a fork of the TCB firmware with your changes on your own GitHub, or if you prefer you can provide me the source code and I can fork it myself and host it on the Open Panzer GitHub page.

You may be interested to know that in fact all the functions could be simplified onto the Teensy 3.2 alone, eliminating the need for the 2560 altogether. In other words, we can combine both the sound card ability and all the rest of the TCB functions onto just the Teensy, including onboard main motor drivers as you have done, so that in the end we have a complete single board product. The 3.2 has barely just enough pins if we use some shift registers! I have started writing code for this but it is not yet complete and I don't know when I will have the time to finish it. I haven't even started on a board design. I am not spending much time in development this year due to other commitments, but if the project were to be revived someday I think that would be the way to do it. But for now it is just an idea.

Thank you for the praise  :) Yes I needed an extra timer for the motor C and D PWM, not really sacrificed as such, they can still be PWM controlled they are just running at a different frequency XD.

Yes this should perhaps be an entire new branch of OP, to differentiate it. I do not intent to make things harder for the rest of the OP userbase. I will work on putting my designs on GitHub and make a fork on the firmware (I should probably comment a bit more in my code "gulp") I think i prefer it to be on the Open Panzer GitHub page, I think it will reach more people this way.

Yeah in my research I also considered going with Teensy alone (4.0 specifically) but due to time constraints before my exam, I stuck to the current setup. As an after thought, I considered the teensy 4.1 because of the plethora of outputs. STM32 F4 and F7 series would also be interesting. Many posibilities, a lot of coding required :D
I would be delighted to help you with the board design if you want on that teensy branch ;)

In my Frankenstein Leopard 2 I went to exam with I used the teensy 4.0 and an external DAC for the sound card (16bit sound is awesome!) that's what the EXT_DAC port on my design is for, a PCM5102 based module

Cheers Kim

Re: Testing TCB Firmware with Stock Arduino Mega
« Reply #204 on: July 15, 2020, 08:18:46 AM »
Here are the schematics for my latest build, it is drawn in KiCad (free open source)
I have attached a zip with the compiled gerber files aswell.

I will post the custom code later.

Cheers!
*
MCU V3A4 KiCad.zip
(378.89 kB ~ Downloads: 11)
*
MCU V3A4 Gerber.zip
(865.26 kB ~ Downloads: 11)

*

Offline LukeZ

  • 978
    • View Profile
  • Edinburgh, Scotland
Re: Testing TCB Firmware with Stock Arduino Mega
« Reply #205 on: July 16, 2020, 12:06:25 PM »
Thanks for the Gerbers, I took a look at them in KiCad. You have done a professional layout job, I am impressed. You said you used this project for an exam, are you an engineering student? I think you deserve a good grade, I hope you get one!

I look forward to inspecting your firmware and I will be happy to host it on the OP GitHub, it should be possible to make you a contributor so you can maintain that repository. It also should not be a problem to add an entry to OP Config Firmware tab so users can select your firmware for download/flashing.

As you say, with all the microcontroller advancements constantly being made there are now many tantalizing possibilities, but people who possess time and skill are necessary to realize them, and in so far as there is no great financial reward for doing this work, these must also be special people who have other motivations (educational achievements appears to be a good one!)

Thank you for the offer to help with board layout, I will keep it in mind and let you know if I can get the design to the layout stage.
NO SUPPORT THROUGH PM - Read why
Need a forum account? Read here
Open Panzer FAQs

*

Offline Lotuswins

  • 152
    • View Profile
  • Roseburg, oregon
Re: Testing TCB Firmware with Stock Arduino Mega
« Reply #206 on: July 25, 2020, 03:10:18 PM »
Hi Luke,

Well I think I'm done with my shield.  I called it 'FatFingers' since us old folks can't seem to manipulate the SMD components too easily. 

I've included the Gerber zip file, and in the Here is the FatFingers V2 boards zip is the PDF of the schematic, the BOM in excel, an assembly writeup in Word, and the Eagle files.

I hope this helps someone who wants a TCB but can't manage the SMD and flow soldering.  Let me know if you have any comments?  I've assembled 4 of these so far, with 6 more to go.  Takes me about 3-4 hours for one, but doing multiple takes less time per board.

Jerry
*
Here is the FatFingerV2 boards.zip
(859.37 kB ~ Downloads: 8)
*
FatFingersOPTCBRev2_2020-07-25.zip
(387.71 kB ~ Downloads: 8)

*

Offline LukeZ

  • 978
    • View Profile
  • Edinburgh, Scotland
Re: Testing TCB Firmware with Stock Arduino Mega
« Reply #207 on: July 26, 2020, 01:43:40 PM »
Jerry this is really great, I read through your write-up and examined the board in Eagle. I can tell you put a lot of time and thought into this, I was surprised to see you even kept the same mounting hole dimensions and connector layout! Thanks for being so thorough in the documentation and creating the bill of material, etc...

I have created a new section on the Downloads page called "Member Designs" and yours is the first design to be posted, and I've included links to the various board files and resources. (Kim, I will be happy to post your design there as well when all is ready!) I also put a link to your board on OSH Park under the OP account.

I noticed you mentioned trouble getting boards of adequate thickness from OSH Park, but although they do offer a thinner option, I believe the standard selection is 1.6mm thick which is what you recommend and which I agree is better. I did a test order at OSH Park and it looks like it comes to about $40 US for 3 boards, which seems reasonable. However SEEED is also a good place to order them so that is fine as well.

This may have already been mentioned earlier in the thread, if so forgive me, but did you ever find any other Arduino Mega boards besides the RobotDyn that uses the same footprint? Jürgen mentioned the generic Chinese "Mega2560 Pro Mini R3" boards which look very similar but I can't tell for sure if they are actually the same footprint or would be compatible with your shield. Anyway, if there are others you know of that would work let me know and I'll list them in the comments.

Over the years people have built quite a few different kinds of shields and partial shields, or assembled mostly functional TCB substitutes from various parts, but this one I think is the most complete project so far. It maintains all the functionality of the original board, can be built without advanced soldering techniques, and is well documented. I really do hope you get to experience the enjoyment of seeing someone else build and run your design!
NO SUPPORT THROUGH PM - Read why
Need a forum account? Read here
Open Panzer FAQs

*

Offline Lotuswins

  • 152
    • View Profile
  • Roseburg, oregon
Re: Testing TCB Firmware with Stock Arduino Mega
« Reply #208 on: July 27, 2020, 11:29:42 AM »
Hi Luke,

Thank you so much for the kind words, especially since mine is obviously an amateur effort.  One doesn't appreciate what effort goes into a boards design until one attempts his own!!  Your layout is really a piece of art!!  I can't imagine how long it must have taken to get all those bits and pieces to align and fit on a 2 layer board, it boggles the mind.

The Arduino I've located to replace the Robotdyn that works is from ebay: https://www.ebay.com/itm/274262551130.  I have two operating, so far so good.  I hope Robotdyn has fixed the 5v regulator issue, as I fear the ebay source will eventually dry up/change.... I will try again at Robotdyn, in the near future.  I could not find another 'commercial' outlet for the board, that would be a better source?

I think the OSH boards are better quality than the Seed version.  I was replacing that pesky transistor Q7, and the pads wanted to distort/lift on me with the Seed PCB.  The OSH pads seem to be better anchored to the substrate.  The reason I got the thinner board from OSH is that they don't offer the 1.6mm board and 2 oz. copper.  I have a good friend who I went to school with that went into the electronics field, and he recommended I use 2oz copper.  I'm not sure how 1 oz would work?  I really didn't do any current calcs on the board, simply went with as large a trace that would fit in the confines for other than signals (smoker, airsoft, etc.).   Also, the purple is a nice relief from the standard green color  8)

I feel honored that I'm the first on the Members Design!!! thank you.....Jerry


*

Offline LukeZ

  • 978
    • View Profile
  • Edinburgh, Scotland
Re: Testing TCB Firmware with Stock Arduino Mega
« Reply #209 on: July 29, 2020, 09:35:42 AM »
Thanks for the link to the eBay boards, and on closer examination it looks to me that the pro mini boards Jürgen mentioned will also work, there are minor differences but overall it's the same footprint. I made a note about these in the description on the Downloads page.

That is a good point about copper thickness, you're right OSH only offers thicker copper on their thinner board for some reason. I did a rough calculation for the smoker portion of your board and even with the 32 mil trace width you use, and even at 2 oz copper, the maximum calculated limit of those traces is only 1.7 amps. At 1 oz copper it drops to about 1 amp. I don't recall exactly how much current the generic Taigen/Heng Long smokers pull, the heating element itself was about 1/2 amp but then there is the current of the motor as well. (Actually it seems you measured one at 2.1 amps once)

It highlights yet another of the many aspects of board design, aside from merely squeezing everything into a finite area. This is why we often use planes rather than only traces for high current signals, or polygons if we don't have the luxury of covering the majority of a board layer with copper. Another method is to run double traces, one on top of the board and one on bottom, this effectively doubles your copper thickness without increasing the trace width, though of course you need to have a clear run on both the top and bottom for that to work. Component placement also helps, we can try to locate high current outputs/transistors as close as possible to the incoming power source, in order to keep trace length short. We used all these and more on the original TCB, which was produced using only 1 oz copper. However I will say, that although more difficult to assemble, an SMD board does make life easier in other ways, for one we need fewer traces on the bottom of the board, and fewer interruptions generally on the bottom due to fewer through-holes, so this makes it easier to to have large power planes on the bottom layer.

In your case I rather doubt it will be an issue, but you can keep an eye on your boards for signs of overheating. There is still a little room to increase power handling on your design but I'd just use it and see what empirical evidence tells you before feeling like you should launch into an overhaul.
NO SUPPORT THROUGH PM - Read why
Need a forum account? Read here
Open Panzer FAQs

 

bomber-explosion