• Hello,

    When I try to setup a serial port this board hangs with espruino. I have two boards which has the same problem.

    I have used this commands

    Serial1.setup(9600,{rx:B7,tx:B6});
    Serial2.setup(9600,{rx:B7,tx:B6});
    Serial3.setup(9600);
    Serial2.setup(9600);
    etc...

    all those commands hangs the board, board doesn't response any more. I have tried those binaries

    espruino_1v80_stm32vldiscovery.bin
    espruino_1v91_stm32vldiscovery.bin
    espruino_1v92_stm32vldiscovery.bin
    espruino_1v93_stm32vldiscovery.bin

    Am I doing some thing wrong?

  • On the VL board you're communicating via Serial1 on pins A9/A10 to get a Serial console. Is it possible that when you call Serial1.setup(9600,{rx:B7,tx:B6}); you're just moving the serial port to another place, which means you no longer get a response?

    What if you type setInterval("LED.toggle",500) beforehand - so an LED will flash on and off. Does it keep flashing after you issue the command?

  • Hello Gordon, thank you for your response.

    I think this problem is not about Serialx, I tried your code.

    setInterval("LED.toggle",500)
    //device failed here
    

    this command hangs too. device doesn't response after this command and led is not flashing.

    One more issue;
    If I type an undefined function or variable, it also hangs like this :

    gogogo
    Uncaught ReferenceError: "gogogo" is not defined
    Execution Interrupted
    //device failed here
    

    board doesn't response after this command too.

    here is some output that works well and hangs at the end.

    _____                 _
    |   __|___ ___ ___ _ _|_|___ ___
    |   __|_ -| . |  _| | | |   | . |
    |_____|___|  _|_| |___|_|_|_|___|
              |_| http://espruino.com
     1v91 Copyright 2016 G.Williams
    Espruino is Open Source. Our work is supported
    only by sales of official boards and donations:
    http://espruino.com/Donate
    >console.log('Merhaba')
    Merhaba
    =undefined
    >1+1
    =2
    >x=function() { console.log("Merhaba")}
    =function () { ... }
    >x()
    //device failed when I call x() but all the others worked good until this one.
    
  • Ok, thanks - I'll need to look into this. It's possible that over time the amount of free stack available in the VL image has dropped to the point where it's not really usable.

  • Thank you for your response Gordon.

    I will change my board.

  • Yes, it's probably the best bet I'm afraid. The VL doesn't have much free memory with Espruino on it, so is quite limited

  • Post a reply
    • Bold
    • Italics
    • Link
    • Image
    • List
    • Quote
    • code
    • Preview
About

Serial1.setup(9600...) hangs on STM32 VL Discovery

Posted by Avatar for fobus @fobus

Actions