Avatar for the1laz

the1laz

Member since Mar 2015 • Last active Jul 2018
  • 9 conversations
  • 143 comments

I'm an electrical engineer who spends to much time automating his house. I post about my projects on http://www.addictedtopi.com

Most recent activity

  • in Projects
    Avatar for the1laz

    Hmm, not sure about that one. The code looks good, but the error message is indicating some of the code didn't make it, no idea why, I've never had an issue with sending code (to official boards) before. Might need @Gordon 's help. I'd recommend power cycling both your computer and the Pixl if you try again in the meantime, might be a Bluetooth connection issue.

  • in Projects
    Avatar for the1laz

    No problem. :) Yeah, I've seen a few other people miss that before. FYI, the left side is running commands directly on the board via a console, if a module isn't on the board yet, the board can't grab it. The right side will search your code for "require" and send the modules you need to the board before uploading your code.

  • in Projects
    Avatar for the1laz

    Hi Nick, are you typing this into the left hand side or right hand side of the IDE? Most modules aren't built into the firmware, the IDE loads it onto the board when you upload code from the right hand side. You could try typing the same code into the right hand side, or type

    require("DS18B20") 
    
    

    into the right hand side and click upload, which will load the module, then type your code into the left hand side.

  • in Puck.js, Pixl.js and MDBT42
    Avatar for the1laz

    All good, thanks for looking. 👍

  • in Puck.js, Pixl.js and MDBT42
    Avatar for the1laz

    It's in the spec and I've seen it done, it doesn't seem to be a common thing though. Most devices only have a single temperature reading, magnetometer or whatever.

    I was looking at how to have a bunch of generic I/O using the standard characteristics. No big deal for me to use 128 bit UUIDs or do it some other way, I was just trying not to reinvent the wheel.

  • in Puck.js, Pixl.js and MDBT42
    Avatar for the1laz

    BLE seems to support multiple of the same UUID for services and characteristics, for example you could use the automation IO service with 4 digital characteristics. With Espruino, specifying the services as an object seems to prevent that as the keys won't be unique, ie:

    NRF.setServices({
      0x1815: { // automation
        0x2A56: { // digital
          readable: true,
          value : 1,
        },
        0x2A56 { // digital --> gets ignored as it's a duplicate key
          readable: true,
          value: 0
        }
      }
    });
    

    Is there any way around this?

  • in Other Boards
    Avatar for the1laz

    I definitely swapped the ch340g pins a few times to be sure. Not sure if I swapped the pins on the pl2303hx, but both pins had the same voltage on when measured. All good for me now that I found one that works, but could be a bit harder to work out for someone who doesn't have a pile of random usb-uart modules lying around.

  • in Other Boards
    Avatar for the1laz

    I flashed the espruino_1v97.99_nrf52832.hex travis build to an MDBT42Q module to give it a spin but couldn't connect via serial. I can connect to it via BLE but serial just wasn't working. I found the notes about it needing to see 3.3V on D8 so I checked it out and found that my CH340G (clone?) only had about 1.7V on RXD. I grabbed another USB-serial module, this time a PL2303HX (clone?) and found only about 0.6V on RXD. Finally tried a CP2102 (clone?) and it worked fine with 3.3V on RXD in idle.

    My reference devices are all off aliexpress and not necessarily reliable adherers to good UART practices, but detecting full voltage on that pin might not be a good indicator of when a serial connection is there. Maybe checking for >0.5V using the ADC would be more reliable? I imagine this would affect a puck-js as well, I can't test on mine because I've got the pins already soldered to something.

Actions