X-Git-Url: https://codewiz.org/gitweb?a=blobdiff_plain;f=examples%2Flpc2378%2Fhw%2Fhw_sipo.h;fp=examples%2Flpc2378%2Fhw%2Fhw_sipo.h;h=b4fba473a4428dcfe857de958ce2328b94797515;hb=ab067bd420a6e48b25d66444d97ee229b48bcb23;hp=0000000000000000000000000000000000000000;hpb=8284fb65c8c8f9fd233da33fd08f1f81b64cb94b;p=bertos.git diff --git a/examples/lpc2378/hw/hw_sipo.h b/examples/lpc2378/hw/hw_sipo.h new file mode 100644 index 00000000..b4fba473 --- /dev/null +++ b/examples/lpc2378/hw/hw_sipo.h @@ -0,0 +1,109 @@ +/** + * \file + * + * + * \brief Macro for HW_SIPO_H + * + * + * \version $Id: hw_sipo.h 2882 2009-09-04 19:17:37Z batt $ + * + * \author Andrea Grandi + * \author Daniele Basile + */ + +#ifndef HW_SIPO_H +#define HW_SIPO_H + +/** + * Map sipo connection on board. + */ +typedef enum SipoMap +{ + SIPO_CNT +} SipoMap; + +/** + * Define generic macro to set pins logic level + */ +#define SIPO_SET_LEVEL_LOW(dev) do { /* Implement me! */ } while (0) +#define SIPO_SET_LEVEL_HIGH(dev) do { /* Implement me! */ } while (0) + + +/** + * Generate one low pulse on select line. + */ +#define PULSE_LOW(dev) do { /* Implement me! */ } while (0) + +/** + * Generate one hight pulse on select line. + */ +#define PULSE_HIGH(dev) do { /* Implement me! */ } while (0) + + +/** + * Define the procedure to drive serial input in sipo device (SI). + */ +#define SIPO_SI_HIGH() do { /* Implement me! */ } while (0) +#define SIPO_SI_LOW() do { /* Implement me! */ } while (0) + +/** + * Drive clock to shift SI data into latch. + */ +#define SIPO_SI_CLOCK(clk_pol) \ + do { \ + (void)clk_pol; \ + /* Implement me! */ \ + } while (0) + +/** + * Do everything needed in order to load dato into sipo. + */ +#define SIPO_LOAD(device, load_pol) do { /* Implement me! */ } while (0) + +/** + * Enable the shift register output. + */ +#define SIPO_ENABLE() do { /* Implement me! */ } while (0) + +/** + * Set polarity for Load, Clk, SI signals. + */ +#define SIPO_SET_LD_LEVEL(device, load_pol) do { /* Implement me! */ } while (0) +#define SIPO_SET_CLK_LEVEL(clock_pol) do { /* Implement me! */ } while (0) +#define SIPO_SET_SI_LEVEL() do { /* Implement me! */ } while (0) + +/** + * Do anything that needed to init sipo pins. + */ +#define SIPO_INIT_PIN() do { /* Implement me! */ } while (0) + +#endif /* HW_SIPO_H */