Smartpin register use summary WRPIN WXPIN WYPIN RDPIN Mode description ======================================================================================================================================= %00001 byte - byte Byte repository --------------------------------------------------------------------------------------------------------------------------------------- %00001 period - ADC accumulation DAC noise --------------------------------------------------------------------------------------------------------------------------------------- %00010 word - word Word repository --------------------------------------------------------------------------------------------------------------------------------------- %00010 period duration ADC accumulation 16 bit psueido-random dither --------------------------------------------------------------------------------------------------------------------------------------- %00011 long - long Long repository --------------------------------------------------------------------------------------------------------------------------------------- %00011 period duration ADC accumulation 16 bit PWM dither --------------------------------------------------------------------------------------------------------------------------------------- %00100 X[15:0] Base period pulses/cycles - Pulse/cycle output X[31:16] Compare --------------------------------------------------------------------------------------------------------------------------------------- %00101 X[15:0] Base period transitions - Transition output --------------------------------------------------------------------------------------------------------------------------------------- %00110 X[15:0] Base period NCO value - NCO frequency output --------------------------------------------------------------------------------------------------------------------------------------- %00111 X[15:0] base period NCO value - NCO Duty --------------------------------------------------------------------------------------------------------------------------------------- %01000 X[15:0] base period Y[15:0] Output value - PWM Triangle X[31:16] Frame period --------------------------------------------------------------------------------------------------------------------------------------- %01001 X[15:0] base period Y[15:0] Output value - PWM Sawtooth X[31:16] Frame period --------------------------------------------------------------------------------------------------------------------------------------- %01010 X[15:0] base period Y[15:0] Output value - PWM Switchmode power supply X[31:16] Frame period --------------------------------------------------------------------------------------------------------------------------------------- %01011 period - Encoder value A/B Quadrature encoder --------------------------------------------------------------------------------------------------------------------------------------- %01100 period - count Count A-Input highs --------------------------------------------------------------------------------------------------------------------------------------- %01101 period - count Count A-Input positive edges --------------------------------------------------------------------------------------------------------------------------------------- %01110 period - count A-Input highs inc B-Input highs dec --------------------------------------------------------------------------------------------------------------------------------------- %01111 period - count A-Input pos edge inc B-Input pos edge dec --------------------------------------------------------------------------------------------------------------------------------------- %10000 - - z[31] Prior state Time A-input states Z[30:0] Prior duration --------------------------------------------------------------------------------------------------------------------------------------- %10001 - - z[30:0] Prior duration Time A-input high states --------------------------------------------------------------------------------------------------------------------------------------- %10010 high count - - Time X A-input high count --------------------------------------------------------------------------------------------------------------------------------------- %10011 periods Y[1:0] state/edge z{30:0] time For X periods count time --------------------------------------------------------------------------------------------------------------------------------------- %10100 periods Y[1:0] state/edge Z[30:0] states For X periods count states --------------------------------------------------------------------------------------------------------------------------------------- %10101 periods Y[1:0] state/edge Z[30:0] time For periods in X+ clock cycles, count time --------------------------------------------------------------------------------------------------------------------------------------- %10110 periods Y[1:0] state/edge Z[30:0] states For periods in X+ clock cycles, count states --------------------------------------------------------------------------------------------------------------------------------------- %10111 periods Y[1:0] state/edge Z[30:0] periods For periods in X+ clock cycles, count periods --------------------------------------------------------------------------------------------------------------------------------------- %11000 NCO baud output input/status USB Host, low speed --------------------------------------------------------------------------------------------------------------------------------------- %11001 NCO baud output input/status USB Host, full speed --------------------------------------------------------------------------------------------------------------------------------------- %11010 NCO baud output input/status USB Device, low speed --------------------------------------------------------------------------------------------------------------------------------------- %11011 NCO baud output input/status USB Device, full speed --------------------------------------------------------------------------------------------------------------------------------------- %11100 X[5] Update mode output word - Synchronous serial receiver X[4:0] bits-1 --------------------------------------------------------------------------------------------------------------------------------------- %11101 X[5] sample position - recieved word Synchronous serial transmitter X[4:0] bits-1 --------------------------------------------------------------------------------------------------------------------------------------- %11110 X[31] Counter/NCO output word Z[7] busy flag ASynchronous serial receiver X[30:16] baud rate X[4:0] bits-1 --------------------------------------------------------------------------------------------------------------------------------------- %11111 X[31] Counter/NCO - Received word ASynchronous serial transmittter X[30:16] baud rate X[4:0] bits-1