Experimental Physics and
| |||||||||||||||
|
Hello fellow
tech-talkers,
Apologies for not
getting back to you earlier, many thanks for all the
smart suggestions
concerning 'arrays in scripts'....problem solved.
I now have a
problem setting up a timer in a driver, I used the functions
timer_create timer_connect timer_settime When the
interrupt occurs I get the error message...
interrupt: timerWdHandler: kill failed (timer=0x33a930, tid=0x5bba80, errno=0x16). I am pretty sure that it is the
timer/interrupt as the message occurs
at the interval I set the timer for i.e. in
tests so far once every 1 or 5
seconds.
I have trawled the internet and found this additional report.... saw anther scenario when I place the code in a driver. When I
am
using the same functions(create,connect,settime) and I saw that in the "kill fail" error message I get tid that I never had. So I made a break point on timer_create and saw that timer_create is in a task I didn't create. (On the break point I get t1 with the tid number I will get in the kill fail message). Do anyone know why after the connected function is done the task is gone instead of returning to the place he was before the connect? Anyone know the problem / fit ?
Extract from my code.....
static void
RS485TimerInterruptHandler(timer_t timer_id, int arg)
{ logMsg("TIMER id - %d arg - %d !/n", (int)(timer_id), arg, 0, 0, 0, 0); } Extract from configure
routine....
timer_t
RS485TxHoldTimer;
/* Set Up Timer */
if (timer_create(CLOCK_REALTIME, NULL, &RS485TxHoldTimer) == ERROR) printf("timer_create() - ERROR/n"); if (timer_connect(RS485TxHoldTimer, &RS485TimerInterruptHandler, 1) == ERROR) printf("timer_connect() - ERROR/n"); DelayTime.it_value.tv_sec = 1; DelayTime.it_value.tv_nsec = 0; DelayTime.it_interval.tv_sec = 1; DelayTime.it_interval.tv_nsec = 1000000; if (timer_settime(RS485TxHoldTimer, CLOCK_REALTIME, &DelayTime, NULL) == ERROR) printf("timer_settime() - ERROR/n"); Thanks Darrell
Nineham
Hytec Electronics Ltd. Tel: +44 (0) 118 975 7770 Fax: +44 (0) 118 975 7566 Web: www.hytec-electronics.co.uk ++++++++++++++++++++++++++++++++++++++++++++ This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error, please notify the sender immediately. The views expressed in the message are those of the individual author and may not necessarily represent the views of Hytec Electronics Ltd.
| ||||||||||||||
ANJ, 02 Sep 2010 |
·
Home
·
News
·
About
·
Base
·
Modules
·
Extensions
·
Distributions
·
Download
·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing · |