2009-05-24 17:25:50 GPIOs
Nikolay Chokoev (IRELAND)
Message: 74507
Hi,
How the GPIO numbers in ucLinux are realated to the physical Blackfin ports?
QuoteReplyEditDelete
2009-05-24 17:28:57 Re: GPIOs
Mike Frysinger (UNITED STATES)
Message: 74508
why do you want to know ? in most cases, you shouldnt care.
QuoteReplyEditDelete
2009-05-24 18:57:04 Re: GPIOs
Frank Van Hooft (CANADA)
Message: 74511
Mike is right; in general you shouldn't play with GPIO numbers, you should reference their names (eg GPIO_PG8). However, if you're curious, you might find the table at the bottom of this wiki page interesting:
docs.blackfin.uclinux.org/doku.php
QuoteReplyEditDelete
2009-05-26 17:34:27 Re: GPIOs
Steve Strobel (UNITED STATES)
Message: 74623
You need to know when configuring the interrupt line for the isp1362 through the config system, for example.
QuoteReplyEditDelete
2009-05-26 17:46:23 Re: GPIOs
Mike Frysinger (UNITED STATES)
Message: 74624
that is because the driver sucks, but you are correct there
QuoteReplyEditDelete
2009-05-28 11:42:44 Re: GPIOs
Lukasz Jaruszewski (POLAND)
Message: 74712
Hi, I have BF 533 Stamp. My question, meybe trivial, is how can I set "1" on some of STAMP pins. I tried to do this but my program didn't want to go through compilation process. I haven't right librarys or /and I don't know which pin on STAMP is releted to appropriate GPIO number. Meybe someone of you have this kind of program for Blackfin 533 (or know how to write it) and he share with me.
I'm using gcc compiler downloaded from blackfin.uclinux.org website:
- blackfin-toolchain-08r1.5-14.i386.rpm
-blackfin-toolchain-uclibc-full-08r1.5-14.i386.rpm
I will be very grateful for any suggestions and pieces of advice.
QuoteReplyEditDelete
2009-05-28 12:26:30 Re: GPIOs
Mike Frysinger (UNITED STATES)
Message: 74717
if you're using Linux, then you can use the GPIO framework:
docs.blackfin.uclinux.org/doku.php?id=gpio
the next release will have a driver so people can easily do it from userspace:
docs.blackfin.uclinux.org/doku.php?id=linux-kernel:drivers:simple-gpio
QuoteReplyEditDelete
2009-05-28 13:22:25 Re: GPIOs
Lukasz Jaruszewski (POLAND)
Message: 74720
Mike,
Thanks for response - this is exactly what I wanted to know. I'm using uImage-bf533-stamp-2008R1.5-RC3 downloaded from release section of blackfin.uclinux.org. I supose, I haven't implemented simple_gpio in my uClinux so when can I expect a new release of uClinux with this stuff implemented?
I am in a rush with my master degree project so I will try with GPIO Framework.
Many thanks again.
Lukasz
QuoteReplyEditDelete
2009-05-28 14:47:53 Re: GPIOs
Mike Frysinger (UNITED STATES)
Message: 74722
we hope to have it finished in June
QuoteReplyEditDelete
2009-05-29 14:05:34 Re: GPIOs
Lukasz Jaruszewski (POLAND)
Message: 74778
I tried to compile my program through bfin-uclinux-gcc, but I can see I haven't all librarys, f. e. gpio.h and library with Memory Mapping for BF533 - I want to use GPIO_PG8 but my gcc doesn't see this name.
Do you know where can I find those librarys?
Thanks,
Lukasz
QuoteReplyEditDelete
2009-05-29 15:16:10 Re: GPIOs
Mike Frysinger (UNITED STATES)
Message: 74781
you cannot access MMRs directly from userspace. that is the kernel's job.
QuoteReplyEditDelete
2009-06-01 13:31:23 Re: GPIOs
Lukasz Jaruszewski (POLAND)
Message: 74927
Mike:
In Docs: docs.blackfin.uclinux.org/doku.php?id=gpio I can see functions responsible for setting and getting value to/from GPIO:
void gpio_set_value(unsigned gpio, int arg);
and
int gpio_get_value(unsigned gpio);
You wrote that access to MMRs is a kernel job. Is it means that I must compile kernel with above functions implemented to using GPIOs (f.e. GPIO_PG8)? Is any chance to set/get value to my BF533 Stamp pin with uImage-bf533-stamp-2008R1.5-RC3 which I'm using now?
I will be very grateful if you write litle more about: How can I set/get value to/from GPIO?
QuoteReplyEditDelete
2009-06-01 16:18:48 Re: GPIOs
Mike Frysinger (UNITED STATES)
Message: 74933
if you want to use the GPIO framework, you need to write a kernel driver. if you want to access things from userspace, you can use the simple-gpio driver:
docs.blackfin.uclinux.org/doku.php?id=linux-kernel:drivers:simple-gpio
but that isnt in the 2008R1.5 release. you'll have to use the 2008R1.5 svn branch.
QuoteReplyEditDelete
2009-06-05 11:22:51 Re: GPIOs
Lukasz Jaruszewski (POLAND)
Message: 75254
Mike:
Thanks a lot for your replay.
Regarding your last post: can I use SVN branch uImage-SVN-r8215-bf533-stamp downloaded from blackfin.uclinux.org/gf/project/uclinux-dist/frs web site? Is this stuff including simple-gpio driver described in following Docs section: docs.blackfin.uclinux.org/doku.php?id=linux-kernel:drivers:simple-gpio ?
I want to be 100% sure before I'll test GPIO on BF533-Stamp.
Lukasz Jaruszewski.
QuoteReplyEditDelete
2009-06-07 02:48:49 Re: GPIOs
Mike Frysinger (UNITED STATES)
Message: 75303
probably