Avatar for Nickax

Nickax

Member since Jul 2018 • Last active Jul 2018
  • 1 conversations
  • 13 comments

Full stack developer by day.
Trying to build a water heating and refrigeration control system for a camper van based on a Pixel.js

Most recent activity

    • 25 comments
    • 355 views
  • in Projects
    Avatar for Nickax

    Thanks

  • in Projects
    Avatar for Nickax

    I have an r-pi ... two in fact - and my experience with those has been equally, if not more frustrating - the plethora of languages and versions - and the sea of incompatible out out of date samples made it more or less impossible to work with.

    The elegance and simplicity of Espruino are what drew me to it - JS is NOT my favourite language but a year of writing TypeScript as a day job has softened my hatred slightly. What I can see is that for someone with no prior knowledge it is relatively easy to pick up as it is fairly compact. For someone from an OO background its a more difficult switch.

    I have limited spare time so I make the classic mistake of trying to skip the examples and videos - but I will try and avoid that temptation and get a better understanding of how it all works.

  • in Projects
    Avatar for Nickax

    Hi again

    Just to repeat that the thing that solved it for me was the 'throttle send' option in the communications section of settings.

    All (well, most) of the problems melt away once it actually runs the code you send.

    Interestingly - I was also able to go back to the original code sample - with the require() up-front, and it worked just fine.

    I think the lesson here is to rule out the simplest causes first.

    The real question is why do some people 'experience lost characters' and what is the real fix.

    I don't know how common the problem is - common enough for there to be a tickbox.

  • in Projects
    Avatar for Nickax

    Thanks ... I have a lot to learn
    It seems some JS knowledge helps - but there is a lot more to know.
    All good fun.

  • in Projects
    Avatar for Nickax

    My (dumb) mistake ... I was caught out by the unused pin
    First little label - first pin .. WRONG

    25.9375 C

    Hurrah !

    What's a software resistor ? - sounds like the kind of thing you send the apprentice down to the stores for - like a long weight, or green oil for the starboard lamp.

  • in Projects
    Avatar for Nickax

    Thanks again for another comprehensive reply.
    I could live with/check for the odd null .. what I'm actually getting now is the '85°c' problem.
    I get lots of nulls - then squish my dodgy wiring together and start getting repeated 85°c
    I thought it might be farenheit for a while.. but it's not that warm in here .. yet.
    And I see on the forums that 85 is a magic number

    I have a 4k7 (yellow,purple, red,gold) resistor between 3.3v and Data and the sensor accross D13 and GND
    Power 3.3v is applied to pin3 (not parasitic mode)

    I think this is as per your example page - but maybe I misread somewhere

  • in Projects
    Avatar for Nickax

    Right... the fix appears to be to use the 'throttle send' option in the communications section of settings.

    Without it - I get stupid syntax errors about EOF encountered and expecting } - when all my braces are present and correct.

    With it .. worked first time

    (This is with the code refactored as per @Gordon 's suggestion - but I suspect the original may work)

    (Well, I say worked - my temperature comes back as null all the time but that's a different problem)

    I feel like I'm in with a chance now.

    Thanks everyone

  • in Projects
    Avatar for Nickax

    Hi Gordon

    Nice to meet you .. I (potentially) love what you are doing and have high hopes for my Pixl.

    I did indeed see that FIFO buffer error at least once .. but definitely not every time.

    I will try both of your suggestions - I'm not sure of the rationale for executing each line as it uploads - I can see that any setInterval could fire for a function not yet defined - or for that matter simple function calls could fail. Maybe I misunderstand (entirely).

    I could see I was getting syntax error on code I hadn't written - some sort of corruption.

    Apologies for my bad manners in code formatting.

    My laptop is an HP Spectre 360 - it has Bluetooth but I don't know if it's 'LE' - could that have anything to do with it ?

    BTW I'm using the native IDE not the web one .. I will see if it has a save on send option.

  • in Projects
    Avatar for Nickax

    Thanks allObjects

    I will try moving my code into onInit() and restarting the board after each upload - although that seems like the bad old days.

    If OTA is so flaky - why is there no wired option for the Pixl ? - rhetorical question don't worry.
    My Pixl is 20cms from my laptop - and actually powered from in over a USB cable.

    I can see how it should work - and if it did - it would be a thing of beauty - But I have stumbled on some really silly fundamental problems.

    I understand about copy and paste - and invisible whitespace characters - (carriage returns, line feeds etc).. that caught me out early on but I have enough experience to spot it.

    The 'Level 0' setInterval() thing - I will need to read up on - I took setInterval() to be the primary mechanism for running asynchronous code - I'm just surprised and frustrated the upload mechanism is so fundamentally flawed.

    Again thanks for your reply

    Nick

Actions