New project - MSFS C++ USB interface


+ Reply to Thread
Results 1 to 40 of 170

Hybrid View

  1. #1
    Join Date
    Jan 2005
    Location
    Montreal, Quebec, Canada
    Posts
    3,172


    Did you find this post helpful? Yes | No

    Default Re: New project - MSFS C++ USB interface

    Quote Originally Posted by Ioannis View Post
    Wow from me too!

    You got all that in a few days? Well, KiCAD will be my next try on PCB software then!...

    Ioannis

    I can't say enough good about KiCad. It even has SPICE, but I never got to learning exactly how to use that.

    I can generate all the files for a new circuit within a few hours. I can't imagine not working with it now. I love the Electrical Rules Checker; that saves a ton of time, money and effort.

    It takes a while to get used to some of its way of doing things. There's a LOT of information on the web for any error I encountered; like having to add a PWR_FLAG to VDD and GND lines, and how symbols can be divided into units).

    Units are essentially individual layers for components with multiple functions, like a 74HC14 chip with 6 circuits and the power circuit. In this example, I use only 4 of the 6 circuits. I'm putting the decoupling caps near the pin on the MCU (it's a separate circuit).

    Name:  KiCAD units.png
Views: 8016
Size:  141.2 KB

    And best of all, it's free.
    My Creality Ender 3 S1 Plus is a giant paperweight that can't even be used as a boat anchor, cause I'd be fined for polluting our waterways with electronic devices.

    Not as dumb as yesterday, but stupider than tomorrow!

  2. #2
    Join Date
    Nov 2003
    Location
    Greece
    Posts
    4,170


    Did you find this post helpful? Yes | No

    Default Re: New project - MSFS C++ USB interface

    Why is the PWR_FLAG necessary to be added? Isn't +5V enough?

    Ioannis

  3. #3
    Join Date
    Aug 2011
    Posts
    458


    Did you find this post helpful? Yes | No

    Default Re: New project - MSFS C++ USB interface

    You shouldn't leave the inputs of the HC14 floating... the outputs will be unknown.

    Also, an ST gate really won't debounce anything if that's what you're trying to do.

  4. #4
    Join Date
    Nov 2003
    Location
    Greece
    Posts
    4,170


    Did you find this post helpful? Yes | No

    Default Re: New project - MSFS C++ USB interface

    Yes, inputs should not be in the air.

    Also despite being ST inputs, the resistor and a cap should still be added. Tubleweed is very right about that.

    Ioannis

  5. #5
    Join Date
    Jan 2005
    Location
    Montreal, Quebec, Canada
    Posts
    3,172


    Did you find this post helpful? Yes | No

    Default Re: New project - MSFS C++ USB interface

    Quote Originally Posted by tumbleweed View Post
    You shouldn't leave the inputs of the HC14 floating... the outputs will be unknown.
    ....
    I wish I had seen that before sending that order to JLCPCB. I'm gonna have a resistor jumper on my brand spanking new circuit (only printed 5 to test).

    Name:  74HC14 input.png
Views: 7310
Size:  686.1 KB


    Quote Originally Posted by tumbleweed View Post
    ...
    Also, an ST gate really won't debounce anything if that's what you're trying to do.
    I'm trying to get a cleaner signal like he explains here at "Hysteresis: The Full Fix".

    Are you saying this doesn't work as he explained?

    https://hackaday.com/2015/12/09/embe...uttons-part-i/
    My Creality Ender 3 S1 Plus is a giant paperweight that can't even be used as a boat anchor, cause I'd be fined for polluting our waterways with electronic devices.

    Not as dumb as yesterday, but stupider than tomorrow!

  6. #6
    Join Date
    Nov 2003
    Location
    Greece
    Posts
    4,170


    Did you find this post helpful? Yes | No

    Default Re: New project - MSFS C++ USB interface

    It will work if you included the RC network also. But NOT as in your post #69, where switch go directly to the HC14 input.

    Ioannis

  7. #7
    Join Date
    Jan 2005
    Location
    Montreal, Quebec, Canada
    Posts
    3,172


    Did you find this post helpful? Yes | No

    Question Re: New project - MSFS C++ USB interface

    I really shouldn't work until the wee hours in the morning. That rotary switch circuit was totally not finished.

    I've updated my pushbutton circuit.

    Name:  Circuit B3F-4055 w 74HC14.png
Views: 7879
Size:  52.2 KB


    And my rotary switch circuit. (CORRECTED VERSION IN NEXT POST)

    Name:  Circuit SR25 SP4T w 74HC14.png
Views: 7887
Size:  97.5 KB


    1. Do you see any other mistakes?

    2. Do I still need a cap at the MCU pin when it's a signal from a 74HC14?



    EDIT: Hmmm, just noticed my pull-ups on the rotary switch are between the 10K and 74HC14. Gonna go change that.

    Thanks!
    Last edited by Demon; - 14th January 2024 at 00:19.
    My Creality Ender 3 S1 Plus is a giant paperweight that can't even be used as a boat anchor, cause I'd be fined for polluting our waterways with electronic devices.

    Not as dumb as yesterday, but stupider than tomorrow!

  8. #8
    Join Date
    Jan 2005
    Location
    Montreal, Quebec, Canada
    Posts
    3,172


    Did you find this post helpful? Yes | No

    Default Re: New project - MSFS C++ USB interface

    Here's my corrected rotary switch with corrected pull-ups.

    Name:  Circuit SR25 SP4T w 74HC14 corrected.png
Views: 13539
Size:  82.1 KB
    My Creality Ender 3 S1 Plus is a giant paperweight that can't even be used as a boat anchor, cause I'd be fined for polluting our waterways with electronic devices.

    Not as dumb as yesterday, but stupider than tomorrow!

  9. #9
    Join Date
    Jan 2005
    Location
    Montreal, Quebec, Canada
    Posts
    3,172


    Did you find this post helpful? Yes | No

    Default Re: New project - MSFS C++ USB interface

    Quote Originally Posted by tumbleweed View Post
    You shouldn't leave the inputs of the HC14 floating... the outputs will be unknown.

    ...

    Oooops. I've since added a pull-down for the input I was using.


    I'm seeing several comments on google about connecting the unused pins to ground. If I'm not using their output, can a floating input disturb the other circuits?


    EDIT: I've googled some more and found this explanation:

    "...random charges accumulating there can/will cause unpredictable internal behavior in the chip, including oscillation and high power dissipation."

    https://electronics.stackexchange.co...-inputs-outpus
    Last edited by Demon; - 15th January 2024 at 05:26.
    My Creality Ender 3 S1 Plus is a giant paperweight that can't even be used as a boat anchor, cause I'd be fined for polluting our waterways with electronic devices.

    Not as dumb as yesterday, but stupider than tomorrow!

  10. #10
    Join Date
    Jan 2005
    Location
    Montreal, Quebec, Canada
    Posts
    3,172


    Did you find this post helpful? Yes | No

    Default Re: New project - MSFS C++ USB interface

    Quote Originally Posted by Ioannis View Post
    Why is the PWR_FLAG necessary to be added? Isn't +5V enough?

    Ioannis

    In order for KiCad to be able to test the circuit, it has to know where the current is coming from. I just noticed how one dude uses a tiny legend to connect the flag with VDD and GND. You only need to connect the flag on each once.

    https://forum.kicad.info/t/erc-error...nd-gnd/39364/5
    My Creality Ender 3 S1 Plus is a giant paperweight that can't even be used as a boat anchor, cause I'd be fined for polluting our waterways with electronic devices.

    Not as dumb as yesterday, but stupider than tomorrow!

Similar Threads

  1. USB interface
    By Frozen001 in forum mel PIC BASIC Pro
    Replies: 1
    Last Post: - 28th December 2011, 20:37
  2. Host for USB interface?
    By Carrasco in forum Off Topic
    Replies: 4
    Last Post: - 4th August 2007, 00:59
  3. USB Interface using PIC
    By Tissy in forum mel PIC BASIC Pro
    Replies: 21
    Last Post: - 22nd May 2006, 17:04
  4. USB interface from PIC16F877 to PC
    By headshouter in forum USB
    Replies: 0
    Last Post: - 26th February 2006, 05:58
  5. USB project
    By NL2TTL in forum mel PIC BASIC Pro
    Replies: 0
    Last Post: - 18th January 2005, 22:59

Members who have read this thread : 7

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts