Filtering noise from a wire


+ Reply to Thread
Results 1 to 31 of 31

Hybrid View

  1. #1
    Join Date
    May 2013
    Location
    australia
    Posts
    2,631


    Did you find this post helpful? Yes | No

    Default Re: Filtering noise from a wire

    what problem is the active pullup bus chip going to solve ?
    it will make zero difference to pbp's bit-banged commands and the mssp port would have no issues at 400kHz bus speed anyway [providing bus length and load is within reason] using the usual pullup resistors.
    Warning I'm not a teacher

  2. #2
    Join Date
    Jan 2005
    Location
    Montreal, Quebec, Canada
    Posts
    3,154


    Did you find this post helpful? Yes | No

    Default Re: Filtering noise from a wire

    Quote Originally Posted by richard View Post
    what problem is the active pullup bus chip going to solve ? ...
    I was hoping:

    - it would allow me to use the MCP23017 at 400MHz,
    - it would be enough to read rotary encoders with an MCP23017,
    - it would work using I2CREAD command.

    But that's too many IFs. The chip is not available in DIP package for me to test.

    I've since decided to go with a dedicated 16F1937 TQFP-44 at 32MHz with 36 IOC pins to manage my encoders. I have room for 14 encoders on this secondary PIC (primary is a USB PIC), and the jumper at bottom right will permit me to use a 2nd circuit if needed in the future.

    I only need 13 for this first project. I could use the 2 pins for encoder #14 to create a 3 bit jumper, giving me addressing for 8 circuits (total of 103 encoders). I'll most likely make the change now that I've thought about it.

    Name:  PCB Encoders.png
Views: 5070
Size:  161.9 KB


    EDIT: I didn't forgetting mounting holes. The PCB will be mounted vertically along the perimeter of the enclosure with the pins pointed inwards. The high-mounted header pins will be easy to access. and a single line of hot-glue will secure the connectors.
    Last edited by Demon; - 17th May 2024 at 20:43.
    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!

  3. #3
    Join Date
    May 2013
    Location
    australia
    Posts
    2,631


    Did you find this post helpful? Yes | No

    Default Re: Filtering noise from a wire

    I was hoping:


    - it would allow me to use the MCP23017 at 400MHz,
    - it would be enough to read rotary encoders with an MCP23017,
    - it would work using I2CREAD command.
    MCP23017@400KHz , using a pic16 @32mhz can do that easily using mssp module
    using I2CREAD command. @32 mHz the cmd will do 166KHz at best, even at 64 MHz it will not reach 400kHz

    to read multiple rotary encoders with an MCP23017 the bus speed is the least of your problems , the hoops you need to jump through to track multiple edge transitions without error are extremely challenging.


    re 16F1937 , why ? surely at least a 16f18875 would make tracking edges far easier. mind you its still difficult to keep track of more than one those 4 count per indent RE's
    13 will be interesting. have you tried any code to be sure a result is even viable with the encoders you have selected ?
    Warning I'm not a teacher

  4. #4
    Join Date
    Jan 2005
    Location
    Montreal, Quebec, Canada
    Posts
    3,154


    Did you find this post helpful? Yes | No

    Default Re: Filtering noise from a wire

    Quote Originally Posted by richard View Post
    MCP23017@400KHz , using a pic16 @32mhz can do that easily using mssp module
    using I2CREAD command. @32 mHz the cmd will do 166KHz at best, even at 64 MHz it will not reach 400kHz
    ..
    I've never used MSSP. At least now I know where I stand using the command.


    Quote Originally Posted by richard View Post
    ...to read multiple rotary encoders with an MCP23017 the bus speed is the least of your problems , the hoops you need to jump through to track multiple edge transitions without error are extremely challenging....
    I am polling a controller for Flight Sim. I have multiple encoders on the circuit, but I do not expect more than 1 encoder to be active at the same time. I suppose with auto-pilot you could move 2 encoders at the same time, but there isn't an auto-pilot in this first plane (Cessna-152).


    Quote Originally Posted by richard View Post
    ...16F1937 , why ? surely at least a 16f18875 would make tracking edges far easier. mind you its still difficult to keep track of more than one those 4 count per indent RE's
    13 will be interesting. ...
    Cost, size and availability at JLCPCB mainly. I want to make 100 units for the 1st batch, so every penny quickly adds up.


    Quote Originally Posted by richard View Post
    ... have you tried any code to be sure a result is even viable with the encoders you have selected ?
    Not yet. My breadboards are crap, and my mini-CNC is not as useful as I hoped.

    I was going to get 5x PCBs from JLCPCB for testing. These are ordinary EC11 and EC10 (mouse wheel) encoders moved manually, it's NOT mechanically manipulated.
    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!

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


    Did you find this post helpful? Yes | No

    Default Re: Filtering noise from a wire

    The controllers will look something like this:



    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,115


    Did you find this post helpful? Yes | No

    Default Re: Filtering noise from a wire

    Quote Originally Posted by Demon View Post
    Cost, size and availability at JLCPCB mainly. I want to make 100 units for the 1st batch, so every penny quickly adds up.
    Well, why not select from Mouser or Digikey?

    Ioannis

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


    Did you find this post helpful? Yes | No

    Default Re: Filtering noise from a wire

    Quote Originally Posted by Ioannis View Post
    Well, why not select from Mouser or Digikey?

    Ioannis
    The price at JLCPCB is unbeatable by North American suppliers, as long as JLCPCB has the item in stock. Choosing PICs was probably the hardest thing, cause prices vary a lot depending on model, and then quickly rise when you go outside JLCPCB.

    - most likely will switch from 16F1936/37 to 16F18855 for secondary PIC; every pin can be On Interrupt,
    - 16F18877 is useful to handle both switches and ADC (7 pots on the right enclosure),
    - 16F1459 will be most likely used for USB communication and primary PIC.

    I'll be assembling all pots, switches and encoders myself since JLCPCB does not seem to beat prices from Alibaba.

    If you know another affordable PIC with so many IOC pins, please let me know.
    Last edited by Demon; - 27th August 2024 at 00:27.
    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. Noise on input signal
    By fanman in forum mel PIC BASIC Pro
    Replies: 17
    Last Post: - 28th February 2012, 02:55
  2. Notch filtering
    By SOMRU in forum mel PIC BASIC Pro
    Replies: 0
    Last Post: - 23rd June 2010, 16:45
  3. Noise on OSC pins.
    By Tobias in forum General
    Replies: 0
    Last Post: - 31st December 2009, 01:29
  4. Input Noise
    By PJALM in forum mel PIC BASIC Pro
    Replies: 13
    Last Post: - 28th February 2006, 19:26
  5. Loop noise
    By Jųan in forum mel PIC BASIC Pro
    Replies: 5
    Last Post: - 20th October 2005, 12:19

Members who have read this thread : 11

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