Avatar for François

François

Member since Dec 2016 • Last active Nov 2021
  • 2 conversations
  • 26 comments

Most recent activity

  • in Puck.js, Pixl.js and MDBT42
    Avatar for François

    NDEFWriter has been merged into NDEFReader recently. See https://github.com/espruino/EspruinoDocs­/pull/589

  • in Other Boards
    Avatar for François

    Ok, wow - that's news to me. I think there's a very high likelihood it's to do with the micro:bit's USB-TTL conversion. Does it happen on other boards.

    I don't know.

    No... I haven't come across it. I guess it could be losing the serial data somewhere along the line?

    Is there a tool I could use to monitor raw serial data?

  • in Other Boards
    Avatar for François

    serial break? I'm not quite sure I understand...

    In JavaScript, I call port.setSignals({ brk: true }); which sends the break signal.

    You could send "\x03\x10reset()\n"? The issue (I believe) is that on 'normal' USB Espruino boards the USB goes right to the microcontroller running Espruino, so it can keep the serial data buffered until it sees a connection.

    I've tried this without luck sadly.

    I could be wrong but I think that everything still works ok, just not the magnetometer?

    Indeed compass() and acceleration() don't work.

    One more and last thing
    I've noticed 2v06 (c) 2019 G.Williams in the prompt message was sometimes missing the ending \n. Basically ending with \r, instead of \r\n. Is this a known issue?

  • in Other Boards
    Avatar for François

    I'm currently using the Serial Web API to communicate with the BBC micro:bit and I'm loving it so far!
    There are some nits I'd love to understand though and I thought you folks may know the answer.

    I'm able to connect to the BBC micro:bit device and open the serial port at 9600bps. /me happy
    Then my readLoop doesn't show anything until I turn off serial break for instance. Is this expected?
    Is there another way to "force" the device to send the usual prompt when port is opened?

    Then, the prompt I get contains the "Uncaught InternalError: I2C Write Error 33281" message as shown below. Is there something going on I should fix?

    
    script.js:53 [?7l
    script.js:53  ____                 _ 
    script.js:53 |  __|___ ___ ___ _ _|_|___ ___ 
    script.js:53 |  __|_ -| . |  _| | | |   | . |
    script.js:53 |____|___|  _|_| |___|_|_|_|___|
    script.js:53          |_| espruino.com
    script.js:53  2v06 (c) 2019 G.Williams
    script.js:53 Espruino is Open Source. Our work is supported
    script.js:53 only by sales of official boards and donations:
    script.js:53 http://espruino.com/Donate
    script.js:53 Uncaught InternalError: I2C Write Error 33281
    
  • in Puck.js, Pixl.js and MDBT42
    Avatar for François

    Woohoo for Uri!

  • in Puck.js, Pixl.js and MDBT42
    Avatar for François

    How about audio related stuff?
    Speaker, beep, etc.

  • in Puck.js, Pixl.js and MDBT42
    Avatar for François

    @Gordon is right.
    Web Bluetooth is supported by default (no flag) on Mac, Android and Chrome OS.
    On Linux, you need chrome://flags/#enable-experimental-web-­platform-features experimental flag for now.

  • in Puck.js, Pixl.js and MDBT42
    Avatar for François

    Here's what we know from Emil:

    Unfortunately, no platforms I'm aware of have well-defined behaviour
    nor documented APIs to handle the case when the maximum number of
    connections is reached. It seems people working on Bluetooth stacks
    have not really thought, cared about or even tested what will or
    should happen if users have many BLE devices. As an example, the
    Bluetooth stack in Android hangs if you have 7 BLE connections and try
    to establish the 8th with "autoConnect=true" (in the way that it will
    never again connect to BLE devices until Bluetooth is restarted, even
    if the 7 get disconnected). If you have GATT notifications you listen
    to in Windows and are above the maximum number of connections, you get
    no event telling this, so some notifications will not be delivered to
    your computer (since the peripheral can't connect). Generally among
    most platforms some random error code is thrown (general failure,
    internal error, unspecified error, gatt error) when you actively try
    to connect a new device when the maximum number of connections has
    been reached. Sometimes a better error code like "no resources" is
    thrown. The non-existing documentation of error codes that is
    unfortunately general among all BLE implementations is very annoying
    when you are an app developer (Windows must be the worst when they're
    trying to map BLE errors to their general 0x80... HRESULT error
    codes).

    Source: https://github.com/WebBluetoothCG/web-bl­uetooth/issues/342#issuecomment-26811708­5

Actions