Hi,

You're right: alias is a way to create a generic device.

So something like (not checked):

alias debug_stream is serial_hw_data

const enable_debug = 1

procedure debug_byte_dec(byte in level, byte in data) is



end procedure


2010/9/7 mattschinkel <[email protected]>:
>> If you create a debug library, it should contain all the functions
>> from print.jal.
>
> Yes, it would actually just be an if statement with a bunch of aliases
>
>> And I would recoment to add a debug
>> number, so you can enable/disable groups of statements.
>
> I was thinking the same thing. There may be more then one debug lib in
> this case
>
> I could instead make a bogus pseudo variable instead like this, but
> that would require processing power if debugging is off.
>
> procedure debug_lvl1'put(byte in data) is
>   pragma inline
> end procedure
>
> print_string(debug_lvl1, icmp_str1)
>
> Matt.
>
> --
> You received this message because you are subscribed to the Google Groups 
> "jallib" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to 
> [email protected].
> For more options, visit this group at 
> http://groups.google.com/group/jallib?hl=en.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"jallib" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/jallib?hl=en.

Reply via email to