Notice. New forum software under development. It's going to miss a few functions and look a bit ugly for a while, but I'm working on it full time now as the old forum was too unstable. Couple days, all good. If you notice any issues, please contact me.
|
Forum Index : Microcontroller and PC projects : I2C / I2C2 ... how to address PicoMite slave devices.??
Author | Message | ||||
kermess Regular Member Joined: 04/04/2013 Location: SpainPosts: 45 |
Hi. I am interested in knowing how to assign addresses to various PicoMites so that I can converse with them. Master will be a PicoMite and slaves will also be PicoMites. Thank you very much. David. From Barcelona. |
||||
lizby Guru Joined: 17/05/2016 Location: United StatesPosts: 3008 |
From the Picomite manual: I2C SLAVE See Appendix B PicoMite, Armmite F4, SensorKits, MMBasic Hardware, Games, etc. on fruitoftheshed |
||||
Mixtel90 Guru Joined: 05/10/2019 Location: United KingdomPosts: 5705 |
Also see the "Getting Started With the Micromite" book on Geoff's site. Page 70 onward gives an in depth example. If it's a purely local connection between the PicoMites you can use any addresses, but if other things are on the I2C bus you must avoid those addresses. Mick Zilog Inside! nascom.info for Nascom & Gemini Preliminary MMBasic docs & my PCB designs |
||||
Tinine Guru Joined: 30/03/2016 Location: United KingdomPosts: 1646 |
Because it is possible, doesn't mean that it's the best solution. I prefer... Craig |
||||
Mixtel90 Guru Joined: 05/10/2019 Location: United KingdomPosts: 5705 |
... and I'd prefer several PicoMites in a 10MHz serial SPI ring (doesn't need CS pins or addresses), but that wouldn't answer the original question either. ;) Mick Zilog Inside! nascom.info for Nascom & Gemini Preliminary MMBasic docs & my PCB designs |
||||
Tinine Guru Joined: 30/03/2016 Location: United KingdomPosts: 1646 |
Data not buffered....processor would be tied up servicing the SPI. Craig |
||||
Mixtel90 Guru Joined: 05/10/2019 Location: United KingdomPosts: 5705 |
That's only because MMBasic doesn't support SPI slave mode. It's always a master. A slave won't produce the clock (it will read it) and will have an interrupt when it's receive buffer is ready. Like I said, it's what I'd *prefer*. Doesn't mean it's possible in MMBasic. :) Mick Zilog Inside! nascom.info for Nascom & Gemini Preliminary MMBasic docs & my PCB designs |
||||
Volhout Guru Joined: 05/03/2018 Location: NetherlandsPosts: 3490 |
I2C is nice, but it is a local bus. Unreliable over distance. But picomites interconnect through I2C may give you a way to distribute algorithms over multiple cores. A kind of multitasking. Like a power analyzer use 1 pico to measure 3 phase voltage on its 3 adc and process (fft, rms) And anothe to do the same for the 3 phase current. And a 3rd to provide user interface. The system would use I2C to communicate and 1 separate sync signal to synchronize the 2 measurement picos. Edited 2022-04-30 20:47 by Volhout PicomiteVGA PETSCII ROBOTS |
||||
Print this page |