Silicon Laboratories Inc. Si5351A-B-GT I2C-PROGRAMMABLE ANY-FREQUENCY CMOS CLOCK GENERATOR
Dependents: clockGenerator Check_Si5351A_Clock_generator t2d Thing2Do ... more
Test program:
/users/kenjiArai/code/Check_Si5351A_Clock_generator/
Revision 4:8c63d15c8c2e, committed 2017-08-23
- Comitter:
- kenjiArai
- Date:
- Wed Aug 23 09:53:16 2017 +0000
- Parent:
- 3:af2d99cfb3f0
- Commit message:
- countermeasure for NonCopyable
Changed in this revision
si5351a.cpp | Show annotated file Show diff for this revision Revisions of this file |
si5351a.h | Show annotated file Show diff for this revision Revisions of this file |
diff -r af2d99cfb3f0 -r 8c63d15c8c2e si5351a.cpp --- a/si5351a.cpp Sat Jan 07 05:54:36 2017 +0000 +++ b/si5351a.cpp Wed Aug 23 09:53:16 2017 +0000 @@ -24,7 +24,7 @@ * http://mbed.org/users/kenjiArai/ * * Started: December 24th, 2016 - * Revised: January 7th, 2017 + * Revised: August 23rd, 2017 * */ @@ -48,7 +48,7 @@ uint8_t xtal_cap, uint8_t drive_current ) - : _i2c(p_sda, p_scl) + : _i2c_p(new I2C(p_sda, p_scl)), _i2c(*_i2c_p) { base_freq = base_clk_freq; x_cap = xtal_cap; @@ -2007,3 +2007,4 @@ #endif // +
diff -r af2d99cfb3f0 -r 8c63d15c8c2e si5351a.h --- a/si5351a.h Sat Jan 07 05:54:36 2017 +0000 +++ b/si5351a.h Wed Aug 23 09:53:16 2017 +0000 @@ -24,7 +24,7 @@ * http://mbed.org/users/kenjiArai/ * * Started: December 24th, 2016 - * Revised: January 7th, 2017 + * Revised: August 23rd, 2017 * */ @@ -238,7 +238,8 @@ void debug_example_clock(void); protected: - I2C _i2c; + I2C *_i2c_p; + I2C &_i2c; uint32_t gcd(uint32_t x, uint32_t y); void si5351_read(const uint8_t *buf);