Recent Posts

Pages: 1 [2] 3 4 5 ... 10
11
TCB Dev / Re: High DPI Issue
« Last post by LukeZ on January 15, 2024, 02:45:01 PM »
Hi Chris, again apologies for having missed your posts. I've realized that I'm having problems getting forum notifications so I need to check in much more often.

I must admit to knowing absolutely nothing about Macs, having never so much as touched one in my life (a deliberate choice). I really have no idea what would be involved in compiling for Mac, but maybe for someone comfortable with that OS and a bit of programming experience it might be less difficult than I imagine. It awaits someone to try, but be careful also, because once you create something you then have to maintain, update, and support it for life, which we don't always think about at the beginning!


Oh and I would be happy to recommend changes on a pull request from the fork if helpful.   

With regards to the Windows version, yes do feel free to recommend changes using pull requests, though we can also discuss here in advance. The main update to OP Config that would be nice is exactly what you've identified, the issue with High DPI screens. That appears to be an easy fix as you've discovered, but fixing all the things that the fix breaks may prove more tedious. However again I would welcome with gratitude any improvements others want to devote themselve to, and will try to help as I can.


One of the main differences in the later version is the settings in the user file but of course that contains user specific environment variables/paths and aren’t great for inclusion in the source control as it isn’t transferable between different environments.  Might have a think about that too.
I may not know what this file is if it's specific to later versions of Qt, but even in my version there is an OpenPanzerConfig.pro.user file which I believe is the equivalent of what you're talking about, and yes, it's not of much use to share it. I think it could probably be left out and theoretically the environment would create it for whoever is compiling the source.


I would love to build a board specifically or the Heclo hat but I’m starting with a few separate components at the moment just to get my head round it a bit.
That is definitely the right approach to take! The result of your experiments with individual sections will go a long way to informing what kind of board you will ultimately want. Starting with a grand unified design at the beginning will always result in a lot of revision later on, or anyway that's my experience.

12
Open Panzer Help / Re: OP Panel size
« Last post by skb6666 on January 15, 2024, 12:32:13 PM »
Thanks, Yes I will put updates up. Just finding time to fit everything in :)
13
Other Open Source Projects / Re: Standalone Tank IR
« Last post by LukeZ on January 15, 2024, 12:22:46 PM »
So every time at least 1.9V is there in this pin. BUT! When I checked this pin switched off (fortunately my switch is disconnecting the + wire) connecting multimeter to battery +  and airsoft pin it was around 7V visible (not much less then the battery actual voltage *DOUBLECHECKED it was 6,64 - 6,62Volts). When switching on the MFU its dropped from 7V to 1.99V and stayed there until I (I mean, my dear wife :D who helped me) fired the tank and it was 7.04V again (which is the actual battery voltage)
Ok, this is interesting, and I believe explains the "phantom firing" that you experience. On a 5 volt Arduino like the Nano, the documentation says that any signal over 3 volts is considered HIGH (1) and any signal less than 1.5 volts is considered LOW (0). In between 1.5 and 3 volts is where the pin switches from one state to another, and we can't  predict exactly whether the Arduino will read High or Low.

If I understand your description correctly, the Taigen airsoft pin initializes at 1.9 volts when the MFU is turned on, which is right in the in-between range on the Arduino, and sometimes the Arduino is interpreting this as Low and firing the cannon. After the first cannon fire of the Taigen, this pin reverts to +V Batt as we would expect (except at the moment when the cannon is fired, in which case I assume it must be held to Ground. Probably a better test would have been to connect your multimeter black wire to Ground, and the multimeter red wire to the Taigen airsoft pin.)

Anyway, there are two problems here. One is the fact that (at least after the first cannon fire) the Taigen airsoft pin rests at close to +V Batt, which is higher than the 5 volt limit of the Arduino pins. The easiest way to solve this is to use a voltage divider, I have attached a picture below. It is created with only two resistors so is easy to do. The absolute value of the resistors is not as important as is the ratio between them. I chose 3.3k and 4.7k because they are common values and give us a ratio that will cut the input voltage by about 40%, so 7 volts input will become something closer to 4 volts on the output, this will still be read as High by the Arduino, but it won't exceed the 5 volt input limit. This ratio will protect the Arduino even if you use a fully charged 2S LiPo that could be as high as 8.4 volts (will be divided down to 5 volts).

However, there still remains the second problem, which is that on startup the Taigen airsoft pin is basically in a low state, and that causes phantom firing on the Arduino until you fire the Taigen and only then does the Taigen begin to act in a reasonable way. I don't see an easy solution to this problem. It is bizarre that the Taigen acts this way, but I have come to expect bizarre behavior from Chinese electronics, and sadly this behavior is not what we want.


No, those are not activated until receiving a signal from a microswitch (it is located in the airsoft or recoil unit and pushed mechanically by those units). The initial triggering signal is from the airsoft, anyway :( Or.... maybe that should be solution if I connect the airsoft signal to the microswitch pin and then, the MFU triggers the gun fire function then sends out the 5V to IR. If so, I have to redesign my board again, and order it from pcb manufacturer :'(
You're right, I forgot! The Taigen does require that physical switch to be activated by the airsoft/recoil unit before it will do the Flash and IR. That is annoying. Yes, I suppose you can try your suggestion, and you can certainly at least do a test without a new PCB, just connect some temporary wires. The only thing I am not sure of is what the Taigen MFU expects from the trigger switch - is it expecting a high or low signal? And even if it is expecting a low signal, maybe it too will be confused by the 1.9 volts from the airsoft pin at startup, so you might end up with phantom firing anyway. But I guess you'd get the phantom fire out of the way the instant the Taigen is powered up, and in that case possibly a delay could be added to the Arduino to ignore it.

Only some testing can answer these questions. I'm sorry I don't have any of this to try on my end, but let me know what you discover.
14
Open Panzer Help / Re: OP Panel size
« Last post by LukeZ on January 15, 2024, 11:08:19 AM »
Congrats on building three boards from scratch, that's an accomplishment! Keep us posted on how you get on with them.
15
Open Panzer Help / Re: OP-Config not finding I-Bus radio with an FS-A8S and Arduino Mega
« Last post by LukeZ on January 15, 2024, 11:06:46 AM »
Hi Chris, sorry for the slow reply!

A little confused that the MG LED doesn’t have a pin on Arduino but I assume that is just a PIN number allocation in the code and I should be able to tweak that.  I guess the Arduino pin layout is the way it is because you designed the pins were they were convenient on the chip when mounted directly but they are relocated to different places on an ardunio board?
You figured it out, but for anyone else curious, yes, there are a few pins on the ATmega2560 which are not used by the Arduino project, but they are still there and on the TCB board I chose to use some of them. For those using a stock Arduino Mega board, those pins will have to be changed, but this can be done as Chris says by uncomenting the "#define TCB_DIY" line in the Settings.h file, or what is even easier, just flash the "TCB - DIY Version" firmware to your Mega from OP Config where all this is already taken care of.


Pressing and holding the bind button for 2 seconds (while powered and bound to the transmitter) it suddenly started spouting serial data out!   Woohoo!  I now have 10 channels in Op-Config to play with.
Thanks for reporting back! The documentation with these Chinese companies is never great. I've added a link to your post in the Wiki under the Receiver Selection Guide for anyone else who might encounter the same confusion, so thanks again for resolving that and helping out future users!
16
Open Panzer Help / Re: OP Panel size
« Last post by skb6666 on January 12, 2024, 05:45:14 AM »
It wouldn't normally be a problem, but have just built 3 TCBs from scratch. Have got them flashed ok, but need to do some testing on them. So need to look at all the menus. I was lucky with parts as I actually purchased alot of the parts years ago before the all vanished and have only just had time to get them done. They all connect and communicate ok so that's a good start.

Thanks

Steve
17
Open Panzer Help / Re: OP Panel size
« Last post by LukeZ on January 11, 2024, 11:03:59 AM »
Thanks Chris for helping out. And yeah, I apologize Steve for this mess. The reason I never fixed the High DPI issue is that doing so breaks other things which I've never had the time to resolve. Years ago there weren't many people using such high resolution monitors, though today it's obviously more common. Hopefully this workaround gets you by for now.
18
Open Panzer Help / Re: OP Panel size
« Last post by skb6666 on January 11, 2024, 07:19:05 AM »
Worked great.
Thanks
Steve
19
Open Panzer Help / Re: OP Panel size
« Last post by skb6666 on January 11, 2024, 07:11:10 AM »
Thanks, will give it a go.
Thanks for the help
Steve
20
Open Panzer Help / Re: OP Panel size
« Last post by FuzzyJack on January 11, 2024, 07:05:06 AM »
I had a little play and it does improve a bit if you scale the layout down a bit.

It's still not perfect though.  I've attached two screens.   Both are on a high resolution of 2880*1800.  One at 200% text scaling, the other at 100% (you don't appear to go smaller).

Interestingly, if you have OP-Config open when you are up at 200% and then scale down to 100% it also scales most of the field values (although not all of them) and it's much more readable.

If you scale first and then open OP-Config it doesn't scale the field values so well.

Hope that helps for now anyway.
Pages: 1 [2] 3 4 5 ... 10
bomber-explosion