*** UNIX MANUAL PAGE BROWSER ***

A Nergahak database for man pages research.

Navigation

Directory Browser

1Browse 4.4BSD4.4BSD
1Browse Digital UNIXDigital UNIX 4.0e
1Browse FreeBSDFreeBSD 14.3
1Browse MINIXMINIX 3.4.0rc6-d5e4fc0
1Browse NetBSDNetBSD 10.1
1Browse OpenBSDOpenBSD 7.7
1Browse UNIX v7Version 7 UNIX
1Browse UNIX v10Version 10 UNIX

Manual Page Search

Manual Page Result

0 Command: gpiopwm | Section: 4 | Source: NetBSD | File: gpiopwm.4
GPIOPWM(4) FreeBSD Kernel Interfaces Manual GPIOPWM(4) NAME gpiopwm - support for pulsing GPIO pins in software SYNOPSIS gpiopwm* at gpio? offset ? mask 1 gpiopwm* at gpio? DESCRIPTION The gpiopwm driver allows for pulsing GPIO pins in software using the callout(9) facility. The pulse frequency and duty cycle are specified indirectly by setting an "on" and "off" period, in ticks. Both values are accessible as sysctl(3) variables. SYSCTL VARIABLES The following sysctl(3) variables are used to define the pulsing: hw.gpiopwmN.off Define the "off" period in ticks. hw.gpiopwmN.on Define the "on" period in ticks. Only when both the "on" and the "off" period are set to values higher than zero pulsing will start. To stop the pulsing, set either value to zero. EXAMPLES To pulse a pin on a machine with 100 ticks/second with a frequency of 1Hz and a duty cycle of 20%, the "on" period must be set to 20 and the "off" period must be set to 80. The following example will pulse the error LED of a Soekris net4801 with a frequency of 1 Hz and a duty cycle of 20%: # gpioctl gpio0 20 set pp # gpioctl gpio0 attach gpiopwm 20 1 # sysctl -w hw.gpiopwm0.off=80 # sysctl -w hw.gpiopwm0.on=20 SEE ALSO gpio(4), intro(4), gpioctl(8), sysctl(8) HISTORY The gpiopwm driver first appeared in NetBSD 6.0. AUTHORS The gpiopwm driver was written by Marc Balmer <[email protected]>. FreeBSD 14.1-RELEASE-p8 November 13, 2011 FreeBSD 14.1-RELEASE-p8

Navigation Options