I prefer that the first library has a constant to choose RX1/TX1 or
RX2/TX2, default is RX1/TX1. Yes, keep the same naming.

But also, there should be a 2nd library with an alike constant but
default of RX2/TX2

Do both ports use alike registers?

Matt.

On Apr 15, 8:39 am, Sebastien Lelong <[email protected]>
wrote:
> Hi guys,
> Hi guys,
>
> I have a working sample running EUSART2 module (via Peripheral Pin Select
> feature so RX2/TX2 remapped on pins of my choice, woohoo) on PIC18F27J53. As
> Matt mentioned, current serial_hardware.jal and usart_common.jal libraries
> don't support EUSART2, only the first module.
>
> How can we make progress on this ? I had suggested to use a template to
> generate 2 different sets for these, does that sound ok to you ? This would
> involves:
>
>   - serial_hardware.jal and serial_hardware2.jal (first lib remains
> unchanged for backward compatibilities)
>   - same for each "public" procedures and functions, only the second version
> will have names including "2" (eg. serial_hw2_init, serial_hw2_read, etc...)
>
> Do you see other options ?
>
> Cheers,
> Seb
>
> 2010/10/2 Sebastien Lelong <[email protected]>
>
> > Hi Matt,
>
> > There doesn't seem to be PICs with more than two (and most importantly
> > that's a finite number :)) so I would suggest to have another
> > serial_hardware2.jal library. To avoid code duplication and ease
> > maintenance, I would suggest to use a template.
>
> > This is what I did for PWM libs at the very first days of jallib. There
> > were only 5 PWM max, then appeared (or we discovered) PICs with 10 PWM, I
> > just replace 5 by 10 in my template script and voilà.
>
> > Cheers,
> > Seb
>
> > 2010/9/30 mattschinkel <[email protected]>
>
> >> I would like to use the 2nd serial port on 16f67j50 because of the
> >> port/pin location.
>
> >> I think we could either have a 2nd serial_hw library, or add a
> >> constant to the current library so the user may choose what port they
> >> wish to use.
>
> >> What do you think?
>
> >> 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.

Reply via email to