12.07.2015 Views

SUB-20 User Manual - Dimax

SUB-20 User Manual - Dimax

SUB-20 User Manual - Dimax

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

39<strong>SUB</strong>-<strong>20</strong><strong>SUB</strong>-<strong>20</strong> APICompatibilityFW versionLibrary version0.2.7 or grater0.1.12.17 or grater3.7.6 sub_gpiob_writeSynopsisint sub_gpiob_write( sub_handle hndl, int set, int* get, int mask )Set GPIOB output status. For GPIOB in output state function will set output driver to drive "1"-high, "0"-low. ForGPIO in input state function will "1"-enable, "0"-disable weak pull-up on corresponding GPIOB pin.Parameters· set - Bits 0..7 of set parameter correspond to GPIOB0..GPIOB7 output statuses.· *get - Pointer to store current GPIOB output status read from <strong>SUB</strong>-<strong>20</strong>.· mask - Bit in set parameter will take effect only if corresponding mask bit is "1". With mask=0 function willonly read current GPIOB output status.Return valueOn success function returns 0. Otherwise error code.See alsoError CodesCompatibilityFW versionLibrary version0.2.7 or grater0.1.12.17 or grater3.7.7 Edge DetectorEdge Detector description<strong>SUB</strong>-<strong>20</strong> Edge detector module (EDGE) is capable to detect falling, rising or "any change" edge on the GPIOpins listed below.GPIO Header Pin GPIO Edge Number1 GPIO8 EDG02 GPIO9 EDG13 GPIO10 EDG24 GPIO11 EDG313 GPIO28 EDG414 GPIO29 EDG515 GPIO30 EDG616 GPIO31 EDG7Pulses on EDG7:0 pins wider than the minimum pulse width of 50ns will trigger edge detection. If enabled, theedge detection will trigger even if the corresponding GPIO are configured as outputs.Functionssub_edge_configsub_edge_read© <strong>20</strong>13 xdimax.com rev 2.17

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!