1
0
Fork 0
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:
kunalpowar 2014-05-03 21:35:09 +05:30
parent 42033238e2
commit 59958d7dfc
7 changed files with 163 additions and 4 deletions

View file

@ -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
}