element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Avnet & Tria Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • About Us
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
Personal Blogs
  • Community Hub
  • More
Personal Blogs
NexGen Flight Simuator NexGen: Hacking: Mode Selector Panel. part 1 -- Overview
  • Blog
  • Documents
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
  • Share
  • More
  • Cancel
Group Actions
  • Group RSS
  • More
  • Cancel
Engagement
  • Author Author: phoenixcomm
  • Date Created: 4 Nov 2023 4:46 PM Date Created
  • Views 431 views
  • Likes 4 likes
  • Comments 0 comments
  • flight simulator
  • nexgen
  • arduino mega 2560
  • diy aircraft cockpit
  • CANaerospce
Related
Recommended

NexGen: Hacking: Mode Selector Panel. part 1 -- Overview

phoenixcomm
phoenixcomm
4 Nov 2023

image

imageI have had this Mode Selector for more than a few years so I guess, "The time has come,' the Walrus said, To talk of many things:
-The Walrus and the Carpenter BY LEWIS CARROLL

imageThis one should be straightforward, on my Arduino Mega I will 2 x Schmitt Triggers, plus the RC filters, I will most likely route the 7 Schmitt Triggers from the switches into an MCP2017 and a Resistor array for pull-ups. Now for the outputs, I need 18 output lines, so that's 1 MCP2017 plus I will need to steal 2 more from the other MCP2017 - Easy Peasy - Lemon Squeezy

Each lamp type 727, which are rated 5v at 0.012A or about 12ma each, but each legend takes two of the lamps which is 0.024W, but the MCP2017 spec is"Maximum output current sourced by any output pin ....25 mA", or 0.025A. So I think I might need a small transistor to give me a little more current. As this is getting more convoluted by the second I will be forced to go with a PCB image The interface cables need 18 (lamp drive) +7 (inputs) =25 pins plus a 4-pin connector for 5 VDC (raw) for the lamps, p5 from the Arduino for the logic, and of course ground. and the RJ-45s for the CAN bus. CAN outputs are from an SPI module with an MCP215 controller with a TJA1050 transceive

Connections
L
A
M
P
S
1
2
3 COM N.O. N.C.
4
5

To put the lamp wiring in perspective, pins 1 through 5, connect to two circuits, pins 2, and 4 run the top legend while pins 1, and 3 run the bottom legend.

FD
ENG
AP
GA
VOR
LOC
HDC
ENG
NAV
ARM ENG
NAV1
NAV2
ALT
ENG
GS
ARM ENG
BC
ON

Arduino Interrupts:

SVC1 CAN bus interrupt (this tells the Arduino that the CAN module has data 1300
SVC2 CAN bus Lamps -- 1301
SVC4 Arduino -- 1302 (this tells the Arduino that the Mode Control Switches were pressed)

CANaerospace Info:

*CANid and Data Types are subject to change
DATA TYPE:
1301 ::= 4 Bytes but only the first 3 are used.
1302 ::= 4 Bytes but only the first 2 are used.

CANids: 1301, 1302, and where 1300 is the system itself.
LAMP  Message Data (3 Bytes) Byte 3 has the switch address, and Byte 4 is the upper or lower lamps Byte 3 is the  state ::= 0 (off) or 1 (on)
SWITCH Message Data (2 Bytes) Byte 3 has the switch address, and Byte 3 is the  state ::= 0 (off) or 1 (on)

ID Byte 4 Byte 5 Byte 6 Byte 7
1300 Error Code
(0-FFxHex)
Defined As:
1301* 0-9 0-1 (0 upper), (1 lower) 0-1 (0 off), (1 on)
1302* 0-7 0-1 (0 off), (1 on)
  • Sign in to reply
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2025 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube