Hi all,
Just got down to trying this again.
Thanks to Joao for spotting this patch issue - I recompiled to get our spi
pin back! :)
Following the instructions, I run the echo command to load the DT for the
MRF24J40. Had to enable the root account in Ubuntu, since simply doing
"sudo echo ..." was not enough permission-wise.
It seems to work fine, as dmesg shows:
[ 244.225700] bone-capemgr bone_capemgr.7: part_number 'BB-BONE-MRF24J40',
version 'N/A'
[ 244.225854] bone-capemgr bone_capemgr.7: slot #4: specific override
[ 244.225930] bone-capemgr bone_capemgr.7: bone: Using override eeprom
data at slot 4
[ 244.225987] bone-capemgr bone_capemgr.7: slot #4:
'Bone-MRF24J40,00A0,Signal 11 Softwa,BB-BONE-MRF24J40'
[ 244.226324] bone-capemgr bone_capemgr.7: slot #4: Requesting firmware
'cape-bone-mrf24j40-00A0.dtbo' for board-name 'Bone-MRF24J40', version
'00A0'
[ 244.226388] bone-capemgr bone_capemgr.7: slot #4: dtbo
'cape-bone-mrf24j40-00A0.dtbo' loaded; converting to live tree
[ 244.226863] bone-capemgr bone_capemgr.7: slot #4: #2 overlays
[ 244.238783] omap2_mcspi 481a0000.spi: registered master spi1
[ 244.345859] edma-dma-engine edma-dma-engine.0: allocated channel for 0:43
[ 244.346037] edma-dma-engine edma-dma-engine.0: allocated channel for 0:42
[ 244.346098] spi spi1.0: setup: speed 12000000, sample leading edge, clk
normal
[ 244.346158] spi spi1.0: setup mode 0, 8 bits/w, 20000000 Hz max --> 0
[ 244.348917] mrf24j40: probe(). IRQ: 205
[ 244.352298] mrf24j40 spi1.0: setup: speed 6000000, sample leading edge,
clk normal
... (lots of those) ....
[ 244.357443] mrf24j40 spi1.0: setup: speed 6000000, sample leading edge,
clk normal
[ 244.357934] omap2_mcspi 481a0000.spi: registered child spi1.0
[ 244.359496] bone-capemgr bone_capemgr.7: slot #4: Applied #2 overlays.
I then go on to run the setup script, but it seems the "iz add" command
fails to link the physical device to an interface.
This is the script output:
root@arm:/home/ubuntu# ./setup
++ set -e
++ ifconfig lowpan0 down
lowpan0: ERROR while getting interface flags: No such device
++ /bin/true
++ rmmod mrf24j40
++ modprobe mrf24j40
+++ iz listphy
+++ grep wpan-phy
+++ tail -n 1
+++ awk '{print $1, " " }'
++ DEV='wpan-phy1 '
++ iz add wpan-phy1
Receive failed: Netlink Error (errno = Invalid argument)
When manually reproducing the script, I can see the MRF (I think..):
root@arm:/home/ubuntu# iz listphy
wpan-phy1 IEEE 802.15.4 PHY object
page: 0 channel: n/a
channels on page 0: 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26
But iz add fails:
root@arm:/home/ubuntu# iz add wpan-phy1
Receive failed: Netlink Error (errno = Invalid argument)
Using -d to get a more detailed report, I get:
root@arm:/home/ubuntu# iz add wpan-phy0
Receive failed: Netlink Error (errno = No such device)
root@arm:/home/ubuntu# iz add wpan-phy1
Receive failed: Netlink Error (errno = Invalid argument)
root@arm:/home/ubuntu# iz -d add wpan-phy0
DBG<1>: Clearing cache 0x15218 <genl/family>...
DBG<1>: Picking up answer for cache 0x15218 <genl/family>...
DBG<1>: Added 0x16360 to cache 0x15218 <genl/family>.
DBG<1>: Added 0x162e8 to cache 0x15218 <genl/family>.
DBG<1>: Added 0x16440 to cache 0x15218 <genl/family>.
DBG<1>: Added 0x163c8 to cache 0x15218 <genl/family>.
DBG<1>: Added 0x165e0 to cache 0x15218 <genl/family>.
DBG<1>: Clearing cache 0x15218 <genl/family>...
DBG<1>: Deleted 0x16360 from cache 0x15218 <genl/family>.
DBG<1>: Deleted 0x162e8 from cache 0x15218 <genl/family>.
DBG<1>: Deleted 0x16440 from cache 0x15218 <genl/family>.
DBG<1>: Deleted 0x163c8 from cache 0x15218 <genl/family>.
DBG<1>: Deleted 0x165e0 from cache 0x15218 <genl/family>.
DBG<1>: Freeing cache 0x15218 <genl/family>...
DBG<1>: Clearing cache 0x15218 <genl/family>...
DBG<1>: Picking up answer for cache 0x15218 <genl/family>...
DBG<1>: Added 0x17410 to cache 0x15218 <genl/family>.
DBG<1>: Added 0x17398 to cache 0x15218 <genl/family>.
DBG<1>: Added 0x174f0 to cache 0x15218 <genl/family>.
DBG<1>: Added 0x17478 to cache 0x15218 <genl/family>.
DBG<1>: Added 0x17690 to cache 0x15218 <genl/family>.
DBG<1>: Clearing cache 0x15218 <genl/family>...
DBG<1>: Deleted 0x17410 from cache 0x15218 <genl/family>.
DBG<1>: Deleted 0x17398 from cache 0x15218 <genl/family>.
DBG<1>: Deleted 0x174f0 from cache 0x15218 <genl/family>.
DBG<1>: Deleted 0x17478 from cache 0x15218 <genl/family>.
DBG<1>: Deleted 0x17690 from cache 0x15218 <genl/family>.
DBG<1>: Freeing cache 0x15218 <genl/family>...
nl_send_auto_complete
nlmsg_free
Receive failed: Netlink Error (errno = No such device)
DBG<1>: Unregistered cache operations netfilter/log
DBG<1>: Unregistered cache operations netfilter/ct
DBG<1>: Unregistered cache operations fib_lookup/fib_lookup
DBG<1>: Unregistered cache operations genl/family
DBG<1>: Unregistered link info perations vlan
DBG<1>: Unregistered cache operations route/rule
DBG<1>: Unregistered cache operations route/route
DBG<1>: Unregistered cache operations route/qdisc
DBG<1>: Unregistered cache operations route/neightbl
DBG<1>: Unregistered cache operations route/neigh
DBG<1>: Unregistered cache operations route/link
DBG<1>: Unregistered cache operations route/cls
DBG<1>: Unregistered cache operations route/class
DBG<1>: Unregistered cache operations route/addr
root@arm:/home/ubuntu#
Any ideas would be welcome!
Kind regards,
Kostas
2013/3/26 João Paulo Bodanese <joao.bodan...@gmail.com>
> Hi Alan,
>
> There is a patch after March, 6th (commit 9bf23ea262), that removes the
> symbol spi1_pins_s0 from am335x-bone-common.dtsi
> The patch name is:
> 0115-am335x-bone-common-Remove-SPI-unused-pinmux-config.patch
>
> Now the command is working, and I can see the mrf24j40 print debug. One
> more step :)
>
> Thank you a lot
>
> Best regards,
> Joao Paulo
>
>
> 2013/3/25 Alan Ott <a...@signal11.us>
>
>> On 03/25/2013 04:48 AM, João Paulo Bodanese wrote:
>>
>> Hi Alan,
>>
>> I am starting this new thread to do not disturb that one from the
>> compilation error.
>>
>> I'm following the steps you told me to load the MRF24J40.
>>
>> After board power up, I am getting problem below when running the
>> command: echo BB-BONE-MRF24J40 >/sys/devices/bone_capemgr.7/slots
>>
>> [ 30.143448] bone-capemgr bone_capemgr.7: part_number
>> 'BB-BONE-MRF24J40', version 'N/A'
>> [ 30.153341] bone-capemgr bone_capemgr.7: slot #4: specific override
>> [ 30.160081] bone-capemgr bone_capemgr.7: bone: Using override eeprom
>> data at slot 4
>> [ 30.168118] bone-capemgr bone_capemgr.7: slot #4:
>> 'Bone-MRF24J40,00A0,Signal 11 Softwa,BB-BONE-MRF24J40'
>> [ 30.178582] bone-capemgr bone_capemgr.7: slot #4: Requesting firmware
>> 'cape-bone-mrf24j40-00A0.dtbo' for board-name 'Bone-MRF24J40', version
>> '00A0'
>> [ 30.196039] bone-capemgr bone_capemgr.7: slot #4: dtbo
>> 'cape-bone-mrf24j40-00A0.dtbo' loaded; converting to live tree
>> [ 30.207704] of_resolve: Could not find symbol 'spi1_pins_s0'
>> [ 30.213751] bone-capemgr bone_capemgr.7: slot #4: Failed to resolve
>> tree
>> -sh: echo: write error: Invalid argument
>>
>>
>> I double checked my patched files and they are correctly.
>>
>>
>> What version of everything are you running? Maybe something changed in
>> the .dtsi (arch/arm/boot/dts/am33x*)
>>
>> Check that and see if you can find out why spi1_pins_s0 is failing.
>>
>> Alan.
>>
>>
>>
>> Thank you again,
>>
>> Best regards,
>> Joao Paulo
>>
>>
>> --------------------------------------------------------------------------------------------------
>>
>> 2013/3/18 Alan Ott <a...@signal11.us>
>> On 03/18/2013 04:45 AM, João Paulo Bodanese wrote:
>> > I am trying to set up the demo that Alan presented at Linux Conference
>> > Europe 2012.
>> > I have already installed the 3.7-rc2 Linux kernel in the BeagleBone
>> > with all the patches that its described in his website.
>>
>> Hi João,
>>
>> At this point you're best off doing something slightly different than
>> that, which I'll describe.
>>
>> Grab the BeagleBone 3.8 kernel, which already has Tony's patches in it:
>> https://github.com/beagleboard/kernel/tree/3.8
>>
>> Apply these patches to it:
>> http://www.signal11.us/~alan/patches/patches-joao.tar.gz
>> (btw, those were sent to next-next just a minute ago)
>>
>> Also apply this one:
>> http://www.signal11.us/~alan/patches/bone-dt-cape-override.diff
>>
>> Install the linux-zigbee userspace tools from source:
>> 1. extract libnl (I'm using 3.2.7) and linux-zigbee userspace tools (use
>> the ones from git) side-by-side.
>>
>> 2. Build libnl with:
>> ./configure --prefix=$PWD/../out --host=arm-linux
>> make
>>
>> 3. Build linux-zigbee userspace tools with:
>> LDFLAGS=-L$PWD/../out/lib ./configure \
>> --prefix=$PWD/../out --host=arm-linux
>> make
>>
>> 4. Output files will be in out/ . Copy these to your BeagleBone.
>>
>> Connect your mrf24j40ma to SPI1 (CS0), and connect the INT pin to
>> GPIO1_29 (see my DT file, patch 0001).
>>
>> Once the Bone is running, load the DT for the MRF24J40:
>> echo BB-BONE-MRF24J40 >/sys/devices/bone_capemgr.7/
>>>
>>> slots
>>>
>>> Then run this setup script:
>>> http://www.signal11.us/~alan/patches/setup
>>>
>>> I'll get this stuff up on the website soon, as it's a popular question.
>>> Or if you have time (all you need is a souceforge account)....
>>>
>>> > My question is how to install the linux-zigbee userspace tools in the
>>> > BeagleBone node? Is there a recipe to install it in the Angstron?
>>>
>>> Not that I know of. Feel free to find out for sure and let us know.
>>>
>>> Alan.
>>
>>
>>
>>
>
>
> ------------------------------------------------------------------------------
> Own the Future-Intel® Level Up Game Demo Contest 2013
> Rise to greatness in Intel's independent game demo contest.
> Compete for recognition, cash, and the chance to get your game
> on Steam. $5K grand prize plus 10 genre and skill prizes.
> Submit your demo by 6/6/13. http://p.sf.net/sfu/intel_levelupd2d
> _______________________________________________
> Linux-zigbee-devel mailing list
> Linux-zigbee-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/linux-zigbee-devel
>
>
------------------------------------------------------------------------------
Precog is a next-generation analytics platform capable of advanced
analytics on semi-structured data. The platform includes APIs for building
apps and a phenomenal toolset for data science. Developers can use
our toolset for easy data analysis & visualization. Get a free account!
http://www2.precog.com/precogplatform/slashdotnewsletter
_______________________________________________
Linux-zigbee-devel mailing list
Linux-zigbee-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linux-zigbee-devel