<p>Anyway regarding the optimization issue causing the HARDFAULT, I have been trying to find the reason for it but I can't. Initializing the variables fixes the issue but I don't know why, any ideas <a class="user-mention" data-hovercard-type="user" data-hovercard-url="/hovercards?user_id=1375137" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/aabadie">@aabadie</a>? A fix could be just initializing them all.</p>
<pre><code>    /* Read RX2 datarate */
    uint8_t dr = 0;
    pos += eeprom_read(pos, &dr, 1);
    DEBUG("[semtech-loramac] reading rx2 dr: %d\n", dr);
    semtech_loramac_set_rx2_dr(mac, dr);
</code></pre>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />You are receiving this because you are subscribed to this thread.<br />Reply to this email directly, <a href="https://github.com/RIOT-OS/RIOT/issues/11626?email_source=notifications&email_token=ABE7WYCLURKDILENFO54GJTPY6KGNA5CNFSM4HS3HL52YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODW7KIFY#issuecomment-499033111">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/ABE7WYC4Z6JTFUQRCRTEQK3PY6KGNANCNFSM4HS3HL5Q">mute the thread</a>.<img src="https://github.com/notifications/beacon/ABE7WYANHXABFWBYNSYJUITPY6KGNA5CNFSM4HS3HL52YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODW7KIFY.gif" height="1" width="1" alt="" /></p>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/RIOT-OS/RIOT/issues/11626?email_source=notifications\u0026email_token=ABE7WYCLURKDILENFO54GJTPY6KGNA5CNFSM4HS3HL52YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODW7KIFY#issuecomment-499033111",
"url": "https://github.com/RIOT-OS/RIOT/issues/11626?email_source=notifications\u0026email_token=ABE7WYCLURKDILENFO54GJTPY6KGNA5CNFSM4HS3HL52YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODW7KIFY#issuecomment-499033111",
"name": "View Issue"
},
"description": "View this Issue on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]</script>