Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
    Sergey Lyubka
    @cpq
    mos1 ls
    api_adc.js
    api_arch_uart.js
    api_aws.js
    api_bitbang.js
    ...
    mookiedog
    @mookiedog
    The console is silent, except for the messages that my app produces once in a while.
    Sergey Lyubka
    @cpq
    works for me.
    Forrest Wallace
    @fwallacevt
    Looks like it's mounting from too high up, but only in this directory. If I delete everything in the directory and get a fresh copy of the example project, it works. Thoughts on what could be causing that? (firmware-extras is a github repo)
    Building...
    mount from "C:\\Users\\fwall\\projects\\Git\\firmware-extras" to "/app"
    mount from "C:\\Users\\fwall\\projects\\Git\\firmware-extras\\default\\deps\\mongoose-os" to "/mongoose-os"
    Sergey Lyubka
    @cpq
    interesting... no idea tbh
    mookiedog
    @mookiedog
    Why would I not see any messages arriving at mos-1517502659/#. That would seem to be an issue somewhere between the mos tool and amazon. At that point, my device is not even in the loop. The error message from the mos gui I originally sent was complaining about a bad TLS certificate [Jan 29 16:00:08.077] E0129 16:00:08.077077 21244 reconnect_wrapper.go:93] [reconnectWrapperCodec to mqtts://an4w0fzy06dsc.iot.us-west-2.amazonaws.com:8883/esp32_0C1C84; connect in 2.00s] connection error: MQTT connect error: Network Error : remote error: tls: bad certificate
    Which certificate is it talking about?
    Sergey Lyubka
    @cpq
    the one given by --cert
    mookiedog
    @mookiedog
    That cert works fine to publish data, so I would have to think that it is OK. The only weird thing In noticed about the cert is that it has some CR/LF line endings in its header. Not the lines in the body where the actual cert data is, just the header.
    hazardandy
    @hazardandy
    I think I remember some chats about storing core dumps locally and then posting them via AWS once rebooted and reconnected. Was that implemented somewhere?
    Sergey Lyubka
    @cpq
    nope
    hazardandy
    @hazardandy
    Trying to reduce the likelihood that we're busy during wifi stuff to eliminate beacon timeout. If we're in a mgos_set_timer callback, does that block everything else from happening? Trying to decide if I should just make one long callback that does everything we need to do in one go, or multiple smaller timers that will have gaps between them.
    Sergey Lyubka
    @cpq
    is it esp8266 ?
    hazardandy
    @hazardandy
    yea
    Sergey Lyubka
    @cpq
    yeah, when callback runs, everything else is stopped
    hazardandy
    @hazardandy
    Loading the empty app onto a nodemcu causes beacon timeouts literally every minute or so, but only that often on the router bolted to the ceiling. Been trying to replicate with a different router that I could ship to you. Running our full code causes the timeouts at least once every few hours regardless of the router, and sub-minute timeouts with the ceiling router.
    Have oodles of packet captures and am extremely confident it isn't our hardware (same results with our board and with nodemcu)
    Sergey Lyubka
    @cpq
    got it
    hazardandy
    @hazardandy
    ESP32 will pull context away from the app to handle wifi in all cases except for maybe a hardware interrupt?
    Sergey Lyubka
    @cpq
    on esp32, there are dedicated rtos tasks
    for wifi, bt, etc
    mos also runs in its own task
    hazardandy
    @hazardandy
    Oh, right, because mos is built on top of the IDF instead of on top of nonos sdk
    Sergey Lyubka
    @cpq
    yeah
    hazardandy
    @hazardandy
    all future products = esp32, but it's way too late to switch for this one.... :(
    Jonathan Witthoeft
    @JonWitthoeft_twitter

    For the esp32, I am switching from a 4MByte to 2MByte flash and am getting this error when trying to flash:

    partition 4 invalid - offset 0x1d0000 size 0x180000 exceeds flash chip size 0x200000

    Where can I define flash size when building so to get a valid partition table that fits in a 2MByte flash?
    Also my firmware image is about 800k. How can I support OTA? Will I be able to support OTA if I decrease the file system allocation?

    Deomid Ryabkov
    @rojer
    flash < 4MB is not currently supported, you'll need to tinker with partition table yourself. but really - just leave it be.
    you may be able to squeeze into 2MB by reducing FS_SIZE and APP_SLOT_SIZE
    Forrest Wallace
    @fwallacevt
    Hi, is there currently anything in place to allow us to track metrics for applications (like CPU usage, memory usage, etc)?
    Jonathan Witthoeft
    @JonWitthoeft_twitter
    @rojer Do I then have to change the addresses for APP_SLOT and FS_ADDR, or are those automatically adjusted during the build based off of the sizes?
    mookiedog
    @mookiedog

    @mookiedog ok login to AWS IoT console, click on "test" , load up MQTT client. subscribe to mos-1517502659/#. Run mos command again, see if any message arrives

    I did the same AWS console thing, but it finally occurred to me to subscribe to 'esp32_0C1C84/#' instead. Lo and behold, I can now see mos commands show up at amazon at 'esp32_0C1C84/rpc'. I can't figure out how to put a screenshot in this chat window, but I see activity when I issue things like 'mos1 ls' or 'mos1 call RPC.List'. So it seems like Amazon is getting the mos request and publishing to the proper rpc topic, but for some reason my ESP32 is not seeing any activity from its end, or maybe not even subscribing to that topic. Is there some debug level I can set to get insight into what the ESP32 might be doing?

    mookiedog
    @mookiedog
    I figured it out, and it was stupid: the original app that I used to build my app on top of is the official demo-C app. Out of the box, that app is designed to do MQTT with Amazon AWS, but it's mos.yml file does NOT include the rpc mqtt library - origin: https://github.com/mongoose-os-libs/rpc-mqtt, with predictable results: mqtt/aws works perfectly, and mqtt/rpc works not at all. Adding the library fixes it.
    It might be worth adding the rpc-mqtt library to that demo app.
    farzanDE
    @farzanDE
    Quick question: is it safe to use mgos_pwm_set in ISR context for esp32?
    pawanmlnr
    @pawanmlnr
    Feb 2 11:42:01.557] Uploading key...
    Server Error: {"error":"failed to upload gcp-esp8266_1B1F9C.priv.pem: The handle is invalid."}
    what to do
    Deomid Ryabkov
    @rojer
    @farzanDE yes
    @JonWitthoeft_twitter i think you'll need to adjust FS_ADDR, first app is always at 0x10000
    Crystik
    @Crystik
    hey everyone i know it is a stupid question.. but do you know why i cant flash my esp 32 at mongoose?
    Liviu
    @nliviu

    mgos_sys_ro_vars_get_fw_version() is no longer available in latest?

    mgos_sys_ro_vars_get_fw_version' was not declared in this scope

    It compiled earlier today...

    Deomid Ryabkov
    @rojer
    @nliviu mgos_ro_vars.h used to be transitively included via mgos_sys-config.h, but not anymore
    cesanta/mongoose-os@6d81a99
    add #include "mgos_ro_vars.h"
    Jonathan Witthoeft
    @JonWitthoeft_twitter
    @rojer I was able to shrink the APP_SLOT_SIZE and FS_SIZE to less of the half remaining (after accounting for OTA_DATA, NVS, and partition table). So there should be enough room left on the 2M flash chip for a second APP_SLOT and FS_SLOT. Should OTA work in this case? I do not see where OTA start addresses are defined, so I am assuming that it uses unallocated flash at the end. Am I right in assuming this?
    Liviu
    @nliviu
    @rojer Thank you. I saw the commit, but I missed the #include "mgos_ro_vars.h" in fw/src/mgos_sys_config.c
    LE. prometheus-metrics is affected by this change too https://github.com/mongoose-os-libs/prometheus-metrics/blob/c869dafc86cf1fe56f89c46075d26bc2f1102470/src/mgos_prometheus_metrics.c#L54
    Deomid Ryabkov
    @rojer
    @JonWitthoeft_twitter OTA uses partition names, app_0/fs_0 and app_1/fs_1
    Jonathan Witthoeft
    @JonWitthoeft_twitter
    right, I am just seeing a defined address for app_0 but not for app_1
    Deomid Ryabkov
    @rojer
    as long as partition table has these entries and they fit on flash, OTA should be working
    that's only necessary for initial flashing by the mos tool
    Jonathan Witthoeft
    @JonWitthoeft_twitter
    ok so I don't have to explicitly assign an address in flash for the second partitions?