define data and clock pins in one object then pass that as one argument to 2-wire objects

Dependents:   Nucleo_read_button_interrupt_copy Seeed_Grove_4_Digit_Display_Clock

DataClockPair.h

Committer:
tulanthoar
Date:
2017-05-21
Revision:
1:a288ae0fdd74
Parent:
0:6d9fab76ca5b

File content as of revision 1:a288ae0fdd74:

#ifndef DATA_CLOCK_PAIR_H
#define DATA_CLOCK_PAIR_H
#include "mbed.h"
struct DataClockPair{
    PinName dataPin;
    PinName clockPin;
    DataClockPair(PinName clk, PinName dat):dataPin(dat), clockPin(clk){};
    DataClockPair(){};
};
#endif