diff --git a/devices/tm1637/tm1637.go b/devices/tm1637/tm1637.go index 98e06ab..c428470 100644 --- a/devices/tm1637/tm1637.go +++ b/devices/tm1637/tm1637.go @@ -15,7 +15,7 @@ import ( "time" "github.com/google/periph/conn/gpio" - "github.com/google/periph/host" + "github.com/google/periph/host/cpu" ) // Clock converts time to a slice of bytes as segments. @@ -184,5 +184,5 @@ func (d *Dev) writeByte(b byte) (bool, error) { // sleep does a busy loop to act as fast as possible. func (d *Dev) sleepHalfCycle() { - host.Nanospin(clockHalfCycle) + cpu.Nanospin(clockHalfCycle) } diff --git a/experimental/devices/bitbang/i2c.go b/experimental/devices/bitbang/i2c.go index d0784ef..b49aeec 100644 --- a/experimental/devices/bitbang/i2c.go +++ b/experimental/devices/bitbang/i2c.go @@ -17,7 +17,7 @@ import ( "github.com/google/periph/conn/gpio" "github.com/google/periph/conn/i2c" - "github.com/google/periph/host" + "github.com/google/periph/host/cpu" ) // Use SkipAddr to skip the address from being sent. @@ -251,7 +251,7 @@ func (i *I2C) readByte() (byte, error) { // sleep does a busy loop to act as fast as possible. func (i *I2C) sleepHalfCycle() { - host.Nanospin(i.halfCycle) + cpu.Nanospin(i.halfCycle) } var _ i2c.Bus = &I2C{} diff --git a/experimental/devices/bitbang/spi.go b/experimental/devices/bitbang/spi.go index 51f8bd3..3dd13e2 100644 --- a/experimental/devices/bitbang/spi.go +++ b/experimental/devices/bitbang/spi.go @@ -19,7 +19,7 @@ import ( "github.com/google/periph/conn/gpio" "github.com/google/periph/conn/spi" - "github.com/google/periph/host" + "github.com/google/periph/host/cpu" ) // SPI represents a SPI master implemented as bit-banging on 3 or 4 GPIO pins. @@ -164,7 +164,7 @@ func NewSPI(clk, mosi gpio.PinOut, miso gpio.PinIn, cs gpio.PinOut, speedHz int6 // sleep does a busy loop to act as fast as possible. func (s *SPI) sleepHalfCycle() { - host.Nanospin(s.halfCycle) + cpu.Nanospin(s.halfCycle) } var _ spi.Conn = &SPI{}