[SOLVED]voltage drop when stm32 inserted

edited February 2015 in Troubleshooting
Hi everyone,
I've almost finished to build my lxr. However it start to have a weird behaviour after I did an update through the sdCard and few attempt to burn the Avr through avrdude.Just before then it's been working for a while. The update went till the end and ask me to reboot...and kaboom nothing apart from a half turned on lcd. Anyhow I checked continuity between 5v and ground without the stm32 inserted: it is a plain 4.96. I could access the bootloader or the front system...but  if I plug the mainboard and reboot I get only a faint lcd and no sign of life from the lxr. Check voltage on the isp on the frontboard it give me around 2.7v. I probably need to mention that I use an atmega644PA (those one on the shruti or ambika) so I had to tweak a bit the fuse setting.
So here it is I'm in front of wall wondering what to do next not being sur if that's a problem coming from badly update atmega...or worse something related to the mainboard. Any help would be apreciated :)


  • hmmm sounds like a short somewhere.
    I can think of no real reason how a firmware update should cause a voltage drop.

    with a turned off unit, what resistance do you measure between 5V and GND?
    Best tho measure this on the frontpanel and the mainbaord separately while not put together.
  • atmega644PA should make no real difference since the P only means its a pico power device.
  • Hi Julian,
    I check the FrontBoard isp point between 5v and gnd: without stm32 inserted 450ohm
    with stm32 inserted same point: 1000ohm
    on the mainboard between connectors to the front 520ohm between 5v and gnd (following schematic between conn P1 point 25 and +5V pt 23/24) or nothing if I swape the probes (testing the gnd probes on the +5V and the red one on the Gnd from the board)
    and between 3.3v and gnd 474ohm...
    I am getting really confused now? could it be the regulator  lf33 on the mainboard?
  • Hello. Here is a little report. Of my current situation with the stm.
    I've been since last time trying different option thinking it might be possible to fix it (changing the first cap on the mainboard and changing the regulator , applying power only to 5 and gnd...no matter what I did that's no better luck) I still have that drastic voltage drop. I guess that mean the stm is fried and I'll have to get a new one in a while. However I'd like to know what could have cause the main board to die? I mean apart from bad handling at the building time, all those various moments were I read I should have been more careful about the mobo and I haven't, is there any specific place on the front board that could cause the mainboard to die. More important is it possible to resurrect it?
    Thanks for the help anyway
  • edited January 2015
    What makes you think the STM is fried, its a uC, nothing going bad with that would cause what you're seeing.  A voltage drop is usually the result of a power rail short..  How hot are the voltage regulators getting?  Put your meter in diode mode (beep mode) and check 3.3V and 5V rails against ground with the device off and everything in place
  • @Altitude Hello, I suppose the stm32 fried for two reasons : I believed in the worst case scenario/murffy's law a bit too much. More seriously there is so many thing I don't fully understand between the way you program those MCU and the way they interact with the Hardware, that I tend to breaks things easily. And at the moment I can't afford another STM.
    The second reason is much more simple: the Stm32 get really hot under power!? I just realized now and I unplug. Before then I tried different way of powering it: either with the 16*2 pin plug on the front board or only the gnd and 5v of the Atmega isp directly to them on the mainboard. I tried also from another Psu on a shruti (without digital board). I just been trying a different Wallwart as I realised it has to be 600ma min. and I was using one which could deliver only 500ma, the new one is meant to be 600ma which give me no headroom but I assume the 600ma requirement already took that into accoumpt.
    eventually here are the result of my new test with black probe on ground and red on 5v: nothing (1)
    between 3.3 and gnd: no beep and 498ohm...
    All of that without pluging the stm32 to the frontBoard. (I could do a bit later during the evening the same test the two board plug together)
    I'm not sure how to do further investigation. I change the regulator (inserted three header where I took those new test) it is a 1086 ct33. I tried also to plug a second stm32 discovery with no loss of power and I endvisaged to use it as programmer for the mainboard but reading Julian answer I've been focusing on hardware problem rather than soft.
    Tonight I will resolder the 2.2uf electrolyte C47 and the 104before the regulator as I thought for a minute that they could be the culprits...
    If their is a short between the 3.3 and the gnd is there any method to narrow the area where it could be? That would be a really good advice ;)
    anyway thanks Julian and Altitude for the help
  • Oups I forgot to say even if the stm get hot I still haven't seen any smoke... maybe a glimpse of hope.
  • That's a clue, it shouldnt get that hot.. That low resistance on the 3.3 sounds fishy
  • altitude is right.
    the stm should not get hot.
    can you make a high resolution picture of the mainboard?
  • Yep it's pretty much what I thought... This morning I tried to power up the stm only with a lab power supply : it gets really really hot and around 680ma... Sounds like a lot?
    I could had some high def pictures but I think it is down for now...
    Might be a silly idea but "could a really bad firmware update mess up every setting internally and let the stm in a sort over clock mod?"
  • it should not pull 680ma :(

    I doubt a wrong firmware update could do this.
    If there are normal IO pins directly connected to GND (which there are none on the mainboard) and the firmware would put them to +3.3V the chip could get hot.
    But on the mainboard the unused pins are left unconnected.

    If you really wanna be sure, use the ST-Link on your discovery board to erase the chip or re-program the bootloader. But I doubt this will help.

    I think it is much more likely that 2 pins are shorted somewhere or something like that.
    So a pic would really help to convince me otherwise. ;)
  • @julian I've been downloading the zip from your link...I don't understand what's in it as it appears to be a single file with no extension and around 1,3mo?
    I'm also wondering if there is anywhere on the forum a full capture of the main board layout?
  • edited January 2015
    It seems the STM-chip of your board is fried, brown spot near the 'Z'. I had the same problem once because of wrong powered USB-hub....
  • @vibes71 thanks for the advice... But so far I haven't inserted anything into the USB socket. Having said that my plan is to get a new like you did asap ;)
  • @kooorps You should definitely get a new board because you're gonna love the LXR :)
    (Be shure there are no shorts elsewere and no parts are mixed up...reflowing solderpoints helped me in some cases)
  • Well I had another really really silly Idea waiting for till I get a new one:
    Thinking it can't be worst than what it is already...I took away the fried chip from the mainboard and did the same with the one from the discovery...sad? isn't it ;)
    anyhow it seems it's been working. I check shortcut between every pins on the mainboard and it seems to be ok...the most freaking part is the fact I could program my frankenstein mainboard with the STlink.
    Thing is I've been fiddling with the sources to build the bootloader and the firmware only for the mainboard...as I said earlier I know nothing at all on the all process Toolchain etc etc. So even If I could upload something on the mainboard I'm not quite sure of what I'm currently uploading?
    A bit of help from those guys who know how to program would be really appreciated :)
    @vibes71 I've heard about the LXR since Batch one...lurking waiting to get it And now I fried it aaaahh...Sure as soon as I could I'll get a brand new one!
  • so you successfully transplanted the STM32 from your discovery board to your mainboard? :^o
    I was just about to offer you a replacement mainboard ;)

    I still have no idea what could have caused your chip to be fried :-/

    about the file - I think the linux zip tool must be broken at the moment. Someone else complained too and I can't open the file from my windows machine. So here is another link to the non compressed bootloader.hex file


    are you on windows? Then I recommend the STM ST-Link utility to flash the chip. Easy to use GUI and error reporting ;)

  • edited February 2015
    Hi Julian! Thank you for the Boot loader it was exactly what I needed. I just had few pictures of the process in case someone else need it.
    If I do a quick recap:
    1unsoldered the two stm and resolder with airflow station
    2check for shorts between every header on the main board
    3it might sound obvious for most of you, but use the St link with SWD pin without jumper on the discovery board (unconnected the St link from the discovery)
    4 upload boot loader through stlink utility
    5 reboot lxr in boot mod with a firmware.bin in SD card
    6 reboot after update finished...et voilà :)
    Now I'm thinking about a homebrew Frankenstein Graphisme as it sounds so good and heavy but it's such a freak inside!
    Thanks again Julian for the lxr and your help and the boot loader!
  • edited February 2015
    Another little note about the Atmega 644P burning process. I've used mainly flag I've found over the mutable instrument website as it turn out the fuse setting are lightly different compare to the 644. Here is what I used once moved in the root folder of avrdude:

    # Step01 set fuses 
    avrdude -B 100 -V -p m644p -c avrisp2 -P usb -e -U lock:w:0x3F:m -e -u -U efuse:w:0xFD:m -U hfuse:w:0xD6:m -U lfuse:w:0xFF:m -U lock:w:0x0f:m

    # Step02 flash bootloader and Step03 lock bootloader
    avrdude -B 1 -V -p m644p -c avrisp2 -P usb \ -U flash:w:SD_Card.hex:i -U flash:w:DrumSynthFront.hex:i -U lock:w:0x2f:m

    hope it could be useful to anyone but watchout I'm really not sure of what those instruction does ;)
  • great work! ^:)^

    these are the AVR fuse settings I use:

    # set fuses
    avrdude   -B100 -c usbasp -p m644 -U lfuse:w:0xff:m -U hfuse:w:0xd8:m -U efuse:w:0xfc:m

    # flash bootloader
    avrdude  -B1  -c usbasp -p m644 -U flash:w:bootloader.hex:i

    # lock bootloader - BLB1 Mode 2 = SPM is not allowed to write to the Boot Loader Section
    avrdude  -B1  -c usbasp -p m644 -U lock:w:0x2F:m
  • Hello everyone,
    as I've been trying to update few times my lxr without any success Irealized the setting for the fuse I choose ages ago are creating lots of trouble.
    Here are the new one I've been using
    avrdude -B100 -V -c avrisp2 -p m644p -P usb -U lfuse:w:0xfd:m -U hfuse:w:0xd0:m -U efuse:w:0xfd:m
    Eventually It seems that with the one above it's working better.
  • ok sorry for the post above...didn't work at all. I went back to my original settings
Sign In or Register to comment.