Copyright ©

Mongoose OS Forum

ATTENTION! This forum has moved to:

Do not post any new messages.

Core Dump with MQTT Debugger

bblankbblank Durham, NC
edited February 12 in Mongoose OS

Hello! I just tried enabling the "stdout_topic" in my mos.yml file for debugging purposes. Unfortunately, I was met with this core dump:

Loaded core dump from last snippet in  /core
Remote debugging using
0x4008df4f in split_if_necessary (heap=0x3ffbac80, block=0x3ffce478, size=16, 
    at /opt/Espressif/esp-idf/components/heap/multi_heap.c:277
277     heap_block_t *next_block = get_next_block(block);
#0  0x4008df4f in split_if_necessary (heap=0x3ffbac80, block=0x3ffce478, 
    size=16, prev_free_block=0x3ffcb104)
    at /opt/Espressif/esp-idf/components/heap/multi_heap.c:277
#1  0x4008e256 in multi_heap_malloc_impl (heap=0x3ffbac80, size=16)
    at /opt/Espressif/esp-idf/components/heap/multi_heap.c:452
#2  0x4008193b in heap_caps_malloc (size=16, caps=6144)
    at /opt/Espressif/esp-idf/components/heap/heap_caps.c:110
#3  0x4008199f in heap_caps_malloc_default (size=16)
    at /opt/Espressif/esp-idf/components/heap/heap_caps.c:153
#4  0x40081e28 in _malloc_r (r=0x3ffbf0d0, size=16)
    at /opt/Espressif/esp-idf/components/newlib/syscalls.c:37
#5  0x4000beb2 in ?? ()
#6  0x400dc3a7 in _dtoa_r (ptr=0x3ffbf0d0, _d=1549934240.0456319, mode=3, 
    ndigits=3, decpt=decpt@entry=0x3ffbe644, sign=sign@entry=0x3ffbe640, 
    rve=rve@entry=0x3ffbe630) at ../../../.././newlib/libc/stdlib/dtoa.c:238
#7  0x400d40e0 in cvt (buf=0x3f40b2cf " %.3lf %d|%.*s", 
    length=<synthetic pointer>, ch=102, decpt=0x3ffbe644, 
    sign=<synthetic pointer>, flags=272, ndigits=3, value=1549934240.0456319, 
    data=<optimized out>) at ../../../.././newlib/libc/stdio/vfprintf.c:1878
#8  _svfprintf_r (data=<optimized out>, fp=<optimized out>, 
    fmt0=<optimized out>, ap=...)
    at ../../../.././newlib/libc/stdio/vfprintf.c:1317
#9  0x4014e479 in _vsnprintf_r (ptr=0x3ffbf0d0, str=<optimized out>, 
    size=256, fmt=0x3f40b2ca "%s %u %.3lf %d|%.*s", ap=...)
    at ../../../.././newlib/libc/stdio/vsnprintf.c:72
#10 0x4014e4b5 in vsnprintf (
    str=0x3ffbe8f0 "840D8E38A204 0", '\245' <repeats 186 times>..., size=256, 
    fmt=0x3f40b2ca "%s %u %.3lf %d|%.*s", ap=...)
    at ../../../.././newlib/libc/stdio/vsnprintf.c:41
#11 0x400eccf5 in mg_avprintf (buf=0x3ffbe880, size=256, 
    fmt=0x3f40b2ca "%s %u %.3lf %d|%.*s", ap=...) at common/str_util.c:390
#12 0x400ecd94 in mg_asprintf (buf=0x3ffbe880, size=256, 
    fmt=0x3f40b2ca "%s %u %.3lf %d|%.*s") at common/str_util.c:379
#13 0x400fca41 in s_debug_write_cb (ev=<optimized out>, ev_data=0x3ffbe9f0, 
    userdata=<optimized out>)
    at /Users/baileyblankenship/Documents/Workspace/Embedded/Resources/Mongoose/mos-libs/mqtt/src/mgos_mqtt.c:267
#14 0x400e29cc in mgos_event_trigger (ev=1297044225, ev_data=0x3ffbe9f0)
    at /mongoose-os/fw/src/mgos_event.c:128
#15 0x400e1cb7 in mgos_debug_write (fd=1, data=0x3ffc1030, len=37)
    at /mongoose-os/fw/src/mgos_debug.c:106
#16 0x400e3dcc in debug_write (fd=1, data=0x3ffc1030, size=37)
    at /mongoose-os/fw/platforms/esp32/src/esp32_debug.c:62
#17 0x400e17ac in esp_vfs_write (r=<optimized out>, fd=4, data=0x3ffc1030, 
    size=37) at /opt/Espressif/esp-idf/components/vfs/vfs.c:430
#18 0x4000bd86 in ?? ()
#19 0x40001180 in ?? ()
#20 0x40059301 in ?? ()
#21 0x4005937d in ?? ()
#22 0x40058bc2 in ?? ()
#23 0x400d691c in __sprint_r (ptr=0x3ffbf0d0, fp=0x3ffae910, uio=0x3ffbed94)
    at ../../../.././newlib/libc/stdio/vfprintf.c:437
#24 0x400dc105 in _vfprintf_r (data=<optimized out>, fp=<optimized out>, 
    fmt0=<optimized out>, ap=...)
    at ../../../.././newlib/libc/stdio/vfprintf.c:1782
#25 0x400d2ba4 in printf (
    fmt=0x3f418659 "dhcps: send_nak>>udp_sendto result %x\n")
    at ../../../.././newlib/libc/stdio/printf.c:58
#26 0x40145374 in send_nak (len=<optimized out>, m=<optimized out>)
    at /opt/Espressif/esp-idf/components/lwip/apps/dhcpserver/dhcpserver.c:598
#27 handle_dhcp (arg=<optimized out>, pcb=<optimized out>, p=0x3ffbe128, 
    addr=<optimized out>, port=<optimized out>)
    at /opt/Espressif/esp-idf/components/lwip/apps/dhcpserver/dhcpserver.c:1038
#28 0x4013ca32 in udp_input (p=0x3ffbe128, inp=<optimized out>)
    at /opt/Espressif/esp-idf/components/lwip/lwip/src/core/udp.c:401
#29 0x40140a9c in ip4_input (p=0x3ffbe128, inp=0x3ffbb6b0)
    at /opt/Espressif/esp-idf/components/lwip/lwip/src/core/ipv4/ip4.c:740
#30 0x401446d1 in ethernet_input (p=0x3ffbe128, netif=0x3ffbb6b0)
    at /opt/Espressif/esp-idf/components/lwip/lwip/src/netif/ethernet.c:184
#31 0x4013983c in tcpip_thread (arg=<optimized out>)
    at /opt/Espressif/esp-idf/components/lwip/lwip/src/api/tcpip.c:135

Any thoughts on this? Note: this also happens when I enable the file logger library.

A portion of my mos.yml file is below:

  - ["debug.level", 2]

  - ["mqtt.enable", true]

  - ["", "????????????"]
  - ["aws.thing_name", "????????????"]

  # I2C Configuration
  - ["i2c.enable", true]
  - ["i2c.unit_no", "i", 0, {title: "Which hardware unit ot use, 0 or 1"}]
  - ["i2c.sda_gpio", "i", 32, {title: "GPIO to use for SDA"}]
  - ["i2c.scl_gpio", "i", 33, {title: "GPIO to use for SCL"}]
  - ["i2c.freq", 50000]

  # File Logger - causes core dumps
  #- ["file_logger.enable", true]

  # OTA Settings
  - ["shadow.autocommit", true]

  # Debug Settings
  - ["debug.stdout_topic", "debug/????????????"]


  • mamuespmamuesp Germany/Northern coast

    Is there enough memory space? And what device are you using?

Sign In or Register to comment.