Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ProhibitedCause #2

Open
dennisbach opened this issue Mar 26, 2017 · 7 comments
Open

ProhibitedCause #2

dennisbach opened this issue Mar 26, 2017 · 7 comments

Comments

@dennisbach
Copy link

Hi Copercini,
Thank for your project. However, I programed in my board, it run failed.
Fatal exception 29. Fatal exception 28.
It means field of memory, it's protected and cannot load or store data into there.
Do you have any solution for this?
I tried to find the way store cert and key to another field of memory, but I don't know where is suitable.

Thanks

@JimmyTai
Copy link

Hi @dennisbach ,
I finally get it work. Now it can connect to AWS IoT via MQTT successfully. I only met these Exception 29 or 28 when the connecting process failed. It means that the CA, Cert, Key may be incorrect. Please give us more information to help you solved the problem.

@dennisbach
Copy link
Author

Hi @JimmyTai
First, about CA, Cert, Key, I already tested with MQTT.fx apps on PC. It ran successfully.
However, when I run on ESP8266, it printout as follow:

WiFi connected
IP address: 
192.168.1.30
Mouted file system
Heap: 36112
Success to open cert file
Cert size:862
cert Loaded
Success to open private cert file
Private key size:1191
private key Loaded
Success to open ca
ca Loaded
Heap: 25912
Connect Server Fail
Attempting MQTT connection...please start sntp first !
failed, rc=-2 try again in 5 seconds
Attempting MQTT connection...Fatal exception 9(LoadStoreAlignmentCause):
epc1=0x402250eb, epc2=0x00000000, epc3=0x00000000, excvaddr=0x01cd0215, depc=0x00000000

Exception (9):
epc1=0x402250eb epc2=0x00000000 epc3=0x00000000 excvaddr=0x01cd0215 depc=0x00000000

ctx: cont 
sp: 3fff0fd0 end: 3fff1290 offset: 01a0

>>>stack>>>
3fff1170:  00000001 3fff2a34 3fff3514 402250c0  
3fff1180:  3fff2a34 3ffe8fd4 3fff0080 40226a8b  
3fff1190:  00000000 3fff0080 3fff0270 3fff345c  
3fff11a0:  000022b3 00000000 40208fc4 00000000  
3fff11b0:  000022b3 00000000 3fff0080 40207b5e  
3fff11c0:  bd27a436 3fff0080 3fff11ee 40208b39  
3fff11d0:  000022b3 3fff0080 3ffe8fd4 40207db1  
3fff11e0:  3ffe9270 bd27a436 3ffe9270 bd27a436  
3fff11f0:  00000000 3ffeffc4 00000000 402080a5  
3fff1200:  00000009 0000001c 3ffe8dac 4020a330  
3fff1210:  00000000 3ffe8db0 00000000 3fff025c  
3fff1220:  3ffeffc4 3ffeffc4 3fff01a0 3fff025c  
3fff1230:  3ffeffc4 3ffeffc4 3fff01a0 402081fc  
3fff1240:  00000000 00000000 3fff01a0 40208a60  
3fff1250:  3fff1c2c 3ffeffc4 3fff01a0 402067cd  
3fff1260:  3ffeffc4 00000000 3fff01a0 4020686e  
3fff1270:  3fffdad0 00000000 3fff0254 40209010  
3fff1280:  feefeffe feefeffe 3fff0270 40100718  
<<<stack<<<

 ets Jan  8 2013,rst cause:4, boot mode:(3,6)

wdt reset
load 0x4010f000, len 1384, room 16 
tail 8
chksum 0x2d
csum 0x2d
v09f0c112
~ld
ÿ
Connecting to Combros_HW
scandone
f 0, scandone
state: 0 -> 2 (b0)
state: 2 -> 3 (0)
state: 3 -> 5 (10)
add 0
aid 15
cnt 

connected with Combros_HW, channel 11
dhcp client start...
.ip:192.168.1.30,mask:255.255.255.0,gw:192.168.1.1
.
WiFi connected
IP address: 
192.168.1.30
Mouted file system
Heap: 36416
Success to open cert file
Cert size:862
cert Loaded
Success to open private cert file
Private key size:1191
private key Loaded
Success to open ca
ca Loaded
Heap: 26216
Connect Server Fail
Attempting MQTT connection...please start sntp first !
failed, rc=-2 try again in 5 seconds
Attempting MQTT connection...Fatal exception 29(StoreProhibitedCause):
epc1=0x402250eb, epc2=0x00000000, epc3=0x00000000, excvaddr=0x1e01a900, depc=0x00000000

Exception (29):
epc1=0x402250eb epc2=0x00000000 epc3=0x00000000 excvaddr=0x1e01a900 depc=0x00000000

ctx: cont 
sp: 3fff0fd0 end: 3fff1290 offset: 01a0

>>>stack>>>
3fff1170:  00000001 3fff2994 3fff33d4 402250c0  
3fff1180:  3fff2994 3ffe8fd4 3fff0080 40226a8b  
3fff1190:  00000000 3fff0080 3fff0270 3fff32a4  
3fff11a0:  000022b3 00000000 40208fc4 00000000  
3fff11b0:  000022b3 00000000 3fff0080 40207b5e  
3fff11c0:  bd27a436 3fff0080 3fff11ee 40208b39  
3fff11d0:  000022b3 3fff0080 3ffe8fd4 40207db1  
3fff11e0:  3ffe9270 bd27a436 3ffe9270 bd27a436  
3fff11f0:  00000000 3ffeffc4 00000000 402080a5  
3fff1200:  00000009 0000001c 3ffe8dac 4020a330  
3fff1210:  00000000 3ffe8db0 00000000 3fff025c  
3fff1220:  3ffeffc4 3ffeffc4 3fff01a0 3fff025c  
3fff1230:  3ffeffc4 3ffeffc4 3fff01a0 402081fc  
3fff1240:  00000000 00000000 3fff01a0 40208a60  
3fff1250:  3fff2954 3ffeffc4 3fff01a0 402067cd  
3fff1260:  3ffeffc4 00000000 3fff01a0 4020686e  
3fff1270:  3fffdad0 00000000 3fff0254 40209010  
3fff1280:  feefeffe feefeffe 3fff0270 40100718  
<<<stack<<<

 ets Jan  8 2013,rst cause:4, boot mode:(3,6)

wdt reset
load 0x4010f000, len 1384, room 16 
tail 8
chksum 0x2d
csum 0x2d
v09f0c112
~ld
ÿ
Connecting to Combros_HW

Do you have any suggestion base on my printout?
Thank you so much.

@dennisbach
Copy link
Author

Hi everyone,
Do you have any solution for my problem?

Thank you so much.
Dennis

@JimmyTai
Copy link

JimmyTai commented Jun 2, 2017

Hi @dennisbach ,

I am sorry for late reply.
I already put my whole esp8266 Arduino core on my Github.
Also I create a library to help you loading the certification and private key.
This is the link: https://github.com/JimmyTai/esp8266-AWSIoT

Jimmy

@dennisbach
Copy link
Author

Hi @JimmyTai
Thank you so much. I will try and share my result later.

Regards

@JimmyTai
Copy link

JimmyTai commented Jun 3, 2017 via email

@dennisbach
Copy link
Author

Thank @JimmyTai so much. Your sharing source code ran very well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants