|
Post by Keith on Oct 22, 2017 9:51:00 GMT 2
Hi,
You have done so much to document your project its great! I intend on using as much as I can from your website to build my own simulator as it seems you have done a lot of the hard work!
To begin I have bought an Arduino starter kit (UNO replica) and have just started to dabble with electronics for the first time.
I am currently trying to get my rotary encoder to work correctly. In your downloadable Arduino sketch (for the instrument panel arduino board) you include 2 libraries. One is the
quadrature library and One is the math library. You have a link to download the quadrature library but I get an error trying to extract the ZIP file. Could it be a corrupted file?
Secondly, where can I find the math library?
Third, after reading the details about how you build your radio stack and use Mobiflight etc. I'm wondering ... there must be some sort of sketch on the radio stack arduino board that reads the radio encoders and drives the 7-segment displays etc. ? This is not available or downloadable from your website yet?
Regards.
Keith
|
|
|
Post by AlbEagle on Oct 22, 2017 21:43:30 GMT 2
Hi there Keith. I can upload the math library but if you use mobiflight you don't need it. Once you config mobiflight you click upload and it uploads the sketch on the arduino for you. For the whole project you only need mobiflight which is easier than link2fs which is great as well but needs more arduino programming knowledge. I'm no longer using link2fs but only mobiflight for all the switches and encoders.
Regards AlbEagle
|
|
|
Post by Keith on Oct 23, 2017 1:18:48 GMT 2
Thanks for the quick reply. That makes sense. There had to be a sketch of some sort on the Arduino to send and receive comms from Mobiflight. I was thinking maybe Mobiflight uploaded its own companion sketch. My electronics skills are very low. I have a starter UNO kit and I managed to upload a sketch to count from 0 to 9 on a 7-segment digit. Next I added a rotary encoder to see if I could read its signals and then control the 7-segment display. I have been failing to upload any sketch from internet (even your sketch "Cessna172WithEncodersFinal.ino" I could not get working) I did manage to get it compiled after making change to the quadrature.h library but my circuit does not work with your sketch. I only have a UNO and only 1 rotary encoder. I did notice that rotary encoders seem to require complex wiring with resisters and even capacitors to remove any "bounce". Your circuit diagram for rotary encoders seem to not use any resisters and circuitry to pull up or any capacitors? Is your wiring diagram actually is required. Maybe some of your website info is out of date? Somethings you don't do any more (like the Cessna172WithEncodersFinal.ino is not required now that you use mobiflight?) and some wiring circuit diagrams are changed since you published them on website? I did remember reading that you don't use the mouse encoders for the panel anymore? However I think you still use them on the radio so you can build double rotary encoder (this is still correct yes?) You say that you use Mobiflight for both radio and instrument panel (plus switches) now ... does that mean you have 2 arduinos connected to Mobiflight? or just 1 for EVERYTHING is enough? Basically Im thinking I might just have to buy everything you use (as it is proven) and follow evything exactly the same (using same electronic components and wiring). For this I need to know exactly what you have done and rely on your details in the web pages. I was trying to test small components to test my abilities and prove that I can get results from 1 switch, 1 encoder, 1 7 segment etc. and build confidence ... this may not be possible ... I may just have to follow your info ... as long as it is up to date and complete and reflects your current working solution. Lots of questions and comments above. I hope I have explained well enough what info I am seeking from you in regards to your website and solution. My intention is to build a fully enclosed C182 cockpit with projection visuals (180-220 degrees). I want a fully functional panel with as close to real tactile and operation feel (of course at lowest price possible). Your solution seems to be the best option I have discovered. Regards Keith
|
|
|
Post by AlbEagle on Oct 23, 2017 22:55:41 GMT 2
Hi Keith You are right about the part with link2fs which I don't use anymore, I will have to edit it, I didn't have enough time to do so. But as for now all you need it mobiflight and nothing else. Check this tutorial on how to connect the 7 segment display with Arduino and how to program it. It is very easy, and I'm sure you are going to love it. The only problem mobiflight has had was working with Arduino uno, which didn't work quite good but I have read that in the last update they have fixed the issue. As for the mouse encoders, I'm not using them anymore because of the difficulty to mount them and attach knobs on them. In the website you will find the encoders I'm using now and the link as well where I purchased them. To get all the switches (on both plane and radio) working you need at least 4 Arduino mega 2560 cards. Arduino Uno leaks on I/O pins. I suggest you purchase at least 2xArduino Mega 2560 (a clone costs about $8) and you can get all what I have right now working (not everything on the radio though, as I said to do that you need at least 4 Arduino megas). But with the uno you can experiment with the mobiflight and the 7 segment display, switches and encoders. Regards Albeagle
|
|
|
Post by Keith on Oct 24, 2017 0:48:28 GMT 2
Thanks for the info. I have to say if it wasn't for your website I don't think I would be contemplating this project. The more I have researched the more I've learnt how broad a project it is. Certainly your panel (including radio) solution is just brilliant for bang for buck I managed to get my rotary encoder operating by moving to pin 2/3 for interrupt based sketch and then modified the code to only change the LED number when rotating AND with encoder button pushed. This was to simulate what I want to implement for the instrument rotaries. It's been 20 years since I've been in the left seat so I can't remember if all panel rotaries need to be pushed in before rotating in the real aircraft. My intention is to try to replicate the real tactile and operation of the real panel and radio switches and knobs. Anyway it was an achievement and gave me a boost to my confidence yesterday. I may as well apologise up front now because I can see myself bugging you with endless stupid questions as I get further along. I will read through all your details and forum topics also. Once (and if I think I can actually do this) I start the project officially I will setup a website I think to detail my progress to add to the pool of knowledge and experience as my "pay it forward" contribution and give credit where credit is due to others. Regards Keith
|
|
|
Post by AlbEagle on Oct 25, 2017 23:39:10 GMT 2
Great to hear you succeeded with the rotary encoder. I'm glad I have helped. I'm trying to stay as active as I can, feel free to ask?
|
|
|
Post by Costel on Oct 28, 2017 9:38:26 GMT 2
Great work! I would want to buy something like this. What would be the price? Thank You!
|
|
|
Post by Simth on Oct 29, 2017 19:43:25 GMT 2
Hi, I am new user of Flight simulator X and want to make a home cockpit for Cessna 172, I want to know can we use rotary encoder to change headings of Adf or Altimeter Bug with the help of mobiflight and can u give me a tutorial for help.. i am very thankful to you for this favor..
Thanks
|
|
|
Post by AlbEagle on Oct 29, 2017 20:59:13 GMT 2
Great work! I would want to buy something like this. What would be the price? Thank You! I'm building this for myself so I never thought of making it for sale, because of the dimensions, which is hard to ship. Regards AlbEagle.
|
|
|
Post by AlbEagle on Oct 29, 2017 22:31:39 GMT 2
Hi, I am new user of Flight simulator X and want to make a home cockpit for Cessna 172, I want to know can we use rotary encoder to change headings of Adf or Altimeter Bug with the help of mobiflight and can u give me a tutorial for help.. i am very thankful to you for this favor.. Thanks Here is a tutorial for Heading bug. The same is for Altimeter etc... The pictures should be self-explanatory. First you connect the encoder to the Arduino (in my case on pin 5 and 6) and the ground. Connect Arduino to your PC and open Mobiflight (I assume you have installed Arduino drivers) and follow the steps below. After you add the encoder, name it (in my case AutopilotHDG) and upload the sketch to Arduino (follow the steps below). After hitting OK go to Inputs and Add the same (AutopilotHDG), check the box and click three dots ... on the right side under Edit. In the InputConfigurationWizard chose your Arduino board, the encoder and for left rotation I went with Event ID. After selecting Event ID you scroll down until you find HEADING_BUG_DEC which stands for decreasing the values. Hit use and OK and you should be good. Do the same for the right rotation. In this case choose HEADING_BUG_INC for increasing the values. Hit use and ok and you are good to go. Disconnect and reconnect Arduino, open FSX, choose Cessna 172 and Run Mobiflight. You will be able to change Heading Bug while rotating the encoder. Regards AlbEagle
|
|
|
Post by yaseenmaqbool on Oct 30, 2017 14:25:16 GMT 2
Thanks for the tutorial, God Bless u..
Simth
|
|
|
Post by AlbEagle on Oct 30, 2017 22:10:22 GMT 2
Thanks for the tutorial, God Bless u.. Simth You're welcome AlbEagle
|
|