ESP8266 Developer Zone The Official ESP8266 Forum 2015-12-01T16:00:29+08:00 https://bbs.espressif.com:443/feed.php?f=66&t=1449 2015-12-01T16:00:29+08:00 2015-12-01T16:00:29+08:00 https://bbs.espressif.com:443/viewtopic.php?t=1449&p=4846#p4846 <![CDATA[Re: Active HW-Timer and writing SPI_FLASH does not work any more]]>
Please do not add "ICACHE_FLASH_ATTR" for your timer callback (hw_pwm_timer_cb), do not put it into Flash.

If your problem is still unsolved, please provide your test code, we will help debug it.

Statistics: Posted by ESP_Faye — Tue Dec 01, 2015 4:00 pm


]]>
2015-11-30T02:36:00+08:00 2015-11-30T02:36:00+08:00 https://bbs.espressif.com:443/viewtopic.php?t=1449&p=4814#p4814 <![CDATA[Active HW-Timer and writing SPI_FLASH does not work any more]]>
i'm investigating an issue the whole day and can not fix following situation:

Witihn user_init() following hw-timer is initialized:
hw_timer_init(FRC1_SOURCE, 1);
hw_timer_set_func(hw_pwm_timer_cb);
hw_timer_arm(100);

The httpd triggers following lines at an incoming http-request:

spi_flash_erase_sector(0x3D);
spi_flash_write((0x3D) * SPI_FLASH_SEC_SIZE,(uint32 *)&data, sizeof(struct SettingsData));

I recognized that this lines are not finished. So erase is not finished. The processor restart with a fatal exception.

In case of deactivated hw_timer, writing to spi flash works without any problems.

Do you know this issue? How can i deactivate the hw_timer to write or do you what's the problem?

Thx.

Klaus

Statistics: Posted by Klaus W. — Mon Nov 30, 2015 2:36 am


]]>