Electronics > Projects, Designs, and Technical Stuff

One crazy SAMD21G MCU – I2C/RESET issues (custom PCB design)

<< < (3/7) > >>

Kasper:

--- Quote from: 3dgeo on October 03, 2019, 08:27:22 pm ---
Also I noticed my Pfets are not working properly, I used SQ3985EV, added 3.3V pullups on Gates, 5V on Source, Drain should be 0v with pullups, but no, it's 5V 

--- End quote ---

On front page of your PMOS datasheet:
If Vgs = -1.8V then Rds = 0.3ohms

For your description:
Vgs = Vg - Vs
Vgs = 3.3V - 5V
Vgs = -1.7V

Rds ~ 0.3ohms

Sounds like your PMOS circuit is working. Just not how you expected.  Generally gate voltage should be as high as source voltage to ~fully turn off PMOS.

When switching PMOS with low voltage MCU it can help to connect NPN or NMOS between MCU and PMOS.

Kasper:

--- Quote from: 3dgeo on October 02, 2019, 07:09:07 pm ---
Also that SAMD21G on the PCB doen't react to RESET going low (internally pulled up), at least computer doesn't make USB connect/disconnect sound (other SAMD21G break out board do).

I'm thinking this is cos of one of two things:
1. some SAMD21G pins are pulled up/down by the PCB design that shouldn't be and messes with reset

--- End quote ---

This video might help with this:

EEVblog #831 - Power A Micro With No Power Pin!
YouTube · EEVblog
Dec 17, 2015

3dgeo:

--- Quote from: Kasper on October 03, 2019, 09:16:39 pm ---Sounds like your PMOS circuit is working. Just not how you expected.  Generally gate voltage should be as high as source voltage to ~fully turn off PMOS.

--- End quote ---

Thank you for explanation, I'm not that familiar with Pfets.


--- Quote from: Kasper on October 03, 2019, 09:21:50 pm ---EEVblog #831 - Power A Micro With No Power Pin!
YouTube · EEVblog
Dec 17, 2015

--- End quote ---

I encountered issue in the video with 74 logic, this is not the case. I should clear it out – pulling Reset to ground seems to crash MCU, it stops responding (at least serial com to PC stops).

I build two more PCBs with minimum components – first one had 5V to 3.3V step down, it worked at the beginning, but then it just stopped, I can't even get it recognized with Atmel Ice. Also I notices that Voltage sometimes goes down to 0 on USB 5V rail on that board, so I figured it's regulator (MCP1700 SOT-23). So I just made another PCB with no regulator, it as well not recognized with Atmel Ice (it's not the Ice cos it still detects my first PCB just fine).

I didn't post the schematic and PCB layout cos I wasn't near my workstation were I can prepare this info.
But I guess I'll have to do it now cos even cursing and threatening at this PCB doesn't seems to work.  :horse:

3dgeo:
OK, I'm back with the schematic, at least part of it that I'm having issues.

By making image below I realized that I'm using 12pF crystal caps (C52,C53) instead of 15pF, can this be a problem? Crystal I'm using is 32.768KHz +-10ppm, 12.5pF.

Also I think I found my problem with the I2C – I'm using MCU IO pin PA21 to reset 3 ICs (NOT THE MCU) on the same I2C  bus I'm having problem with. I actually made some tests before to make sure this pin works properly, it seems at that time that it's fine. This PA21 pin name seemed very familiar tho but I didn't know why. I think that SAM-BA bootloader uses it for some sort of data representation LED, I assume it's the same with Arduino core, so MCU toggling that pin. Me adding another I2C device with its own pullups reduced resistance and that line didn't get to 0v or wasn't long enough on 0V to reset those chips, that's why all IC showed up on the scan script, but If I added another chip without its own pullups only that chip gets detected cos other chips are in Reset constantly – now that's an interesting issue.... I think I'm lucky to figure this one out  :box:

I'm guessing Reset issues I'm having is also related to my PCB pin configuration.
To fix Pfets I'll probably will add ULN2003 darlington array, it got 7 drivers, 7 drivers I need. If anyone have better idea – let me know.

Now I need to find out why my other PCBs with minimum config doesn't work, crystal/caps? But Atmel Ice should be able to detect those with no crystal at all... I really doubt I fried chips while soldering, ESD maybe?

I removed GND copper fills, so please ignore GND:

ataradov:
Crystals are not likely to be the problem.

I don't know anything about SAM-BA or Arduino bootloaders, so can't help you here.

Again scope or logic analyzer will answer those questions.

Navigation

[0] Message Index

[#] Next page

[*] Previous page

There was an error while thanking
Thanking...
Go to full version
Powered by SMFPacks Advanced Attachments Uploader Mod