Avatar for Hansi

Hansi

Member since Jul 2017 • Last active Sep 2017
  • 3 conversations
  • 13 comments

Most recent activity

  • in ESP8266
    Avatar for Hansi

    Could you please explain what 'heap' in the output means?

    Problem is that after starting of program everything is ok, I make 3 requests at the same time every 180seconds. But on 10th time it shows error - out of memory, and every time it happens on different try. Probably I should clean ram somehow after each request or something like this? (using of non-custom font helps a little bit, but errors still happen).

    ERROR: Out of Memory!
    ERROR: Error processing Serial data handler - removing it.
    Execution Interrupted during event processing.
    Uncaught SyntaxError: Expecting a valid value, got EOF
     at line 1 col 22
    {"count":1,"results":[
    

    Thank you for answers!

  • in ESP8266
    Avatar for Hansi

    Thanks, it helps) now need some time to pick some normal melody)

  • in ESP8266
    Avatar for Hansi

    Could anyone explain this message in console:

    ets Jan  8 2013,rst cause:2, boot mode:(3,0)
    load 0x40100000, len 2408, room 16
    tail 8
    chksum 0xe5
    load 0x3ffe8000, len 776, room 0
    tail 8
    chksum 0x84
    load 0x3ffe8310, len 632, room 0
    tail 8
    chksum 0xd8
    csum 0xd8
    2nd boot version : 1.6
      SPI Speed      : 40MHz
      SPI Mode       : DIO
      SPI Flash Size & Map: 32Mbit(512KB+512KB)
    jump to run user1 @ 1000
    âìpNä{òn|ìdl â{püLoading 1298 bytes from flash...
    

    Is it mean that I run out the memory?

  • in ESP8266
    Avatar for Hansi

    Hello,

    Does anyone have working examples with passive buzzer?
    Because when I try this:

    analogWrite(A0, 0.5, { freq: 1000 } );
    
    

    I have such message:

    >Uncaught ReferenceError: "A0" is not defined
     at line 1 col 13
    analogWrite(A0, 0.5, { freq: 1000 } );
    

    I've also tried digital pins, but no sound in result(and no error).

    Could anyone show working example? (https://www.espruino.com/Making+Music doesn't work for me)

    Thanks

  • in ESP8266
    Avatar for Hansi

    oh, thanks, Gordon, good support on your forum.
    Now my project is possible!!!

    • 2 comments
    • 182 views
  • in ESP8266
    Avatar for Hansi

    Have you checked via desktop node.js or your microcontroller?

    Oh, finally I've found my mistake, current result:

    =undefined
    Got response: 200
    {"count":1,"results":[{"num_favorers":34­,"include_dispute_form_link":false}],
    Uncaught SyntaxError: Got EOF expected '}'
     at line 1 col 78
    ...dispute_form_link":false}],
                                  ^
    in function called from system
    {"count":1,"results":[{"num_favorers":34­,"include_dispute_form_link":false}],"pa­rams":{"shop_id":"FoxyGami"},"type":"Sho­p","pagination":{}}
    34
    

    Now I can receive what I want. Just don't know why it always shows such messages:

    {"count":1,"results":[{"num_favorers":34­,"include_dispute_form_link":false}],
    Uncaught SyntaxError: Got EOF expected '}'
     at line 1 col 78
    ...dispute_form_link":false}],
                                  ^
    in function called from system
    

    In node.js is just:

    Got response: 200
    {"count":1,"results":[{"num_favorers":34­,"include_dispute_form_link":false}],"pa­rams":{"shop_id":"FoxyGami"},"type":"Sho­p","pagination":{}}
    34
    
  • in ESP8266
    Avatar for Hansi

    Oh, thank you so much!

    Now it works in my desktop node.js

    var http = require('http');
    
    var options = { host: 'httptohttps.mrtimcakes.com', 
                path: '/https://openapi.etsy.com/v2/shops/shop­ID?method=GET&api_key=apikey',  
                headers: {'user-agent': 'Mozilla/5.0'}
                };
    
    http.get(options, function(res) {  
        console.log("Got response: " + res.statusCode);
        var dataQueue = "";
        res.on('data', function(d) {
            dataQueue += d;
            console.log(dataQueue);
            myObj = JSON.parse(dataQueue);
            console.log(myObj.results[0].num_favorer­s)
        });
    
    }).on('error', function(e) {
        console.log("Got error: " + e.message);
    });
    

    but when I try the same in ESP8266 I receive

    =undefined
    Got error: not found
    

    But now it's closer to the solution!)

    UPD
    And ordered Espruino WIFI to try it later when it comes, but before I want to finish this problem with ESP8266

Actions