Peer to Peer setup on MKW21

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

Peer to Peer setup on MKW21

Jump to solution
1,852 Views
vmatlapudi
Contributor II

All demos apps in KSDK and Beetkit have either coordinator or end Device.

How to setup a router/Peer to peer functionality on MKW21 , which can transfer the data to Other router , whose Channel , PID and MAC address are know.

What PIB attributes i need to change to make it work like a router?

Labels (2)
1 Solution
1,410 Views
jc_pacheco
NXP Employee
NXP Employee

Hello Vijay,

As Angel commented, you can find MAC application examples on how to associate end devices to a coordinator and you can also find some peer-to-peer examples using SMAC.

If you still require to use MAC to send P2P messages between 2 devices, you must manually configure the communication parameters that the MAC is going to use (PAN Information Base - PIBs): PAN ID, Short Address, Logical Channel, RxOnWhenIdle = TRUE. Then use the MCPS-DATA.Request command to send data to a known remote host.

You can find attached a modified App file that works with "MyWirelessApp (EndDevice) " demo (Freescale Kinetis KW2xD IEEE® 802.15.4 Software - Rev 5.0.3), you just require to substitute the original "App.c" of the example project. I'd recommend to take a look into the modifications marked with "\\@P2P". There is a "DEVICE" macro that will let you configure your project as Device1 or Device2, it will let you differentiate the src and dst addresses depending on the device.

Regards,

JC

View solution in original post

4 Replies
1,410 Views
AngelC
Senior Contributor I

Hello Vijay,

It would depend in the software stack used. 802.15.4 MAC codebase would only have Cooridnator (FFD) and End devices (RFD). However, BeeStack could also have routers as selected via BeeKit’s new project wizard.  Please specify the examples you are referring to in order to help you further.

Regards,

AngelC

0 Kudos
1,410 Views
vmatlapudi
Contributor II

I am using 802.15.4 MAC from KSDK for twrkw21d256. I couldn't send data unless i associate to device of some sort.

Is there any way to enable the MCPS sap handler to transmit and receive without MLME association permit enabled. If there is any please provide some documentation on it

Thanks

0 Kudos
1,410 Views
AngelC
Senior Contributor I

Hello Vijay,

Documentation included in 802.15.for KSDK contains the description of the application examples and how to use them. You could send direct data transmission by modifying the corresponding functions and hard-code the addressing information. Default applications imply an association has been done previous to start any TX/RX sequence.

If you would like to send peer-to-peer messages without caring about device functionality (FFD or RFD) and you do not want to mess up with 802.15.4 application’s code, then I would recommend you to use SMAC stack instead.

Regards,

AngelC

0 Kudos
1,411 Views
jc_pacheco
NXP Employee
NXP Employee

Hello Vijay,

As Angel commented, you can find MAC application examples on how to associate end devices to a coordinator and you can also find some peer-to-peer examples using SMAC.

If you still require to use MAC to send P2P messages between 2 devices, you must manually configure the communication parameters that the MAC is going to use (PAN Information Base - PIBs): PAN ID, Short Address, Logical Channel, RxOnWhenIdle = TRUE. Then use the MCPS-DATA.Request command to send data to a known remote host.

You can find attached a modified App file that works with "MyWirelessApp (EndDevice) " demo (Freescale Kinetis KW2xD IEEE® 802.15.4 Software - Rev 5.0.3), you just require to substitute the original "App.c" of the example project. I'd recommend to take a look into the modifications marked with "\\@P2P". There is a "DEVICE" macro that will let you configure your project as Device1 or Device2, it will let you differentiate the src and dst addresses depending on the device.

Regards,

JC