Re: [beagleboard] GPIO problems on ubuntu 16.04

2016-07-24 Thread denis . fisseler
I'm using ubuntu, because it's the recommended platform for ros. Apart from 
that, I managed to mostly solve the ubuntu 16.04 issues in the meantime. I 
noticed, that almost all of my startup error messages were related to pins 
P8_03, P8_04, P8_05 and P8_18. So I made a modified version of 
univ-all-00A0.dts with all entries regarding those pins removed. I also 
took out the can related entries, to not interfere with my separate can 
dts. After compiling those dts files and loading the modified univ-all cape 
in uEnv.txt I'm finally able to access all required GPIOs.
The problem of configuring and activating the GPIOs and setting up the can 
bus automatically at boot time required a different approach. I am using an 
init.d script to do these things at startup. At first, it did only work, if 
I added a dependency to the script to start after $network. Otherwise the 
configuration is done too early in the bootup process and has no effect at 
all. This however required a working network cable to be plugged in at 
startup, which is not possible, as the network router on my robot can only 
be powered on using some GPIO signals. As I was unable to figure out a way, 
to make $network not dependent of link-up on the lan port, I removed the 
dependency from the script and added a 10 second sleep call at the 
beginning of the script(determined the delay by examining the timings in 
syslog). This way the GPIOs and can bus are automatically set up after the 
required modules got loaded and powers on my router, without having to wait 
for link-up. It is not a beautiful solution, but it seems to be reliable.

Am Mittwoch, 20. Juli 2016 03:11:51 UTC+2 schrieb William Hermans:
>
> denis,
>
> But the point I'm trying to make here is that Ubuntu mate is new, so give 
> it some time, and these issues which may, or may not be kernel related. To 
> settle down. So if you have to use Ubuntu, in your shoes. I'd stick with 
> 14.04. But honestly I'd never use Ubuntu on this specific hardware anyhow . 
> . . an odroid XU4 sure, but not a beaglebone.
>

-- 
For more options, visit http://beagleboard.org/discuss
--- 
You received this message because you are subscribed to the Google Groups 
"BeagleBoard" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to beagleboard+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/beagleboard/15df0d7d-cfba-4db1-bc96-cb13953b97ee%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [beagleboard] GPIO problems on ubuntu 16.04

2016-07-19 Thread John Syne
One more thing, the Linux kernel used on RaspberryPi3, etc are still running in 
32bit mode:

https://www.linux.com/news/raspberry-pi-3-still-essentially-32-bit-sbc-now 


Regards,
John




> On Jul 19, 2016, at 6:11 PM, William Hermans  wrote:
> 
> denis,
> 
> For what it's worth. Ubuntu mate does not seem very . . ."complete" on any 
> ARM platform right now. For instance, the Odroid XU4 which has 4 cores A15's 
> and 4 cores A7 uses an armv7 kernel( 32 bit ). Where the A15 cores are 
> actually 64bit cores I believe.  Same for the RaspberryPI 3 , and odroid C2 
> which both use A53 processors that are also 64bit cores . . . and this is not 
> only for Ubuntu. It for all Linux's as far as I can tell.
> 
> But the point I'm trying to make here is that Ubuntu mate is new, so give it 
> some time, and these issues which may, or may not be kernel related. To 
> settle down. So if you have to use Ubuntu, in your shoes. I'd stick with 
> 14.04. But honestly I'd never use Ubuntu on this specific hardware anyhow . . 
> . an odroid XU4 sure, but not a beaglebone.
> 
> On Tue, Jul 19, 2016 at 10:16 AM,  > wrote:
> Ok, can't be helped then. :-) Thank you for spending some time on my problem.
> 
> Am Dienstag, 19. Juli 2016 16:30:26 UTC+2 schrieb William Hermans:
> Do you happen to know a download location for a working ubuntu 16.04 
> beaglebone image with a 4.4.x kernel?
> 
> No I do not. Ubuntu on the beaglebones is not my thing . . .
> 
> On Tue, Jul 19, 2016 at 2:31 AM, > wrote:
> Hello William,
> that doesn't sound very encouraging. I just re-downloaded the image from 
> http://elinux.org/BeagleBoardUbuntu#Ubuntu_.2816.04.29 
>  , flashed it on an 
> empty uSD card loaded am335x-boneblack-emmc-
> overlay.dtb and univ-all cape to ensure it wasn't me who broke the image 
> during install. Unfortunately the kernel log showed the same errors. Then I 
> tried to fake the missing directories by creating symlinks to the existing 
> ones, but it didn't work, because symlinks can not be created in sysfs 
> directories.
> Do you happen to know a download location for a working ubuntu 16.04 
> beaglebone image with a 4.4.x kernel?
> 
> 
> Am Montag, 18. Juli 2016 19:00:52 UTC+2 schrieb William Hermans:
> Hi denis,
> 
> I do not know what to say. That Linux image you have seems to be incomplete 
> or somehow broken.
> 
> On Mon, Jul 18, 2016 at 12:56 AM, > wrote:
> Hello William,
> thank you very much for your answer. I just experimented with your solution. 
> Loading the univ-all cape and the setting P9_15 for gpio48 to hi and P8_20 
> for gpio63 to high I was able to activate and deactivate both pins. If I now 
> just load the univ-all cape at startup both GPIOs seem to behave as required 
> and are powered on by my normal startup code. Unfortunately the kernel log 
> now shows a lot of errors after startup.
> 
> [0.00] Booting Linux on physical CPU 0x0
> [0.00] Initializing cgroup subsys cpuset
> [0.00] Initializing cgroup subsys cpu
> [0.00] Initializing cgroup subsys cpuacct
> [0.00] Linux version 4.4.14-bone11 (root@a4-imx6q-wandboard-2gb) (gcc 
> version 5.3.1 20160413 (Ubuntu/Linaro 5.3.1-14ubuntu2.1) ) #1 Sun Jul 3 
> 07:00:48 UTC 2016
> [0.00] CPU: ARMv7 Processor [413fc082] revision 2 (ARMv7), cr=50c5387d
> [0.00] CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing 
> instruction cache
> [0.00] Machine model: TI AM335x BeagleBone Black
> [0.00] cma: Reserved 24 MiB at 0x9e80
> [0.00] Memory policy: Data cache writeback
> [0.00] On node 0 totalpages: 131072
> [0.00] free_area_init_node: node 0, pgdat c0b62d5c, node_mem_map 
> de36d000
> [0.00]   Normal zone: 1152 pages used for memmap
> [0.00]   Normal zone: 0 pages reserved
> [0.00]   Normal zone: 131072 pages, LIFO batch:31
> [0.00] CPU: All CPU(s) started in SVC mode.
> [0.00] AM335X ES2.1 (sgx neon )
> [0.00] pcpu-alloc: s0 r0 d32768 u32768 alloc=1*32768
> [0.00] pcpu-alloc: [0] 0 
> [0.00] Built 1 zonelists in Zone order, mobility grouping on.  Total 
> pages: 129920
> [0.00] Kernel command line: console=ttyO0,115200n8 
> bone_capemgr.enable_partno=univ-all 
> root=UUID=f71c90d7-7127-4727-9b6c-ec6d687c6682 ro rootfstype=ext4 rootwait 
> coherent_pool=1M quiet
> [0.00] PID hash table entries: 2048 (order: 1, 8192 bytes)
> [0.00] Dentry cache hash table entries: 65536 (order: 6, 262144 bytes)
> [0.00] Inode-cache hash table entries: 32768 (order: 5, 131072 bytes)
> [0.00] Memory: 477068K/524288K available (6817K kernel code, 865K 
> rwdata, 3604K rodata, 456K init, 858K bss, 22644K reserved, 24576K 
> cma-reserved, 0K highmem)
> [0.00] Virtual kernel memory layout:
>

Re: [beagleboard] GPIO problems on ubuntu 16.04

2016-07-19 Thread John Syne
I don’t know why William doesn’t take a quick look on the ARM website before 
making statements like this. CortexA15 is a 32bit processor. CortexA53 is a low 
power 64bit processor. 

Regards,
John




> On Jul 19, 2016, at 6:11 PM, William Hermans  wrote:
> 
> denis,
> 
> For what it's worth. Ubuntu mate does not seem very . . ."complete" on any 
> ARM platform right now. For instance, the Odroid XU4 which has 4 cores A15's 
> and 4 cores A7 uses an armv7 kernel( 32 bit ). Where the A15 cores are 
> actually 64bit cores I believe.  Same for the RaspberryPI 3 , and odroid C2 
> which both use A53 processors that are also 64bit cores . . . and this is not 
> only for Ubuntu. It for all Linux's as far as I can tell.
> 
> But the point I'm trying to make here is that Ubuntu mate is new, so give it 
> some time, and these issues which may, or may not be kernel related. To 
> settle down. So if you have to use Ubuntu, in your shoes. I'd stick with 
> 14.04. But honestly I'd never use Ubuntu on this specific hardware anyhow . . 
> . an odroid XU4 sure, but not a beaglebone.
> 
> On Tue, Jul 19, 2016 at 10:16 AM,  > wrote:
> Ok, can't be helped then. :-) Thank you for spending some time on my problem.
> 
> Am Dienstag, 19. Juli 2016 16:30:26 UTC+2 schrieb William Hermans:
> Do you happen to know a download location for a working ubuntu 16.04 
> beaglebone image with a 4.4.x kernel?
> 
> No I do not. Ubuntu on the beaglebones is not my thing . . .
> 
> On Tue, Jul 19, 2016 at 2:31 AM, > wrote:
> Hello William,
> that doesn't sound very encouraging. I just re-downloaded the image from 
> http://elinux.org/BeagleBoardUbuntu#Ubuntu_.2816.04.29 
>  , flashed it on an 
> empty uSD card loaded am335x-boneblack-emmc-
> overlay.dtb and univ-all cape to ensure it wasn't me who broke the image 
> during install. Unfortunately the kernel log showed the same errors. Then I 
> tried to fake the missing directories by creating symlinks to the existing 
> ones, but it didn't work, because symlinks can not be created in sysfs 
> directories.
> Do you happen to know a download location for a working ubuntu 16.04 
> beaglebone image with a 4.4.x kernel?
> 
> 
> Am Montag, 18. Juli 2016 19:00:52 UTC+2 schrieb William Hermans:
> Hi denis,
> 
> I do not know what to say. That Linux image you have seems to be incomplete 
> or somehow broken.
> 
> On Mon, Jul 18, 2016 at 12:56 AM, > wrote:
> Hello William,
> thank you very much for your answer. I just experimented with your solution. 
> Loading the univ-all cape and the setting P9_15 for gpio48 to hi and P8_20 
> for gpio63 to high I was able to activate and deactivate both pins. If I now 
> just load the univ-all cape at startup both GPIOs seem to behave as required 
> and are powered on by my normal startup code. Unfortunately the kernel log 
> now shows a lot of errors after startup.
> 
> [0.00] Booting Linux on physical CPU 0x0
> [0.00] Initializing cgroup subsys cpuset
> [0.00] Initializing cgroup subsys cpu
> [0.00] Initializing cgroup subsys cpuacct
> [0.00] Linux version 4.4.14-bone11 (root@a4-imx6q-wandboard-2gb) (gcc 
> version 5.3.1 20160413 (Ubuntu/Linaro 5.3.1-14ubuntu2.1) ) #1 Sun Jul 3 
> 07:00:48 UTC 2016
> [0.00] CPU: ARMv7 Processor [413fc082] revision 2 (ARMv7), cr=50c5387d
> [0.00] CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing 
> instruction cache
> [0.00] Machine model: TI AM335x BeagleBone Black
> [0.00] cma: Reserved 24 MiB at 0x9e80
> [0.00] Memory policy: Data cache writeback
> [0.00] On node 0 totalpages: 131072
> [0.00] free_area_init_node: node 0, pgdat c0b62d5c, node_mem_map 
> de36d000
> [0.00]   Normal zone: 1152 pages used for memmap
> [0.00]   Normal zone: 0 pages reserved
> [0.00]   Normal zone: 131072 pages, LIFO batch:31
> [0.00] CPU: All CPU(s) started in SVC mode.
> [0.00] AM335X ES2.1 (sgx neon )
> [0.00] pcpu-alloc: s0 r0 d32768 u32768 alloc=1*32768
> [0.00] pcpu-alloc: [0] 0 
> [0.00] Built 1 zonelists in Zone order, mobility grouping on.  Total 
> pages: 129920
> [0.00] Kernel command line: console=ttyO0,115200n8 
> bone_capemgr.enable_partno=univ-all 
> root=UUID=f71c90d7-7127-4727-9b6c-ec6d687c6682 ro rootfstype=ext4 rootwait 
> coherent_pool=1M quiet
> [0.00] PID hash table entries: 2048 (order: 1, 8192 bytes)
> [0.00] Dentry cache hash table entries: 65536 (order: 6, 262144 bytes)
> [0.00] Inode-cache hash table entries: 32768 (order: 5, 131072 bytes)
> [0.00] Memory: 477068K/524288K available (6817K kernel code, 865K 
> rwdata, 3604K rodata, 456K init, 858K bss, 22644K reserved, 24576K 
> cma-reserved, 0K highmem)
> [0.00] Virtual kernel memory layout:
>vector  : 0x - 0x1000   (   4 kB)
> 

Re: [beagleboard] GPIO problems on ubuntu 16.04

2016-07-19 Thread William Hermans
denis,

For what it's worth. Ubuntu mate does not seem very . . ."complete" on any
ARM platform right now. For instance, the Odroid XU4 which has 4 cores
A15's and 4 cores A7 uses an armv7 kernel( 32 bit ). Where the A15 cores
are actually 64bit cores I believe.  Same for the RaspberryPI 3 , and
odroid C2 which both use A53 processors that are also 64bit cores . . . and
this is not only for Ubuntu. It for all Linux's as far as I can tell.

But the point I'm trying to make here is that Ubuntu mate is new, so give
it some time, and these issues which may, or may not be kernel related. To
settle down. So if you have to use Ubuntu, in your shoes. I'd stick with
14.04. But honestly I'd never use Ubuntu on this specific hardware anyhow .
. . an odroid XU4 sure, but not a beaglebone.

On Tue, Jul 19, 2016 at 10:16 AM,  wrote:

> Ok, can't be helped then. :-) Thank you for spending some time on my
> problem.
>
> Am Dienstag, 19. Juli 2016 16:30:26 UTC+2 schrieb William Hermans:
>>
>> Do you happen to know a download location for a working ubuntu 16.04
>> beaglebone image with a 4.4.x kernel?
>>
>>
>> No I do not. Ubuntu on the beaglebones is not my thing . . .
>>
>> On Tue, Jul 19, 2016 at 2:31 AM,  wrote:
>>
>> Hello William,
>> that doesn't sound very encouraging. I just re-downloaded the image from
>> http://elinux.org/BeagleBoardUbuntu#Ubuntu_.2816.04.29 , flashed it on
>> an empty uSD card loaded am335x-boneblack-emmc-
>> overlay.dtb and univ-all cape to ensure it wasn't me who broke the image
>> during install. Unfortunately the kernel log showed the same errors. Then I
>> tried to fake the missing directories by creating symlinks to the existing
>> ones, but it didn't work, because symlinks can not be created in sysfs
>> directories.
>> Do you happen to know a download location for a working ubuntu 16.04
>> beaglebone image with a 4.4.x kernel?
>>
>>
>> Am Montag, 18. Juli 2016 19:00:52 UTC+2 schrieb William Hermans:
>>
>> Hi denis,
>>
>> I do not know what to say. That Linux image you have seems to be
>> incomplete or somehow broken.
>>
>> On Mon, Jul 18, 2016 at 12:56 AM,  wrote:
>>
>> Hello William,
>> thank you very much for your answer. I just experimented with your
>> solution. Loading the univ-all cape and the setting P9_15 for gpio48 to hi
>> and P8_20 for gpio63 to high I was able to activate and deactivate both
>> pins. If I now just load the univ-all cape at startup both GPIOs seem to
>> behave as required and are powered on by my normal startup code.
>> Unfortunately the kernel log now shows a lot of errors after startup.
>>
>> [0.00] Booting Linux on physical CPU 0x0
>> [0.00] Initializing cgroup subsys cpuset
>> [0.00] Initializing cgroup subsys cpu
>> [0.00] Initializing cgroup subsys cpuacct
>> [0.00] Linux version 4.4.14-bone11 (root@a4-imx6q-wandboard-2gb)
>> (gcc version 5.3.1 20160413 (Ubuntu/Linaro 5.3.1-14ubuntu2.1) ) #1 Sun
>> Jul 3 07:00:48 UTC 2016
>> [0.00] CPU: ARMv7 Processor [413fc082] revision 2 (ARMv7), cr=
>> 50c5387d
>> [0.00] CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing
>> instruction cache
>> [0.00] Machine model: TI AM335x BeagleBone Black
>> [0.00] cma: Reserved 24 MiB at 0x9e80
>> [0.00] Memory policy: Data cache writeback
>> [0.00] On node 0 totalpages: 131072
>> [0.00] free_area_init_node: node 0, pgdat c0b62d5c, node_mem_map
>> de36d000
>> [0.00]   Normal zone: 1152 pages used for memmap
>> [0.00]   Normal zone: 0 pages reserved
>> [0.00]   Normal zone: 131072 pages, LIFO batch:31
>> [0.00] CPU: All CPU(s) started in SVC mode.
>> [0.00] AM335X ES2.1 (sgx neon )
>> [0.00] pcpu-alloc: s0 r0 d32768 u32768 alloc=1*32768
>> [0.00] pcpu-alloc: [0] 0
>> [0.00] Built 1 zonelists in Zone order, mobility grouping on.
>> Total pages: 129920
>> [0.00] Kernel command line: console=ttyO0,115200n8 bone_capemgr.
>> enable_partno=univ-all root=UUID=f71c90d7-7127-4727-9b6c-ec6d687c6682 ro
>> rootfstype=ext4 rootwait coherent_pool=1M quiet
>> [0.00] PID hash table entries: 2048 (order: 1, 8192 bytes)
>> [0.00] Dentry cache hash table entries: 65536 (order: 6, 262144
>> bytes)
>> [0.00] Inode-cache hash table entries: 32768 (order: 5, 131072
>> bytes)
>> [0.00] Memory: 477068K/524288K available (6817K kernel code, 865K
>> rwdata, 3604K rodata, 456K init, 858K bss, 22644K reserved, 24576K cma-
>> reserved, 0K highmem)
>> [0.00] Virtual kernel memory layout:
>>vector  : 0x - 0x1000   (   4 kB)
>>fixmap  : 0xffc0 - 0xfff0   (3072 kB)
>>vmalloc : 0xe080 - 0xff80   ( 496 MB)
>>lowmem  : 0xc000 - 0xe000   ( 512 MB)
>>pkmap   : 0xbfe0 - 0xc000   (   2 MB)
>>modules : 0xbf80 - 0xbfe0   (   6 MB)
>>  

Re: [beagleboard] GPIO problems on ubuntu 16.04

2016-07-19 Thread denis . fisseler
Ok, can't be helped then. :-) Thank you for spending some time on my 
problem.

Am Dienstag, 19. Juli 2016 16:30:26 UTC+2 schrieb William Hermans:
>
> Do you happen to know a download location for a working ubuntu 16.04 
> beaglebone image with a 4.4.x kernel?
>
>
> No I do not. Ubuntu on the beaglebones is not my thing . . .
>
> On Tue, Jul 19, 2016 at 2:31 AM, > 
> wrote:
>
> Hello William,
> that doesn't sound very encouraging. I just re-downloaded the image from 
> http://elinux.org/BeagleBoardUbuntu#Ubuntu_.2816.04.29 , flashed it on an 
> empty uSD card loaded am335x-boneblack-emmc-
> overlay.dtb and univ-all cape to ensure it wasn't me who broke the image 
> during install. Unfortunately the kernel log showed the same errors. Then I 
> tried to fake the missing directories by creating symlinks to the existing 
> ones, but it didn't work, because symlinks can not be created in sysfs 
> directories.
> Do you happen to know a download location for a working ubuntu 16.04 
> beaglebone image with a 4.4.x kernel?
>
>
> Am Montag, 18. Juli 2016 19:00:52 UTC+2 schrieb William Hermans:
>
> Hi denis,
>
> I do not know what to say. That Linux image you have seems to be 
> incomplete or somehow broken.
>
> On Mon, Jul 18, 2016 at 12:56 AM,  wrote:
>
> Hello William,
> thank you very much for your answer. I just experimented with your 
> solution. Loading the univ-all cape and the setting P9_15 for gpio48 to hi 
> and P8_20 for gpio63 to high I was able to activate and deactivate both 
> pins. If I now just load the univ-all cape at startup both GPIOs seem to 
> behave as required and are powered on by my normal startup code. 
> Unfortunately the kernel log now shows a lot of errors after startup.
>
> [0.00] Booting Linux on physical CPU 0x0
> [0.00] Initializing cgroup subsys cpuset
> [0.00] Initializing cgroup subsys cpu
> [0.00] Initializing cgroup subsys cpuacct
> [0.00] Linux version 4.4.14-bone11 (root@a4-imx6q-wandboard-2gb) (gcc 
> version 5.3.1 20160413 (Ubuntu/Linaro 5.3.1-14ubuntu2.1) ) #1 Sun Jul 3 
> 07:00:48 UTC 2016
> [0.00] CPU: ARMv7 Processor [413fc082] revision 2 (ARMv7), cr=
> 50c5387d
> [0.00] CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing 
> instruction cache
> [0.00] Machine model: TI AM335x BeagleBone Black
> [0.00] cma: Reserved 24 MiB at 0x9e80
> [0.00] Memory policy: Data cache writeback
> [0.00] On node 0 totalpages: 131072
> [0.00] free_area_init_node: node 0, pgdat c0b62d5c, node_mem_map 
> de36d000
> [0.00]   Normal zone: 1152 pages used for memmap
> [0.00]   Normal zone: 0 pages reserved
> [0.00]   Normal zone: 131072 pages, LIFO batch:31
> [0.00] CPU: All CPU(s) started in SVC mode.
> [0.00] AM335X ES2.1 (sgx neon )
> [0.00] pcpu-alloc: s0 r0 d32768 u32768 alloc=1*32768
> [0.00] pcpu-alloc: [0] 0 
> [0.00] Built 1 zonelists in Zone order, mobility grouping on.  
> Total pages: 129920
> [0.00] Kernel command line: console=ttyO0,115200n8 bone_capemgr.
> enable_partno=univ-all root=UUID=f71c90d7-7127-4727-9b6c-ec6d687c6682 ro 
> rootfstype=ext4 rootwait coherent_pool=1M quiet
> [0.00] PID hash table entries: 2048 (order: 1, 8192 bytes)
> [0.00] Dentry cache hash table entries: 65536 (order: 6, 262144 
> bytes)
> [0.00] Inode-cache hash table entries: 32768 (order: 5, 131072 
> bytes)
> [0.00] Memory: 477068K/524288K available (6817K kernel code, 865K 
> rwdata, 3604K rodata, 456K init, 858K bss, 22644K reserved, 24576K cma-
> reserved, 0K highmem)
> [0.00] Virtual kernel memory layout:
>vector  : 0x - 0x1000   (   4 kB)
>fixmap  : 0xffc0 - 0xfff0   (3072 kB)
>vmalloc : 0xe080 - 0xff80   ( 496 MB)
>lowmem  : 0xc000 - 0xe000   ( 512 MB)
>pkmap   : 0xbfe0 - 0xc000   (   2 MB)
>modules : 0xbf80 - 0xbfe0   (   6 MB)
>  .text : 0xc0008000 - 0xc0a35940   (10423 kB)
>  .init : 0xc0a36000 - 0xc0aa8000   ( 456 kB)
>  .data : 0xc0aa8000 - 0xc0b80558   ( 866 kB)
>   .bss : 0xc0b83000 - 0xc0c599e4   ( 859 kB)
> [0.00] NR_IRQS:16 nr_irqs:16 16
> [0.00] IRQ: Found an INTC at 0xfa20 (revision 5.0) with 128 
> interrupts
> [0.00] OMAP clockevent source: timer2 at 2400 Hz
> [0.10] sched_clock: 32 bits at 24MHz, resolution 41ns, wraps 
> every 89478484971ns
> [0.27] clocksource: timer1: mask: 0x max_cycles: 
> 0x, max_idle_ns: 79635851949 ns
> [0.37] OMAP clocksource: timer1 at 2400 Hz
> [0.000278] Console: colour dummy device 80x30
> [0.000302] WARNING: Your 'console=ttyO0' has been replaced by 'ttyS0'
> [0.000308] This ensures that you still see kern

Re: [beagleboard] GPIO problems on ubuntu 16.04

2016-07-14 Thread William Hermans
Denis,

Which kernel version are you using for your system ? Ah ok, you said it at
the beginning. a 4.4.x*bone* variant. Can you easily configure a test
system to test the pin with the universal-io config-pin tool ? How I
personally did this was . . .
*/boot/uEnv.txt*
. . .
##BeagleBone Black: HDMI (Audio/Video) disabled:
dtb=am335x-boneblack-emmc-overlay.dtb
. . .
##Example v4.1.x
#cape_disable=bone_capemgr.disable_partno=
cape_enable=bone_capemgr.enable_partno=univ-all

*Then download the config-pin tool.*
$ wget
https://raw.githubusercontent.com/cdsteinkuehler/beaglebone-universal-io/master/config-pin
$ chmod +x config-pin

*check the pin configuration:*
$ sudo ./ config-pin -q P9.15 /* gpio48 */
P9_15 Mode: default Direction: in Value: 1

*Test gpio48:*
$ sudo ./config-pin P9.15 hi
$ sudo ./config-pin -q P9.15
P9_15 Mode: gpio Direction: out Value: 1
$ sudo ./config-pin P9.15 low
$ sudo ./config-pin -q P9.15
P9_15 Mode: gpio Direction: out Value: 0

So  if this works. You'll have some sort of software issue. If it does not
. . . you may have defective hardware.






On Thu, Jul 14, 2016 at 3:29 PM,  wrote:

> Hello,
> I have a beaglebone black, and I am having some serious problems with the
> GPIO configuration, trying to migrate our working ubuntu 14.04 installation
> to ubuntu 16.04. The beaglebone sits on a specifically constructed board,
> that needs some GPIOs and the CAN-bus working, to function properly. As a
> starting point, I took the preconfigured 16.04 image from
> http://elinux.org/BeagleBoardUbuntu#Ubuntu_.2816.04.29 and installed the
> modified 4.4 kernel (--bone-kernel --lts-4_4 as described here:
> http://elinux.org/Beagleboard:BeagleBoneBlack_Debian#Mainline_.284.4.x_lts.29).
>
>
> I modified a dts script for a CAN overlay and got it working. Then, using
> Adafruit with python3, I got the required GPIOs configured. However
> autostart of CAN and GPIOs works only, if I force the respective init.d
> script to start after $network, which could pose a problem later, as the
> power supply for our wlan rounter is powered on using GPIOs.
>
> Nonetheless, the resulting entries in /sys/class/gpio are:
> gpio115, gpio26, gpio38, gpio44, gpio46, gpio48, gpio63, gpio65
>
> With the respective device trees in:
> /sys/devices/platform/ocp/44e07000.gpio/gpio/
> gpio26 (LED)
>
> /sys/devices/platform/ocp/481ac000.gpio/gpio/
> gpio65 (LED)
>
> /sys/devices/platform/ocp/4804c000.gpio/gpio (wird in der BBB_Setup.py
> benutzt)
> gpio38 (scanner_running)
> gpio44 (LED)
> gpio46 (LED)
> gpio48 (scanner_pwr)
> gpio63 (LED)
>
> /sys/devices/platform/ocp/481ae000.gpio/gpio/
> gpio115 (motor_pwr)
>
> At this point, I am able to power up the motor with gpio115 and four of
> the LEDs (gpio44, gpio46, gpio26, gpio65) via python or writing to the
> value files in the device tree.
> Unfortunately gpio48 always stays at measured 0.9V, regardless of the
> values written to the value file or the output commands issued using python
> and gpio63 always outputs something similar to a HIGH signal. As I
> suspected some other conflicting capes, I copied the system from eMMC to
> uSD and disabled the eMMC and HDMI/HDMI-audio capes in /boot/uEnv.txt. The
> slots in /sys/bus/platform/devices/bone_capemgr/slots now show only the CAN
> and the Adafruit capes. pinmux-pins and pingroups in
> /sys/kernel/debug/pinctrl/44e10800.pinmux look, as if all required pins are
> configured as GPIO unclaimed. However gpio48 and gpio63 still do not react
> to any output commands. Then I tried to build a device tree overlay using
> the patched version of the dtc compiler and configuring the required pins
> to work as outputs in mode7. Loading this cape gives me a probably kernel
> related error(see cape-error.log) that does not occur, if w1-gpio and
> w1-term are loaded using modprobe in advance. Regardless of this cape being
> loaded, gpio48 and gpio63 are still not working.
>
> I made some logs, that may be helpful with the diagnosis of the problem:
> www.defi1.de/beaglebone/cape-slots.log (slots right after booting)
> www.defi1.de/beaglebone/dmesg.log (kernel message log right after booting)
> www.defi1.de/beaglebone/cape-error.log (error in kernel message log when
> trying to load my custom cape)
> www.defi1.de/beaglebone/overlays.log (the device tree overlays created
> with Adafruit)
> www.defi1.de/beaglebone/pinmux-pins.log
> www.defi1.de/beaglebone/piongroups.log
>
> Any help on this would be appreciated.
>
>
> --
> For more options, visit http://beagleboard.org/discuss
> ---
> You received this message because you are subscribed to the Google Groups
> "BeagleBoard" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to beagleboard+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/beagleboard/26aa24b0-f201-43de-863d-f6961b679471%40googlegroups.com
> 

[beagleboard] GPIO problems on ubuntu 16.04

2016-07-14 Thread denis . fisseler
Hello,
I have a beaglebone black, and I am having some serious problems with the 
GPIO configuration, trying to migrate our working ubuntu 14.04 installation 
to ubuntu 16.04. The beaglebone sits on a specifically constructed board, 
that needs some GPIOs and the CAN-bus working, to function properly. As a 
starting point, I took the preconfigured 16.04 image from 
http://elinux.org/BeagleBoardUbuntu#Ubuntu_.2816.04.29 and installed the 
modified 4.4 kernel (--bone-kernel --lts-4_4 as described here: 
http://elinux.org/Beagleboard:BeagleBoneBlack_Debian#Mainline_.284.4.x_lts.29). 


I modified a dts script for a CAN overlay and got it working. Then, using 
Adafruit with python3, I got the required GPIOs configured. However 
autostart of CAN and GPIOs works only, if I force the respective init.d 
script to start after $network, which could pose a problem later, as the 
power supply for our wlan rounter is powered on using GPIOs.

Nonetheless, the resulting entries in /sys/class/gpio are:
gpio115, gpio26, gpio38, gpio44, gpio46, gpio48, gpio63, gpio65

With the respective device trees in:
/sys/devices/platform/ocp/44e07000.gpio/gpio/
gpio26 (LED)

/sys/devices/platform/ocp/481ac000.gpio/gpio/
gpio65 (LED)

/sys/devices/platform/ocp/4804c000.gpio/gpio (wird in der BBB_Setup.py 
benutzt)
gpio38 (scanner_running)
gpio44 (LED)
gpio46 (LED)
gpio48 (scanner_pwr)
gpio63 (LED)

/sys/devices/platform/ocp/481ae000.gpio/gpio/
gpio115 (motor_pwr)

At this point, I am able to power up the motor with gpio115 and four of the 
LEDs (gpio44, gpio46, gpio26, gpio65) via python or writing to the value 
files in the device tree.
Unfortunately gpio48 always stays at measured 0.9V, regardless of the 
values written to the value file or the output commands issued using python 
and gpio63 always outputs something similar to a HIGH signal. As I 
suspected some other conflicting capes, I copied the system from eMMC to 
uSD and disabled the eMMC and HDMI/HDMI-audio capes in /boot/uEnv.txt. The 
slots in /sys/bus/platform/devices/bone_capemgr/slots now show only the CAN 
and the Adafruit capes. pinmux-pins and pingroups in 
/sys/kernel/debug/pinctrl/44e10800.pinmux look, as if all required pins are 
configured as GPIO unclaimed. However gpio48 and gpio63 still do not react 
to any output commands. Then I tried to build a device tree overlay using 
the patched version of the dtc compiler and configuring the required pins 
to work as outputs in mode7. Loading this cape gives me a probably kernel 
related error(see cape-error.log) that does not occur, if w1-gpio and 
w1-term are loaded using modprobe in advance. Regardless of this cape being 
loaded, gpio48 and gpio63 are still not working.

I made some logs, that may be helpful with the diagnosis of the problem:
www.defi1.de/beaglebone/cape-slots.log (slots right after booting)
www.defi1.de/beaglebone/dmesg.log (kernel message log right after booting)
www.defi1.de/beaglebone/cape-error.log (error in kernel message log when 
trying to load my custom cape)
www.defi1.de/beaglebone/overlays.log (the device tree overlays created with 
Adafruit)
www.defi1.de/beaglebone/pinmux-pins.log
www.defi1.de/beaglebone/piongroups.log

Any help on this would be appreciated.


-- 
For more options, visit http://beagleboard.org/discuss
--- 
You received this message because you are subscribed to the Google Groups 
"BeagleBoard" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to beagleboard+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/beagleboard/26aa24b0-f201-43de-863d-f6961b679471%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.