Avatar for GeekBot

GeekBot

Member since Jun 2016 • Last active Dec 2016
  • 11 conversations
  • 44 comments

Most recent activity

  • in General
    Avatar for GeekBot

    I use a Saleae logic analyzer. You can purchase one on their website.
    It works great.
    GeekBot

  • in General
    Avatar for GeekBot

    Hello,

    I try to connect a radio module using an SPI link (on SPI3, Espruino Pico, Firmware V1.90)
    Here is my code :

    SPI3.setup({sck:B3, miso:B4, mosi:B5, baud:10000, mode:0, order:'msb'});
    var registreW = {data : 0x81, count : 1};
    var modeASK = {data : 0x23, count : 1};
    var returnedData;
    returnedData = SPI3.send(registreW,A7);
    console.log(returnedData[0]);
    returnedData = SPI3.send(modeASK,A7);
    console.log(returnedData[0]);
    

    NSS Pin is A7.
    Since this code doesn't work (communication doesn't work), I had a look at signals with the logic state analyzer.
    I attach a screen capture. In fact, NSS PIN is set high too early, when the last byte is not totally sent. I looked at the code line 212, the PIN change seems to be executed without knowledge of end of transmission, but I can be wrong !!
    Help will be greatly appreciated.
    Best regards
    GeekBot

  • in General
    Avatar for GeekBot

    I did some more measurements.
    Battery voltage 2.78V
    3.3 V output : 2.5V
    LED1 turned on, Espruino running.
    I confirm that the transistor has just some mV of voltage drop.
    Since, I estimate the current over 35 mA, I have to look at the regulator datasheet to see if it is an expected value.
    Anyway, I manage with these figures!
    GeekBot

  • in General
    Avatar for GeekBot

    @Gordon, thank you, I will do accurate measurements and reporting tomorrow. I come back to you.
    Best regards
    GeekBot

  • in General
    Avatar for GeekBot

    Thank you Gordon. So I connected on BAT_IN as you suggest, it's clearly much safer and easier to manage with USB connection. The voltage drop is about 0.3 V. That's 10% of the battery voltage, but acceptable for my application. I guess this drop comes from the MOS transistor?
    Best regards
    GeekBot

  • in General
    Avatar for GeekBot

    @Gordon, eventually I have a doubt; the 'Bat' pin you talk about is the 'VBat' pin (PIN2 of J2 on Pico, called 5V on the schematic) ?
    Because there is also the VBAT on the schematic which is the PIN 1 on J1, and called BAT_IN on the Pico coloured diagram on the web site.
    According to our discussion, I guess the 'Bat' is the 5V on the schematics, but I need to be absolutely sure.
    Thanks a lot
    GeekBot

Actions