Forum Rule: Always post complete source code & details to reproduce any issue!
Page 2 of 2 FirstFirst 1 2
Results 26 to 29 of 29

Thread: second spi channel ?? teensy 4.1

  1. #26
    Senior Member
    Join Date
    May 2017
    Location
    Netherlands
    Posts
    139
    This was the error from Wire1....

    Code:
    13:24:18.417 -> Scanning(Wire1)...
    13:24:18.450 -> Unknown error at address 0x01MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:18.450 -> Unknown error at address 0x02MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:18.483 -> Unknown error at address 0x03MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:18.483 -> Unknown error at address 0x04MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:18.516 -> Unknown error at address 0x05MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:18.516 -> Unknown error at address 0x06MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:18.549 -> Unknown error at address 0x07MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:18.549 -> Unknown error at address 0x08MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:18.583 -> Unknown error at address 0x09MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:18.583 -> Unknown error at address 0x0AMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:18.616 -> Unknown error at address 0x0BMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:18.616 -> Unknown error at address 0x0CMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:18.649 -> Unknown error at address 0x0DMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:18.649 -> Unknown error at address 0x0EMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:18.682 -> Unknown error at address 0x0FMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:18.682 -> Unknown error at address 0x10MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:18.715 -> Unknown error at address 0x11MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:18.715 -> Unknown error at address 0x12MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:18.748 -> Unknown error at address 0x13MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:18.748 -> Unknown error at address 0x14MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:18.781 -> Unknown error at address 0x15MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:18.781 -> Unknown error at address 0x16MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:18.814 -> Unknown error at address 0x17MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:18.814 -> Unknown error at address 0x18MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:18.848 -> Unknown error at address 0x19MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:18.848 -> Unknown error at address 0x1AMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:18.881 -> Unknown error at address 0x1BMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:18.881 -> Unknown error at address 0x1CMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:18.914 -> Unknown error at address 0x1DMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:18.914 -> Unknown error at address 0x1EMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:18.947 -> Unknown error at address 0x1FMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:18.980 -> Unknown error at address 0x20MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:18.980 -> Unknown error at address 0x21MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.013 -> Unknown error at address 0x22MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.013 -> Unknown error at address 0x23MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.046 -> Unknown error at address 0x24MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.046 -> Unknown error at address 0x25MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.079 -> Unknown error at address 0x26MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.079 -> Unknown error at address 0x27MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.113 -> Unknown error at address 0x28MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.113 -> Unknown error at address 0x29MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.146 -> Unknown error at address 0x2AMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.146 -> Unknown error at address 0x2BMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.179 -> Unknown error at address 0x2CMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.179 -> Unknown error at address 0x2DMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.212 -> Unknown error at address 0x2EMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.212 -> Unknown error at address 0x2FMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.245 -> Unknown error at address 0x30MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.245 -> Unknown error at address 0x31MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.278 -> Unknown error at address 0x32MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.278 -> Unknown error at address 0x33MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.311 -> Unknown error at address 0x34MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.311 -> Unknown error at address 0x35MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.345 -> Unknown error at address 0x36MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.345 -> Unknown error at address 0x37MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.378 -> Unknown error at address 0x38MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.378 -> Unknown error at address 0x39MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.411 -> Unknown error at address 0x3AMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.411 -> Unknown error at address 0x3BMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.444 -> Unknown error at address 0x3CMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.444 -> Unknown error at address 0x3DMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.477 -> Unknown error at address 0x3EMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.477 -> Unknown error at address 0x3FMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.510 -> Unknown error at address 0x40MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.510 -> Unknown error at address 0x41MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.543 -> Unknown error at address 0x42MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.543 -> Unknown error at address 0x43MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.576 -> Unknown error at address 0x44MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.576 -> Unknown error at address 0x45MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.610 -> Unknown error at address 0x46MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.643 -> Unknown error at address 0x47MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.643 -> Unknown error at address 0x48MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.676 -> Unknown error at address 0x49MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.676 -> Unknown error at address 0x4AMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.709 -> Unknown error at address 0x4BMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.709 -> Unknown error at address 0x4CMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.742 -> Unknown error at address 0x4DMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.742 -> Unknown error at address 0x4EMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.775 -> Unknown error at address 0x4FMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.775 -> Unknown error at address 0x50MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.808 -> Unknown error at address 0x51MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.808 -> Unknown error at address 0x52MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.841 -> Unknown error at address 0x53MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.841 -> Unknown error at address 0x54MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.875 -> Unknown error at address 0x55MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.875 -> Unknown error at address 0x56MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.908 -> Unknown error at address 0x57MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.908 -> Unknown error at address 0x58MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.941 -> Unknown error at address 0x59MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.941 -> Unknown error at address 0x5AMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.974 -> Unknown error at address 0x5BMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:19.974 -> Unknown error at address 0x5CMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.007 -> Unknown error at address 0x5DMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.007 -> Unknown error at address 0x5EMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.040 -> Unknown error at address 0x5FMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.040 -> Unknown error at address 0x60MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.073 -> Unknown error at address 0x61MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.073 -> Unknown error at address 0x62MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.106 -> Unknown error at address 0x63MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.106 -> Unknown error at address 0x64MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.140 -> Unknown error at address 0x65MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.140 -> Unknown error at address 0x66MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.173 -> Unknown error at address 0x67MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.173 -> Unknown error at address 0x68MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.206 -> Unknown error at address 0x69MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.206 -> Unknown error at address 0x6AMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.239 -> Unknown error at address 0x6BMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.272 -> Unknown error at address 0x6CMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.272 -> Unknown error at address 0x6DMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.305 -> Unknown error at address 0x6EMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.305 -> Unknown error at address 0x6FMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.338 -> Unknown error at address 0x70MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.338 -> Unknown error at address 0x71MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.372 -> Unknown error at address 0x72MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.372 -> Unknown error at address 0x73MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.405 -> Unknown error at address 0x74MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.405 -> Unknown error at address 0x75MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.438 -> Unknown error at address 0x76MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.438 -> Unknown error at address 0x77MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.471 -> Unknown error at address 0x78MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.471 -> Unknown error at address 0x79MCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.504 -> Unknown error at address 0x7AMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.504 -> Unknown error at address 0x7BMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.537 -> Unknown error at address 0x7CMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.537 -> Unknown error at address 0x7DMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.570 -> Unknown error at address 0x7EMCR:1 MSR:2002001, MIER:0 MDER:0 MCFGR0:0 MDMR:0 MCCR0:1928373b
    13:24:20.570 -> No I2C devices found
    13:24:20.570 -> 
    13:24:20.570 -> Scanning(Wire2)...
    13:24:20.570 -> Device found at address 0x3C  (SSD1306,DigisparkOLED)
    13:24:20.570 -> done

  2. #27
    Senior Member+ KurtE's Avatar
    Join Date
    Jan 2014
    Posts
    8,987
    Quote Originally Posted by pd0lew View Post
    Hi Kurt, group,

    Tested the T4.1 with the scanner and Wire is ok, Wire1 not found, Wire2 is ok it seems that the T4.1 has a defect. I will order a new one.

    Thanks for helping!
    Best regards,
    Johan
    Sorry to hear that. Again I would still be tempted to maybe post a picture of it, and probably double/triple check wiring.
    If it were me, I would probably run something like what I call the HiLow test sketch. I know @defragster has posted more up to date versions.
    Also this version has been posted several times:
    Code:
    void setup() {
      Serial.begin(115200);
      while (!Serial && millis() < 4000 );
      Serial.println("Compile Time:: " __FILE__ " " __DATE__ " " __TIME__);
      Serial.printf("Num Digital Pins: %d\n", NUM_DIGITAL_PINS);
    
      testForShorts();
      
    }
    
    uint32_t cnt = 0;
    void loop() {
      cnt++;
        allPinTest( cnt );
    }
    
    uint32_t pinLast[NUM_DIGITAL_PINS];
    void allPinTest( uint32_t cnt ) {
      uint32_t ii, SET;
      Serial.print("PULLDOWN Start Vals:\n  ");
      SET = 0;
      Serial.print("PULLDOWN :: TEST to 3.3V\n  ");
      for ( ii = 0; ii < NUM_DIGITAL_PINS; ii++) {
        pinMode( ii, INPUT_PULLDOWN );
        delayMicroseconds( 5 );
        pinLast[ii] = digitalReadFast( ii );
        if (pinLast[ii]) {
          Serial.print("\nd#=");
          Serial.print( ii );
          Serial.print( " val=" );
        }
        Serial.print( pinLast[ii] );
        Serial.print(',');
      }
      Serial.println();
      Serial.println();
      while ( 1 ) {
        uint32_t jj, dd = 0, cc = 0, ee=4;
        cc = 0;
        for ( ii = 0; ii < NUM_DIGITAL_PINS; ii++) {
          jj = digitalReadFast( ii );
          if ( jj != pinLast[ii] ) {
            dd = 1;
            cc++;
            pinLast[ii] = jj;
            Serial.print("d#=");
            Serial.print( ii );
            if ( pinLast[ii] ) Serial.print( "\t" );
            Serial.print( " val=" );
            Serial.print( pinLast[ii] );
            Serial.print(',');
          }
          if ( cc > 1 && ee ) {
            Serial.println(">>> MULTI CHANGE !!");
            ee--;
          }
          if ( Serial.available() ) {
            while ( Serial.available() ) Serial.read();
            if ( 0 == SET ) {
              SET = 1;
              Serial.print("PULLUP :: TEST TO GND\n  ");
            }
            else {
              SET = 0;
              Serial.print("PULLDOWN :: TEST to 3.3V\n  ");
            }
            for ( ii = 0; ii < NUM_DIGITAL_PINS; ii++) {
              if ( 0 == SET )
                pinMode( ii, INPUT_PULLDOWN );
              else
                pinMode( ii, INPUT_PULLUP );
              delayMicroseconds( 20 );
              pinLast[ii] = digitalReadFast( ii );
              if (SET != pinLast[ii]) {
                Serial.print("d#=");
                Serial.print( ii );
                Serial.print( " val=" );
                Serial.println( pinLast[ii] );
              }
            }
          }
        }
        if ( dd ) {
          dd = 0;
          Serial.println();
          delay( 50 );
        }
      }
    }
    
    void testForShorts() {
      uint32_t ii;
      Serial.print("Quick Test for Shorts to adjacent pin");
      Serial.println("First pull pins down and see if the next one follows");
      for ( ii = 0; ii < NUM_DIGITAL_PINS-1; ii++) {
        pinMode( ii+1, INPUT_PULLDOWN );
        pinMode( ii, OUTPUT);
        digitalWrite(ii, HIGH);
        delayMicroseconds( 5 );
        if (digitalRead(ii+1)) {
          Serial.printf("%d:%d ", ii, ii+1);
        }
      }
      Serial.println("\n Now try Pull up and see if setting low follow");
      for ( ii = 0; ii < NUM_DIGITAL_PINS-1; ii++) {
        pinMode( ii+1, INPUT_PULLUP );
        pinMode( ii, OUTPUT);
        digitalWrite(ii, LOW);
        delayMicroseconds( 5 );
        if (!digitalRead(ii+1)) {
          Serial.printf("%d:%d ", ii, ii+1);
        }
      }
      Serial.println();  
    }
    But when I get into cases like that that something not working. I run a sketch like the above, either test to gnd or to 3.3v and for example testing to GND, I would then try a probe to the SDA line of one of the sensors and see if a pin number shows up as changing state. Is it the right one? I then do same for SCL pin and see if right pin.

    I have hit issues before like:
    a)I reversed the pins. i.e. Simply moved them down 18,19 to 16,17 which is wrong... That is 18->17 and 19->16
    b)My eyes looked wrong at breadboard and off by one pin (been there)
    c) My breadboard and/or jumper was not working very well. So changed wires.
    d) Solder joint issue - I might hit the connections again with soldering iron and checked for small shorts.
    e) found my devices did not have Pull Up resistors (used meter, or in most cases Logic Analyzer) on the two pins to see if the signal is pulled up (and if any I2C outputs happening)...

    Edit: f) I would try with one simple sensor I know that works on that port. Always possible a sensor is bad

    Again I know you probably did most/all of the above, but that is what I would try... (Along with swap in different T4.1 to see if that made a difference...

  3. #28
    Senior Member
    Join Date
    May 2017
    Location
    Netherlands
    Posts
    139
    Hi Kurt,
    Wire and Wire2 works but Wire1 is failing...... I removed the Teensy from the board and connected directly with wires.... no differences.

    Click image for larger version. 

Name:	DeepinScreenshot_select-area_20210411154850.jpg 
Views:	3 
Size:	55.4 KB 
ID:	24413Click image for larger version. 

Name:	DeepinScreenshot_select-area_20210411154400.png 
Views:	5 
Size:	713.3 KB 
ID:	24414

  4. #29
    Senior Member+ KurtE's Avatar
    Join Date
    Jan 2014
    Posts
    8,987
    With the HiLow test, I don't see you actually trying to run a probe from either 3.3v or GND depending on which way, and touch other side to a pin.

    Note: you need to hit enter to change modes.
    For example I ran it on a T4.1 with nothing connected.
    Then hit enter then tried probing from a gnd pin to different IO pins. like Pin 0, 16, 17, 19 (not necessarily in that order)
    Output looked like:
    Code:
    Compile Time:: C:\Users\kurte\Documents\Arduino\Teensy Tests\HiLowTest\HiLowTest.ino Apr 11 2021 07:39:17
    Num Digital Pins: 55
    Quick Test for Shorts to adjacent pinFirst pull pins down and see if the next one follows
    
     Now try Pull up and see if setting low follow
    
    PULLDOWN Start Vals:
      PULLDOWN :: TEST to 3.3V
      0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
    
    PULLUP :: TEST TO GND
      d#=0 val=0,
    d#=0	 val=1,
    d#=27 val=0,
    d#=27	 val=1,
    d#=16 val=0,
    d#=16	 val=1,
    d#=16 val=0,
    d#=16	 val=1,
    d#=16 val=0,
    d#=16	 val=1,
    d#=16 val=0,
    d#=16	 val=1,
    d#=18 val=0,
    d#=18	 val=1,
    d#=19 val=0,
    d#=19	 val=1,
    d#=16 val=0,
    d#=16	 val=1,
    d#=16 val=0,
    d#=16	 val=1,
    d#=17 val=0,
    d#=17	 val=1,
    d#=17 val=0,
    d#=17	 val=1,
    .
    So it shows that pin 0 went low when I hit it with jumper one end connected to gnd and touch pin 0... Then went back high when I released it.
    Some pins maybe going to gnd won't work, like they have a stronger pull down external, so it stays low... So hitting enter again then allows you to test instead of using GND use 3.3v..

    Again I use that to verify that the pins are working correctly, not a solder issue. Note: sometimes when you touch a pin and multiple ones show change, it is an indication that there may be a short. In your hook up I would expect that normally pin 16 and 17 should be high with a device plugged in that probably has PU resistors on the two IO pins...

    And if those two pins work at all, I might try going to breadboard and use external PU resistors and see if that helps.

Posting Permissions

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