ESP8266 Developer Zone The Official ESP8266 Forum 2015-11-11T15:19:15+08:00 https://bbs.espressif.com:443/feed.php?f=7&t=1323 2015-11-11T15:19:15+08:00 2015-11-11T15:19:15+08:00 https://bbs.espressif.com:443/viewtopic.php?t=1323&p=4533#p4533 <![CDATA[Re: task loop]]>
Sorry that we can not duplicate your problem.

Here is our test code and test bin files, please have a try.

Thanks for your interest in ESP8266 !
test_bin.zip

Statistics: Posted by ESP_Faye — Wed Nov 11, 2015 3:19 pm


]]>
2015-11-04T17:46:23+08:00 2015-11-04T17:46:23+08:00 https://bbs.espressif.com:443/viewtopic.php?t=1323&p=4450#p4450 <![CDATA[Re: task loop]]> Statistics: Posted by ali.nasr — Wed Nov 04, 2015 5:46 pm


]]>
2015-11-04T14:28:10+08:00 2015-11-04T14:28:10+08:00 https://bbs.espressif.com:443/viewtopic.php?t=1323&p=4446#p4446 <![CDATA[Re: task loop]]>
In your case, it seems some tasks in the SDK of which priority is lower than your task can not execute.

Please use ets_task and ets_post instead of system_os_task and system_os_post.

Thanks for your interest in ESP8266 !

Statistics: Posted by ESP_Faye — Wed Nov 04, 2015 2:28 pm


]]>
2015-11-03T17:27:47+08:00 2015-11-03T17:27:47+08:00 https://bbs.espressif.com:443/viewtopic.php?t=1323&p=4432#p4432 <![CDATA[Re: task loop]]> i creat the task and arm the timer and set function for that to call my task every 1ms and it works.now my loop and wifi works :D
but here i have 2 questions
1-now i am using that code in sdk 0.9.5 and my task and wifi working well but when i use exactly same code in sdk 1.3.0 or 1.4.0 esp reset every time and show this massage :
ets Jan 8 2013,rst cause:2, boot mode:(3,6)

load 0x40100000, len 1396, room 16
tail 4
chksum 0x89
load 0x3ffe8000, len 776, room 4
tail 4
chksum 0xe8
load 0x3ffe8308, len 540, room 4
tail 8
chksum 0xc0
csum 0xc0

2nd boot version : 1.4(b1)
SPI Speed : 40MHz
SPI Mode : QIO
SPI Flash Size & Map: 8Mbit(512KB+512KB)
jump to run user1 @ 1000

why it happens? and is there any problem to use sdk 0.9.5?because my cods are working well in sdk 0.9.5.should i fix that problem in sdk 1.3.0 and use this version?

2-you said :

Other ideas might be to find a "priority" of your own task that is lower than the priority of other work ... so that if there is contention in "Do you work vs do other work", the other work will win.

we have just have 3 prioruty 0/1/2 and what is your mean to find my task priority? i set my task priority to 2 .

Statistics: Posted by ali.nasr — Tue Nov 03, 2015 5:27 pm


]]>
2015-11-02T22:52:38+08:00 2015-11-02T22:52:38+08:00 https://bbs.espressif.com:443/viewtopic.php?t=1323&p=4421#p4421 <![CDATA[Re: task loop]]>
Other ideas might be to find a "priority" of your own task that is lower than the priority of other work ... so that if there is contention in "Do you work vs do other work", the other work will win.

Statistics: Posted by kolban — Mon Nov 02, 2015 10:52 pm


]]>
2015-11-01T23:04:28+08:00 2015-11-01T23:04:28+08:00 https://bbs.espressif.com:443/viewtopic.php?t=1323&p=4402#p4402 <![CDATA[task loop]]> i want to do somthing in a loop like this code.

Code:


pwm_1Task(os_event_t *events){
    os_delay_us(10000);
   pwm_motor1_adjust();
   os_delay_us(10000);
    system_os_post(pwm_1TaskPrio, 1, 1 );
};


void user_init(void)
{
    at_init();
    at_port_print("\r\nready\r\n");
    at_cmd_array_regist(&at_custom_cmd[0], 1);
       system_os_task(pwm_1Task, pwm_1TaskPrio, pwm_1TaskQueue, pwm_1TaskQueueLen);
       system_os_post(pwm_1TaskPrio, 1, 1 );
   


pwm task working well in a loop, but wifi and AT commands not working!!!!!
generally how can i use a loop in esp8266 . for example i want to read sensors data and then adjust the light or motor rpm with that date in a Infinite loop whit wifi and AT commands working.
how can i do that????!!!

Statistics: Posted by ali.nasr — Sun Nov 01, 2015 11:04 pm


]]>