From: urefowei on
thanks..

checking
From: urefowei on
>I think you are making this more complicated than it needs to be.
>I'm not sure why you are having a pin count problem, the 18F4550
>has a boat load of pins.
>
>You dont need an interrupt for the 3421 GPX pin unless you
>configure it for INT or SOF output - which you probably dont need in
>this app. There is no reason to make GPX the interrupt pin -
>UNLESS you are trying to do something with the other GPIO pins and
>need interrupt status on them. In either case just tie the INT or
>GPX pin to a PIC INTx pin and configure the PIC for rising or falling
>edge as needed. All the other GPX functions are just operational
>status. Tie the GPX to a PIC (configured) input pin and monitor the
>pin in your firmware loop.
>
>You do not need to use an external transceiver for the PIC device
>USB side. Use the internal transceiver and either the internal
>voltage regulator or the 3.3V you supply to the MAX. If you use
>the internal regulator remember to tie VSUB to ground with a 220nF
>cap. The PIC USB core has it's own set of interrupts. Your ISR
>can easily determine which USB side is knocking on the door.
>
>The 4550 has a MSSP that will do SPI - see section 19 of the
>18F4550 data sheet. Configure the MAX for full duplex mode.
>MasterInputSlaveOutput (MISO) pin goes to the PIC SDI pin.
>Tie the 4550 /SS pin to the 3421 /SS pin. Are you trying to
>use more than 1 SPI slave device, eeprom or something else?
>
>You can use the same 12Mhz clock source for the MAX and the
>PIC. Use the PIC PLL block with a divide by 3. If you have
>a 18LF and NOT using VDD=5V watch your core clock speed.
>See the chart back in the electrical spec section.
>
>
>--
>Joe Chisolm
>Marble Falls, TX
>
>



please look at this if we are connecting these pins right

MAX3421 ---->>>> PIC18F4550
pin13(SCLK) ---->>>> pin34(SCK)
pin16(MOSI) ---->>>> pin26(SDO)
pin14(SS) ---->>>> pin36(RB3)
pin15(MISO) ---->>>> pin33(SDI)
pin18(INT) ---->>>> pin35(INT2)
pin17(GPX) ---->>>> pin37(KB10)

are we doing this right??
we are implementing an interrupt-on-change for GPX. Alternatively, we want
to....

pin17(GPX) ---->>>> pin33(INT0)
this means that we are connecting 2 pins [pin15(MISO) and pin17(GPX)] with
different functions at pin33(SDI and INT0)

which is more preferable??

i do appreciate your replies sir.
From: Joe Chisolm on
On Sat, 20 Dec 2008 19:21:32 -0600, urefowei wrote:
[snip]
>
>
> please look at this if we are connecting these pins right
>
> MAX3421 ---->>>> PIC18F4550
> pin13(SCLK) ---->>>> pin34(SCK)
> pin16(MOSI) ---->>>> pin26(SDO)
> pin14(SS) ---->>>> pin36(RB3)
> pin15(MISO) ---->>>> pin33(SDI)
> pin18(INT) ---->>>> pin35(INT2)
> pin17(GPX) ---->>>> pin37(KB10)
>
> are we doing this right??


I was wrong on the /SS pin. I was writing this from memory. You may need
to drive /SS from the PIC -> 3421 depending on SPI configuration. If
the 3421 is the only thing on the SPI bus then I ask you, why would you
need to drive slave select from the PIC if it's the only slave on the bus?

The connections seem ok. Try it and see what happens.

> we are implementing an interrupt-on-change for GPX. Alternatively, we
> want to....
>
> pin17(GPX) ---->>>> pin33(INT0)
> this means that we are connecting 2 pins [pin15(MISO) and pin17(GPX)]
> with different functions at pin33(SDI and INT0)
>
> which is more preferable??
>
> i do appreciate your replies sir.

Check the MSSP/SPI section in the PIC data sheet. For
shared pins the functions change when you enable different
modules. You will know the answer to the above question.

--
Joe Chisolm
Marble Falls, TX