-
Posts
1775 -
Joined
-
Last visited
-
Days Won
1
Content Type
Profiles
Forums
Events
Everything posted by Hansolo
-
Rotary incremental encoders like the one you are using will only give a sequence of pulses when it moves. This sequence will differ depending on the rotation you give it, but only send signals while you rotate; https://en.wikipedia.org/wiki/File:Quadrature_Diagram.svg This type is a very easy type to implement and I would recommend it when using LED or other type of displays for showing the channels. Then you remove the sync issue as the displays will always show what DCS is seeing anad you just tell the channels to go up or down. But the rotary incremental encoder will never tell you the current position. You can get rotary absolute encoders from which you can determine the actual position, as it has a specific set of outputs for a specific position. https://en.wikipedia.org/wiki/File:Encoder_disc_(3-Bit_binary).svg These comes in many different variants depending of use. If you are using the original switch on your TACAN then this is an absolute encoder. You sent me two PM’s, oneyesterday and one today. One states that you made the original left switch into a switch with one input per positions and tried to trick DCS-BIOS into seeing the left selector as a switch. The second PM was about using rotary encoder and you also tried to incorporate the right switch with my code but can’t get it to ready the port registers. I am currently travelling with work and have limited time. If you need assistance then you need to do the following; 1. Decide which of the two switches you want to implement first 2. Make a small wiring diagram on a piece of paper so that we can see how you connect it. 3. Make a matrix which shows correlation between switch positions and which pins will be grounded in this case. 4. Imbed the code you have used to solve the switch you decided from point 1 into the post you make With my limited knowledge to Arduino coding I have found that solving multiple problems at the same time ends up in a bowl hay where you will not be able to conduct sequential trying and testing to prove what works and what does not. Focus on one item at a time, code it, load it, try it. If it works then save the code with a name that you can go back to. If it doesn’t work go back to the step that worked before and rethink your strategy. For my TACAN code I ended up with 10 different saved versions, most which worked partly. An original TACAN is IMHO a very difficult panel to implement as DCS isn’t prepared for it. The ILS is a much easier panel to implement. Cheers Solo
-
Beautiful work Sir :thumbup: Cheers
-
You're most welcome Sir. Glad you got it working :-) Cheers Hans
-
Alburg & Boltz thanks a lot for the info. Much appreciated :thumbup: Cheers Hans
-
Can't hit anything with CCIP or CCRP in Missions.
Hansolo replied to Wicked.-'s topic in DCS: A-10C Warthog
IFFCC gets the wind data automatically while flying; https://forums.eagle.ru/showpost.php...0&postcount=42 https://forums.eagle.ru/showpost.php...83&postcount=5 You would be using CCIP for unguided munition, right? Cheers Hans -
Sweet jesus that looks good Calum :notworthy: That looks like the real deal man. Awesome work there my friend. I can see you have really started putting your Taig to work :thumbup: Keep those photos flowing Sir Do you mind sharing where you found the floating nuts? "must spread some rep around" - I'll rep you later :-) Cheers Hans
-
Very cool @jrsteensen thanks for doing this work :thumbup: Looks like a much easier solution than what I am doing. I think Tekkx is also doing some boards so end user will have more options to go for fitting the individual needs https://forums.eagle.ru/showthread.php?t=160526 Cheers Hans
-
KY-58 You're most welcome Sir. Have managed to get hold of a KY-58 some time back in decent shape. As usual the original panels need a good cleaning, and some touch up with paint especially on the light plate This is after cleaning and initial touch up; And from the rearside DCS-BIOS ready; It's the standard setup I have used for other panels. Should really go make a pre-made standard board for the communication but just donøt have the time to look into it right now :music_whistling: Now for the 'Zeronize' switch I had a chat with Deadman and he had an ingenious idea on how to get the feedback from the safety cover. Instead og using an ON-OFF toggle he suggested using an MON-OFF-ON or a MON-OFF-MON toggle switch. When the safety cover is flipped down then it presses on the toggle swicth thus moving it in the downward position. This input is then used for the cover position. By using the MOM function then the toggle will flip automatically into middle position when the cover is lifted. By using DCS-BIOS in standard mode then only the cover down input is defined. DcsBios::Switch2Pos ky58ZeronizeCover("KY58_ZERONIZE_COVER", PIN); Thus is not down then it must be lifted :-) It works beautifully @Deadman. many thanks for the assistance. The actual Zeronize function is just using the Switch2Pos function as well. One more panel done, plenty more to go :megalol: Cheers Hans
-
Another forum member found this (forgot who unfortunately) and I tried it out an can see your photos; https://chrome.google.com/webstore/detail/photobucket-hotlink-fix/kegnjbncdcliihbemealioapbifiaedg?hl=en Cheers Hans
-
You're welcome. If you go for a Mega 2560 you should be good. Cheers Hans
-
Hansolo's parts catalogue I use almost exclusive Ebay so can't say anything about Aliexpress. This is a list of the parts I am using. Some of the choises I have made are perhaps not the cheapest but it is a descion I had made based upon many thing; time consumption, price for other parts I am using, pcb design etc. It is in the end a descion you as a panel builder will have to weight against what you want to spend on it. Mega prototype shield; https://www.ebay.com/itm/Good-Prototype-PCB-for-Arduino-Mega-1280-2560-R1-R3-Shield-Board-DIY-/312051313556? Mega terminal board; https://www.ebay.com/itm/MEGA-2560-R3-Prototype-Screw-Terminal-Block-Shield-Board-Kit-For-Arduino/232393202659?epid=6004425993&hash=item361bb6dbe3:g:dtIAAOSwwzhZVyky I only use this for testing as it is expensive but easy to setup for a different panel Nano breakout board; https://www.ebay.com/itm/Nano-Terminal-Adapter-for-the-Arduino-Nano-V3-0-AVR-ATMEGA328P-AU-Module-Board/400387932408?ssPageName=STRK%3AMEBIDX%3AIT&_trksid=p2060353.m2749.l2649 Stepper driver board; https://www.ebay.com/itm/EasyDriver-Shield-stepping-Stepper-Motor-Driver-V44-A3967-For-Arduino/201414925354?epid=523921172&hash=item2ee543dc2a:g:E8sAAOSwBP9UXLju Haven't actually started using these yet IC sockets; https://www.ebay.com/itm/20-PCS-8-Pin-DIP8-Integrated-Circuit-IC-Sockets-Adapters-Solder-Type/172251930212?hash=item281b03de64:g:i1oAAOSwWnFWAmFF In case a MAX487 chip fails it can be replaced without soldering. Secondly you avoid the risk of damaging the IC with the heat during soldering. Brass standoff’s; https://www.ebay.com/itm/M3-x-4mm-60mm-Hex-Brass-Spacer-Female-Female-Screw-PC-Motherboard-Standoff-Riser/172251701345?hash=item281b006061:m:meKVFllD2MqSj3EwB1GtEuA I use 30mm and 60mm. Plastic spacers; https://www.ebay.com/itm/Nylon-Plastic-Non-Threaded-Spacer-Washer-Round-Standoff-For-M3-M4-M5-M6-M8-Screw/222738409333?ssPageName=STRK%3AMEBIDX%3AIT&var=521595265361&_trksid=p2060353.m2749.l2649 Plastic M3 screws; https://www.ebay.com/itm/M2-M2-5-M3-M4-M5-M6-M8-Plastic-Nylon-Screws-Round-Phillips-Pan-Head-Screws-Black/262148039660?ssPageName=STRK%3AMEBIDX%3AIT&var=560912959170&_trksid=p2060353.m2749.l2649 PCB prototype boards; https://www.ebay.com/itm/10X-DIY-Prototype-Paper-PCB-Universal-Experiment-Matrix-Circuit-Board-8-5x20-cm/232208343328?epid=509753568&hash=item3610b22120:g:Y8QAAOSwQNRXLBDc N-channel MOSFET’s; https://www.ebay.com/itm/5-IRF510-Vishay-Siliconix-MOSFET-Transistor-100V-5-6A-43W-0-54R-TO220-854040/361558136667?hash=item542e8b575b:g:x2UAAOSwq7JTz-bM Can handle 5.6A and 100V (plenty) https://www.ebay.com/itm/50x-Stk-2N7000-N-CH-FET-60V-0-2A-200mA-350mW-5Ohm/192339856527?ssPageName=STRK%3AMEBIDX%3AIT&_trksid=p2060353.m2749.l2649 Can handle 200mA, 60V so plan to have these as backup where I use 12/28VDC bulbs but have not used them yet MAX487 communication chip; https://www.mouser.dk/ProductDetail/700-MAX487CPA I have started using Mouser.com instead of China after I got a bad batch of chips which cost me quite a lot of time to figure out. Yes they do cost $2.70 but it’s a price I am willing to pay considering most of the other parts aren’t cheap either. D-SUB / DB9 connector; Male; https://www.ebay.com/itm/10pcs-D-SUB-9-Pin-DB9-Male-Solder-Type-Socket-Connector/172133965436?hash=item2813fbde7c:g:clAAAOSwZ8ZW5vUe Female; https://www.ebay.com/itm/10pcs-D-SUB-9-Pin-DB9-Female-Solder-Type-Socket-Connector/172133973215?hash=item2813fbfcdf:g:M2IAAOSwZQxW5vdC You can most definitely find some of the parts cheaper, as many of them comes with many different suppliers. Cheers Hans
-
Hmm I can't see anything out of the ordinary :cry: Have you tried to include the master caution light to see if it recieves communication correctly; //Master Caution Light DcsBios::LED masterCaution(0x1012, 0x0800, 13); I would suggest that for future installs that you use a 8-pin IC socket for your MAX487. In case a MAX487 chip fails it can be replaced without soldering. Secondly you avoid the risk of damaging the IC with the heat during soldering. Your toggle switches have the common connected to ground, right? So that you pull down the inputs when activating a toggle switch. I found the post with the 100nF capacitor for the MAX487. Ian says it's between ground and Vcc on the MAX487, but since I am running directly from the voltage supply on the Nano/Mega it already has a 100nF capacitor on the Arduino side. Cheers Hans
-
Excellent work Romeokilo :thumbup: Cheers Hans
-
I haven't used any additional components so far for the RS485 bus. I know Rocketeer got confirmation from Ian that a 100pF capacitor should be used for all MAX487 chips for stabillity, but I don't know where to put it so haven't. In the datasheet for MAX487 a 100pF capacitor is mentioned for C1 & C2 but that is for a driver/receiver timing test circuit. I just did a small test pcb for Alburg; In this picture the following colors apply Power for MAX487 chips: WHITE +5V from Mega BROWN GND Power for Nano is via a USB charger Commumincation between the two MAX487 chips: GREY A-line PINK B-line Communication between MAX487 and Arduino's: GREY DI PINK R0 BLUE DE&RE A few more shots; Master (Mega) code; /* Tell DCS-BIOS this is a RS-485 Master. You will need to flash this to a Mega 2560. */ #define DCSBIOS_RS485_MASTER /* Define where the TX_ENABLE signals are connected. You can connect up to three half-duplex RS-485 transceivers. Arduino Pin RS-485 Transceiver Pin TXn ------------------- DI (driver input) RXn ------------------- RO (Receiver Output) UARTn_TXENABLE_PIN ---- /RE, DE (active low receiver enable, driver enable) If you have less than three transceivers connected, comment out the corresponding #define UARTn_TEXENABLE_PIN lines for receivers that are not present. */ #define UART1_TXENABLE_PIN 2 #define UART2_TXENABLE_PIN 3 #define UART3_TXENABLE_PIN 4 #include "DcsBios.h" void setup() { DcsBios::setup(); } void loop() { DcsBios::loop(); } Slave (Nano) code; /* The following #define tells DCS-BIOS that this is a RS-485 slave device. It also sets the address of this slave device. The slave address should be between 1 and 126 and must be unique among all devices on the same bus. */ #define DCSBIOS_RS485_SLAVE 100 /* The Arduino pin that is connected to the /RE and DE pins on the RS-485 transceiver. */ #define TXENABLE_PIN 2 #include "DcsBios.h" /* paste code snippets from the reference documentation here */ //Master Caution Light DcsBios::LED masterCaution(0x1012, 0x0800, 13); //Master caution reste DcsBios::Switch2Pos ufcMasterCaution("UFC_MASTER_CAUTION", 12); void setup() { DcsBios::setup(); } void loop() { DcsBios::loop(); } I am running dcs-bios-v0.7.1. Cheers Hans
-
Hmm Alburg has the same problem. I've 14 panels running this way so I don't think it's DCS-BIOS issue. Can you do me a favour of posting the codes for both Master and Slave, please. Does your slave code works when you insert the functions into a non RS485 sketch and run it of USB? Also you need to post some pictures showing the wires in order to trace them remotely. Cheers Hans
-
That is some beautiful work your have done there. That is true pit building quality right there Sir :thumbup: Thanks for sharing your incredible works :thumbup: Cheers Hans
-
It's not loaded in the cartridge. IFFCC is automatically getting the data as the aircraft is flying. https://forums.eagle.ru/showpost.php?p=1865490&postcount=42 https://forums.eagle.ru/showpost.php?p=3346883&postcount=5 If you make an active pause while flying, do you see a change in the PBIL when you change the wind data? Cheers Hans
-
I plan to get my UHF up and running. I got the pins mapped out but some of them are common so I will have to figure out a system to make it work. The AN/ARC-164 (V) comes up on Ebay from time to time but since they can be made workable if you are certified, they are quite expensive. Last set of 4 went for about $2300. Cheers Hans
-
Hi Gary, No I haven't found a solution for when the channels gets above 99 yet but if you figure out one I'd be happy to hear about it. I removed all original wires and started from scratch. The original IIRCC had some internal crossovers and as you can see from post #180 I deliberatly removed some of the pins as soon as had a matrix that would give be one unique combination per position. Cheers Hans
-
If you want one landing gear panel that works for all your aircrafts then you need to have that panel run on a joystick controller board. I can't see anything technically wrong with running an Arduino for KA-50's ABRIS and another for the A-10C's CDU. If you fly the KA-50 and by accident press the CDU on the A-10C the Arduino will send a command to DCS but since the module doesn't match nothing will happen. It's fairly simple task to re-program the Arduino if you are running it via USB. If you are running it via RS485 then you need to disconnet it from the communications chip before programming it, otherwise the program wont load. As for the diode matrix I seen a ready made one so best guess you will have to do it yourself. Cheers Hans
-
You are off to a good start Sir. I am sorry to say but you may just get bidden by the cockpit building bug :lol: What do you intend to use for interface with DCS? Cheers Hans
-
DCS-BIOS CMSP Mode Select SwitchMultiPos Issue
Hansolo replied to Pavespawn's topic in Home Cockpits
It's the exact same as romeokilo explained you here; https://forums.eagle.ru/showpost.php?p=3396378&postcount=2 Remove the _0, _1, _2, _3 & _4; const byte cmspModePins[5] = {8, 9, 10, 11, 12}; DcsBios::SwitchMultiPos cmspMode("CMSP_MODE", cmspModePins, 5) You just change out the PIN_0, PIN_1 etc with what ever pins you have. An yes on a Nano you may use analog inputs as well but only 0-5, e.i. const byte cmspModePins[5] = {A0, A1, A2, A3, A4}; DcsBios::SwitchMultiPos cmspMode("CMSP_MODE", cmspModePins, 5) Will also work. Of cause you then have to wire to these pins. Caution pin 13 should preferrably be used as ouput, otherwise you may have de-solder the onboard LED. Cheers Hans -
Yeah it look like it. Just Google the switch type e.g. 12TW1-50 and a Honeywell link should come up Cheers Hans
-
Hi Sven, Well I got my Mega's with ATMEGA16U2, I used my previous setup with adding a new Mega as RS485 Master and running a Nano as slave. When using the newest Mega's (with ATMEGA16U2) the Nano received communication immediately. In order to confirm that the CH340 is causing us trouble I programmed one of these as Master again a Slave Nano. Worked perfectly :surrender: What the hell?? Now I have noticed something on the CH340 that I didn't notice before. The clones I have with the CH340 have pins 18 and 19 labelled incorrectly. CH340; Pin18 RX1 Pin19 TX1 Latest with ATMEGA16U2; Pin18 TX1 Pin19 RX1 Which also followd the official pinout; https://www.arduino.cc/en/uploads/Main/arduino-mega2560_R3-sch.pdf My previous assumption that the CH340 may have been an issue turns out to be a wild goose chase. Sorry Cheers Hans
-
This may the library; https://github.com/gadjet/1602-OLED-Arduino-Library Cheers Hans