On Tue, 24 Jan 2012, Sebastian Kuzminsky wrote:

Date: Tue, 24 Jan 2012 13:50:19 -0700
From: Sebastian Kuzminsky <[email protected]>
Reply-To: EMC developers <[email protected]>
To: EMC developers <[email protected]>
Subject: Re: [Emc-developers] hm2 watchdog changes

On Jan 24, 2012, at 09:02 , Peter C. Wallace wrote:

On Tue, 24 Jan 2012, Sebastian Kuzminsky wrote:

That makes some sense, but I'm think there are sensible configs where
you never read and sensible configs where you never write (stepper-only
machines with no home switches, using hm2 as a logic analyser maybe,
using one hm2 card for inputs and another one for outputs, etc).  If we
get rid of the pet_watchdog() function, I think we'd have to pet in both
read() and write() to cover all cases, and that'd be wasteful.

I like read() and write() waking up the watchdog, but i think i want to
keep pet_watchdog() to do the work.

This looks like a big improvement on watchdog operation, and maybe fixes
clytles troubles.

Clytle, do you want to grab the hm2-watchdog branch from git.linuxcnc.org and 
give it a try?  Or install the deb, it's in the 'scratch-rt' component.


I do like the idea of the first read or write enabling the watchdog. This
This means its impossible to run the hardware without a watchdog
(which is almost always a good thing) It might be a little nuisance
while testing things with halrun but I would feel better if the watchdog was
always enabled (and has a short default timeout).

Is there any way to make the pet_watchdog dependent on a cookie (dog_biscuit)?

That would make it possible for the watchdog to be conditionally enabled in
HAL

Are you looking for a way to make the watchdog inactive, so you don't have to 
pet it?  How about setting the watchdog timeout to 0 in HAL?  Doing that 
doesn't currently disable the watchdog, but it'd be easy to add.  I'd have to 
move



No, I did not make myself clear, what I was asking was a way to make _petting_ the watchdog conditional so some other HAL sanity checking function can be ANDed in if desired



Another nice thing about this branch is, when you unload the driver, it unconditionally enables the watchdog and sets the timeout to 1 nanosecond, so the machine immediately safes the outputs. It used to take a full second to safe, before.

Thats a lot better!



And while we're thinking about the watchdog, the hm2 driver currently stops talking with the FPGA when the watchdog bites. I guess it would make sense to keep reading, at least… Maybe writing too, though the outputs won't make it to the pins?

Yes, I think so, you may still want to know input status/encoder position in a
watchdog_has_bitten state. Updating outputs is probably sort of a no-op since you would likely have to restart LinuxCNC to recover (or do you just stop and start again?)





--
Sebastian Kuzminsky


------------------------------------------------------------------------------
Keep Your Developer Skills Current with LearnDevNow!
The most comprehensive online learning library for Microsoft developers
is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
Metro Style Apps, more. Free future releases when you subscribe now!
http://p.sf.net/sfu/learndevnow-d2d
_______________________________________________
Emc-developers mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/emc-developers


Peter Wallace
Mesa Electronics

(\__/)
(='.'=) This is Bunny. Copy and paste bunny into your
(")_(") signature to help him gain world domination.
------------------------------------------------------------------------------
Keep Your Developer Skills Current with LearnDevNow!
The most comprehensive online learning library for Microsoft developers
is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
Metro Style Apps, more. Free future releases when you subscribe now!
http://p.sf.net/sfu/learndevnow-d2d
_______________________________________________
Emc-developers mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/emc-developers

Reply via email to