Hi Rudy!

Bitbanging from kernel module puts a lot of load on the ARM CPU and slows 
down the whole system.

Find an example on how to toggle a fast PRU GPIO at this link 
<http://users.freebasic-portal.de/tjf/Projekte/libpruio/doc/html/ChaExamples.html#sSecExaPruToggle>.
 
It runs at user space, no reboot nor administrator privileges necessary. 
The code limits the toggling frequency down to 40 MHz in order to get good 
measurements by the eCAP feature. When you remove the NOOPs from the PRU 
ASM code you can get up to 200 MHz toggling frequency (=100 MHz pulse train 
@ 50 % duty cycle).

Regards

Am Freitag, 26. Oktober 2018 02:41:29 UTC+2 schrieb [email protected]:
>
> Hi Wesley,
>
> I'm interested in checking this out!
>
> The download links are broken, are you able to post new links?
>
> Hope you're having a top day :D
>
> -Rudy.
>
> On Friday, August 31, 2012 at 7:04:39 AM UTC+10, Wesley wrote:
>>
>> Hey,
>>
>> So I tested to see how fast the GPIO toggle rate of the Beaglebone could 
>> get when using a kernel module. When using user space it was only about 4-5 
>> MHz and once I did the kernel module it got up to 25 MHz. Since I had a 
>> difficult time getting the kernel source tree on the beaglebone and 
>> compiling everything here is some documentation and code for those who want 
>> to build kernel modules/device drivers on the beaglebone and also user 
>> program interaction with the kernel module.
>>
>> gpio.c is the kernel code
>> gpio.h is the header file for both gpio.c and ioctl.c
>> ioctl.c is the user code
>>
>> Here is my Makefile in case you want it also
>>
>> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>> obj-m := gpio.o
>>
>> KERNELDIR := /usr/src/linux-3.2.23
>>
>> default:
>>         $(MAKE) -C $(KERNELDIR) M=$(PWD) modules
>> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>>
>> Also, the websites that I used that helped me get here were mainly these:
>> https://groups.google.com/forum/#!msg/beagleboard/BKnNkP3qzQs/PNloua3737MJ
>> http://www.cemetech.net/forum/viewtopic.php?t=7814
>> and the Linux Device Drivers book
>>
>> ~Wesley
>>
>>

-- 
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 [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/beagleboard/a74db385-5d77-4f31-ab44-f90be80b1e76%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to