17 from __future__
import print_function
18 from libpruio
import *
21 io =
pruio_new(PRUIO_DEF_ACTIVE, 4, 0x98, 0)
25 if IO.Errr:
raise AssertionError(
"pruio_new failed (%s)" % IO.Errr)
27 raise AssertionError(
"config failed (%s)" % IO.Errr)
29 AdcV = IO.Adc.contents.Value
32 print(
"%4X" % AdcV[i], end=
" ")
char * pruio_config(pruIo *Io, uint32 Samp, uint32 Mask, uint32 Tmr, uint16 Mds)
Wrapper function for PruIo::config().
pruIo * pruio_new(uint16 Act, uint8 Av, uint32 OpD, uint8 SaD)
Wrapper function for the constructor PruIo::PruIo().
void pruio_destroy(pruIo *Io)
Wrapper function for the destructor PruIo::~PruIo().