mirror of
https://github.com/kidoman/embd
synced 2025-07-03 03:47:33 +02:00
mcp3008: added package and samples for mcp3008 10-bit 8-channel adc
This commit is contained in:
parent
42033238e2
commit
59958d7dfc
7 changed files with 163 additions and 4 deletions
|
@ -29,6 +29,7 @@ func (s *spiDriver) Bus(mode, channel byte, speed, bpw, delay int) SPIBus {
|
|||
defer s.busMapLock.Unlock()
|
||||
|
||||
b := s.sbf(s.spiDevMinor, mode, channel, speed, bpw, delay, s.shouldInitialize, s.initializer)
|
||||
s.busMap = make(map[byte]SPIBus)
|
||||
s.busMap[channel] = b
|
||||
return b
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue