Avatar for ExperimentalZeros

ExperimentalZeros

Member since Jul 2016 • Last active Mar 2018
  • 0 conversations
  • 13 comments

Most recent activity

  • in JavaScript
    Avatar for ExperimentalZeros

    @MaBe
    Excellent! Great approach!

    @Gordon
    Thank you for the explanation, it does make sense.

  • in ESP8266
    Avatar for ExperimentalZeros

    You are correct! Voltage Divider on-board! Thanks

  • in ESP8266
    Avatar for ExperimentalZeros

    Now I understand - I used to send it this way and it complained:

    >analogRead(A0)
    Uncaught ReferenceError: "A0" is not defined
     at line 1 col 12
    analogRead(A0)
               ^
    

    .... All I had to do was send it like this analogRead(); to get it work!

    NOTE: On the WeMos website they mention that max on the analog read is 3.2v... we sill see.

    Thank you all!

  • in JavaScript
    Avatar for ExperimentalZeros

    Some background Info:

    I am using Espruino as an "external interface" to LabVIEW so I can control hardware away from my setup. I send and capture messages over TCP/IP and utilize its elements to either display and/or do something else.

    Over the computer I can discard anything from return string dump, utilize the information I need, and move on with the tasks. Nevertheless, I was really wondering how useful is the displaying of such type information is.

    And, if I am missing the whole point, please forgive me, I would love to take advantage of it.

    Still, regardless of how many messages are read or written: Aren't all I2C messages 1 Byte (Uint8) long by standard?

    Thank you all.

  • in JavaScript
    Avatar for ExperimentalZeros

    Hopefully this is the proper place the following question:

    with the following code:

    I2C1.setup({sda:D4,scl:D5});
    
    //var result;
    
    function m(){
    var PAYLOAD = [];
    var data = [];
      for (var i = 0; i < 2; i++){
        I2C1.writeTo(0x40,(i));
        data = I2C1.readFrom(0x40,0x02);
        PAYLOAD.push(data);
    	}
      
    //result = PAYLOAD;
      return PAYLOAD;
      
    }
    

    I get the following output:

     _____                 _
    |   __|___ ___ ___ _ _|_|___ ___
    |   __|_ -| . |  _| | | |   | . |
    |_____|___|  _|_| |___|_|_|_|___|
              |_| http://espruino.com
     1v86.tve_master_247bc37 Copyright 2016 G.Williams
    Espruino is Open Source. Our work is supported
    only by sales of official boards and donations:
    http://espruino.com/Donate
    Flash map 4MB:512/512, manuf 0xe0 chip 0x4016
    >echo(0);
    =undefined
    >
    =undefined
    >m();
    =[
      new Uint8Array([113, 39]),
      new Uint8Array(2)
     ]
    > 
    

    My question(s):

    1.- What is the purpose of displaying new Uint8Array([113, 39]), instead of [113, 39]?

  • in ESP8266
    Avatar for ExperimentalZeros

    TI INA3221: "INA3221 Triple-Channel, High-Side Measurement, Shunt and Bus Voltage Monitor"
    a.- (Dev Kit by SwitchDoc Labs : http://store.switchdoc.com/ina3221-break­out-board-3-channel-current-voltage-moni­tor-grove-headers-compare-to-ina219-grov­e-headers/ )

    b.- I2C works with: I2C1.setup({sda:D4,scl:D5});

    c.- Physical Pinouts are SCL/D1 and SDA/D2 (3 places on the board)

    d.- PullUps @ 4k1 Ohms

    E.- Work In Progress

  • in ESP8266
    Avatar for ExperimentalZeros

    @DrAzzy @tve I am very sorry, I meant to say analogRead()... but thanks for all the information!!! It has opened new resources I was not aware of!

  • in ESP8266
    Avatar for ExperimentalZeros

    @MaBe

    Thank you, very relevant I2C information. Also, I will update the I2C Implementation table.

  • in ESP8266
    Avatar for ExperimentalZeros

    @Frida and @MaBe,

    Thank you both for such quick response! I will sure wait for the update!

  • in ESP8266
    Avatar for ExperimentalZeros

    @Frida, or anyone

    That did it! I don't have a Logic Analyzer, but from your knowledge:

    1.-What do you think the data rate will be? Is fixed to a specific value or it fluctuates? those questions matter as I would like to size the pull-up resistors accordingly.

    2.- Do you by any chance know about AnalogWrite pin value or how to find it? I tried it to just put values starting at "A0" and kept on going (who knows how many iterations) without any luck.

    Thank you!

Actions