PAN4555 (MC13213) Evaluation

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

PAN4555 (MC13213) Evaluation

6,840 Views
snickels
Contributor I
I've been struggling with evaluation of the Panasonic PAN4555 module (contains the Freescale MC13213).
 
Here's my setup:
 
(1) 13192-EVB programmed with the wireless UART demo code (when my 13192SARD is programmed with the same code I get data transfer between the two).
 
(1) PAN4555-ETU w/ hand soldered wires to 6-pin BDM header, 3.0V bench power supply - I used BeeKit to generate the wireless UART demo code for the MC13213SRB (no bootloader) and then used CodeWarrior to do the import, as instructed in the documentation.  Then I went into the /drivers/MC13213XSRB.c file and changed the write for the 0x07 register from 0x4C00 to 0x5C00 so that it uses the internal antenna switch.  I used the PE Multilink to program and debug the code.  (I could describe exactly what I see, but for now I just want to see if I'm on the right track rather than debugging a situation while being on the wrong track).
 
After many hours of searching this forum and reading the application notes it seems like the BeeKit is great (and I use that term loosely) if you are working with the Freescale development boards.  I believe it assumes that the bootloader + the NVRAM settings are already on your hardware (OK, if you are truly using the MC13213SRB, but the documentation gives very little support for migrating to your own hardware).  I'm not sure if I really need the NVRAM settings - I know you need them for 802.14.5, but perhaps not for SMAC.
 
So here's my question.  First, am I on the right track?  Second, do I need to "bring in" the NVRAM code? 
 
 
Please note: I am using the SMAC codebase, not the 802.14.5 and not the BeeStack, so be careful what you recommed since the code is significantly different in how registers are written and what #define's are used.
 
 
BTW: the full datasheet for the PAN4555 isn't exactly easy to find, so for anyone who runs across this message and has been looking for more than just the two-pager, go to http://www.panasonic.com/industrial/components/modules/pan4555.htm and look through the links at the bottom of the page.
 
 
Labels (1)
0 Kudos
Reply
13 Replies

1,937 Views
snickels
Contributor I
I've never used the PAN802154 so I'm not sure I'd be much help.  You may want to start a new discussion thread since it would more be more likely viewed by others.  I did take a quick look at the module on the Panasonic web site.  First off, the block diagram shows both Tx and Rx antennas, which is different from the PAN4555, so you do not want to do anything that I eluded to in my posting.  It seemed like most of your concern is with the SCI port.  From the quick glance I took I couldn't tell which SCI channel they are using.  I can see that they are routing it to an RS232 xcvr and out to a header.  I trust that you have reviewed the application note document and sample programs on their web site.
0 Kudos
Reply

1,937 Views
Marquinhjo
Contributor I
I did some tests and finally I know that the SCI port is number 2, it "works" but with a lot of trash..... is there a special considetration to do
 
Regards.
 
 
0 Kudos
Reply

1,937 Views
Marquinhjo
Contributor I
Hi Snickels:
 
At the PAN802.... the SCI is at PIN C6 but when I build the project with the beekit exactly following your instruccions; I am not sure that the SCI is still at the same pins because it doesn´t work, I tried with E0 and E1 with no response. Do you have any tip for this???
 
Thanks again
0 Kudos
Reply

1,937 Views
snickels
Contributor I
Finally figured it out.  The SMAC assumes that you will use the 16MHz clock as the reference clock for the MCU portion of the chip.  In the 1321xNCB, SRB, SED (and now in the new IPB, UCB, and ICB reference designs) they all have CLK0 tied to EXTAL.  But in the PAN4555 these two pins are NOT tied together.  So, in order to run the SMAC you have to wire CLK0 to EXTAL.
 
It does actually mention this in the PAN4555 full datasheet as Note 3 after the table in section 6.  But I didn't really understand what it meant until I studied the MC13213 documentation even harder.  I had also made the wrong assumption that the PAN4555 was wired just like the reference design boards.
 
0 Kudos
Reply

1,937 Views
darin
Contributor I
Hi, I'm also working with the PAN4555 kit for about a few months now and I've been struggling with every step of programming.  So far I've figure out how to program the device locally with some switches and leds but I can't figure out how to use the wireless interface to talk with another end device.  I'm new to MCU programming and I know I want to use SMAC but the gazillion lines and files generated from Beekit don't help.  Especially since everything I do has to be modified from the NCB model. 

Is there a decent reference, guide, or tutorial out there based on the PAN4555 that can step through in developing a super simple transmitting program across a wireless connection with out all the extra convoluted code?

Any pointers would be appreciated.
0 Kudos
Reply

1,937 Views
snickels
Contributor I
I could see how the change in clock source could "upset" the BDM; however, the same code is used in the MC13213XNCB and SRB.  When I tried those boards out (as a loaner from the local Avnet reps) the whole application (SMAC-wireless uart) worked without any problems.  It got past the UseExternalClock() function without stopping the BDM.  Plus, kind-a doubt the writer of the SMAC would puposefully put in instructions that cause the BDM to quit working.
 
So anyway, I commented out the call to that function and just tried running the code.  Low and behold, I can can get the PAN4555 to send bytes back and forth through the radio connection.  I had to change my PC's serial terminal program to 19200 baud because my PAN4555 is running off the internal clock, which is 8MHz (it really should be running 16MHz with the external crystal that is turned on using UseExternalClock()).
 
OK, so radio communication is working, but that doesn't explain why I can't use the 16MHz crystal.  For reliable radio communication the crystal must be used.  Panasonic doesn't give out the schematic for the PAN4555, but from what I can tell, it is very close to the MC13213SED reference design.  I've looked at the MC13213 reference manual's section on the clock reference and did not see anything obvious.
 
I have been working with the PAN4555-ETU (module mounted on a DIP carrier board).  Last night I took a plain PAN4555 module and carefully soldered wires to the appropriate pads.  This module does the same thing, the BDM stops when the clock source is switched.  So the problem is consistent between two hardware pieces.  Is there something different with the PAN4555 vs the MC13213SED???
 
Give me a shout if you have succussfully used the PAN4555 with the SMAC, or if you have an idea why the 16MHz crystal clock source is having problems.
0 Kudos
Reply

1,937 Views
snickels
Contributor I
Yes, I hopes that helps anyone using BeeStack.  Thanks "phlp".
 
But, back to the SMAC,...
 
I was trying it through the CodeWarrior debugger last night and the debugger kept dying in main() at the call to UseExternalClock().  I restart and manually step into that function and the BDM looses communication when the ICGC1 is written.  The full datasheet shows a 16MHz crystal, so it shouldn't have a problem.  Anyone else seeing this?
0 Kudos
Reply

1,937 Views
bigmac
Specialist III
Hello,


snickels wrote:
I was trying it through the CodeWarrior debugger last night and the debugger kept dying in main() at the call to UseExternalClock().  I restart and manually step into that function and the BDM looses communication when the ICGC1 is written.  The full datasheet shows a 16MHz crystal, so it shouldn't have a problem.  Anyone else seeing this?


The issue here would appear to be that, after a POR, the MCU will default to the internal clock, and the bus frequency will be quite different from the final bus frequency using the crystal.  The write to the ICGC1 register will change the bus frequency at this point, resulting in the BDM losing communications whilst single stepping.
 
Regards,
Mac
 


Message Edited by bigmac on 2008-02-23 02:59 PM
0 Kudos
Reply

1,937 Views
phlp
Contributor III
Hi snickels,
 
At the bottom of the page of url in your message is a link to a beestack patch. Download and install it. A new PAN4555 codebase will be installed. Unfortunately it is based upon the Beestack codebase and not SMAC. However, I've used it successfully with a PAN4555 module.
 
Hope it helps.
0 Kudos
Reply

1,937 Views
paramasivan
Contributor I
hi,
when i am creating a new project in codewarrior 6.2 version i can simulate my project using fullchipsimulation mode.
But when i am trying to export the freescale BEEKIT example files(wireless uart demo) in the codewarrior 6.2 the fullchip simulation option not shown in the dialog box.so i cant simulate the example files.
please  help me  how to  and simulate the code. 
 
presently i bought EK2500 evaluation kit for synapse testing .it has PAN4555 with MC13213.shall i check my BEESTACK code in it.do you know any example codes for  EK2500 evaluation kit for beestack testing.Kindly help me.
 
 
regards,
s.paramasivan. 
0 Kudos
Reply

1,937 Views
Marquinhjo
Contributor I

Hi Paramasivan.

 

In my own experience I've never used fullchip simulation because it it important to test the code with the hardware.

 

However, there is a section in this example (Wireless UART) where the external clock is used (PIN 13 & 14), this will cause the lose of the control of your application, just consider it and do not get surprised.

 

In the PAN4555 there are some pins but the munber 13 and 14 MUST be attached together.

 

Check also the recomendations placed by snickels referring to the change of some parameters in the code.

 

Anyway if you need more help this is the better way to get responses.

 

Marquinho

 

 

 

0 Kudos
Reply

1,937 Views
paramasivan
Contributor I

hi,

i am going to use PAN4555 freescale zigbee beestack in my aspplication.i had downloaded BEEKIT & CODEWARRIOR6.2 softwares from freescale site.
when i am  using the BEEKIT software i selected  star network templates and give the pan & mac ids and finally export that project.If i am importing the .XML file in the codewarrior it shows lot of supporting c,header & library files for initilize the beestack.Now what my doubt means, from where i will start my code for simply transmit the data FROM CORDINATOR and receive the same data in the END DEVICE.

1)What are the steps i will do in the software??
2)Already beestacks are all initalzed in that code.Any need to check all that codes??it has more than 20 files for support.

i want a simple example code for transmitting and receiving data htrough STAR or MESH network in my first step at beestack zigbee development..

kindly anyone give a sugesstion how start the applications in beestack...... 

regards,
S.PARAMASIVAN
0 Kudos
Reply

1,937 Views
Marquinhjo
Contributor I

Follow this.....

 

Access Freescale BeeKit

File-New project

 

In SMAC select.................. Wireless UART(fill options at the bottom of this window)  (Ok)

 

 

 At the wizard press (Target Board MC1321x-NCB (Next)

 At Select the hardware Select MC13192-SARD (Finish)

 

At the Top Menu....

 

  Solution-Export Solution (ok at the new window)

 

Quit BeeKit

 

Go to Code warrior

 

File-Import Project....  Select the project you did before..... and give a name to your CW project

 

At this point you did the CW project.....

 

Click at :smileyplus: on Wireless UART folder - sources ..... "wireless-uart.c" this is the code....

 

Open the  MC1321XSRB.c located at Shared-Drivers folders

 

Change RadioInit to.....

 

void RadioInit(void) {
    SPIDrvWrite(0x11,0x80FF);   /* Eliminate Unlock Conditions due to L01 */
    SPIDrvWrite(0x1B,0x8000);   /* Disable TC1. */
    SPIDrvWrite(0x1D,0x8000);   /* Disable TC2. */
    SPIDrvWrite(0x1F,0x8000);   /* Disable TC3. */
    SPIDrvWrite(0x21,0x8000);   /* Disable TC4. */
    SPIDrvWrite(0x07,0x5C00);   /* Enable CLKo in Doze */
    SPIDrvWrite(0x0C,0x0381);   /* IRQ pull-up disable. Vdd for RF switch is set*/
    SPIDrvWrite(0x04,0xA08D);   /* New cal value */
    SPIDrvWrite(0x05,0x8351);   /* Acoma, TC1, Doze, ATTN masks, LO1, CRC */
    SPIDrvWrite(0x06,0x4720);   /* CCA, TX, RX, energy detect */
    SPIDrvWrite(0x0B,0xC0FE);   /* IRQ pull-up disable. Vdd for RF switch is set*/
    (void)SPIDrvRead(0x25);
    /* Advance the state variable to Idle */
    gu8RTxMode = IDLE_MODE;
}

 

 

 

At this point you should program two devices with the same code this process will enable the radio, but the serial port must be attached to some circuitery to get RS232 levels, if you do not have this circuitery you would not be able to send information between this two devices.

 

Regards

 

 

Marco
0 Kudos
Reply