[Asterisk-Users] after hours - is this logic ok ?

Lance Arbuckle asterisk at arbuckle.org
Thu Jan 1 12:46:26 MST 2004


Tilghman Lesher wrote:
> 
> On Thursday 01 January 2004 12:45, Lance Arbuckle wrote:

> > So, here's another question...  How does someone with no programming
> > experience, effectively learn the proper way to do things in Asterisk
> > ?
> 
> Trial and error is especially effective.  This is how I learned.  In
> addition, I read the source regularly, which is not nearly as daunting
> as it may seem, when taken in small doses.  Don't try to understand
> everything at once, but take a look at a small application, for example,
> SayUnixTime and trace back its function calls elsewhere into the code,
> into say.c and into stdtime/localtime.c, if you want to go that far.
> "grep -r some_function_name /usr/src/asterisk" will help you do the
> trace through code.  When somebody asks me about some functionality,
> if I don't know, the first thing I do is to go look in the source and
> see if I can figure it out.
> 
> For the variables, see the README.variables in the root directory of the
> Asterisk source.  The example I quoted above uses both variable
> interpolation ${} as well as expression evaluation $[], although the
> expression is the most simple.  You can also do comparisons in there:
> $[${var} > 3] or $[${var} = "oink"].
> 

well, I must admit I don't even attemp to read the source as I thought
it would be a waste of time since I don't know the language.  I see from
the header at the top of sayunixtime.c you know a little about that app
:)  Me thinks I need to go take an Intro to C class....

-- 
  .~.    
  /V\    Lance C. Arbuckle
 // \\   
/(   )\  
 ^'~'^



More information about the asterisk-users mailing list