Author Topic: Question about using ATTINY to drive a BH2220 D/A Converter  (Read 1424 times)

0 Members and 1 Guest are viewing this topic.

Offline optoisolatedTopic starter

  • Supporter
  • ****
  • Posts: 71
  • Country: au
  • If in doubt, it's probably user error.
    • OpsBros
Question about using ATTINY to drive a BH2220 D/A Converter
« on: April 27, 2017, 09:21:00 am »
Hi all, I am trying to get my head around using an ATTINY to drive a BH2220 DAC, and based on what I am reading in the datasheet (http://rohmfs.rohm.com/en/products/databook/datasheet/ic/data_converter/dac/bh2219fvm-e.pdf) am concerned that the ATTINY simply doesn't have the capability to drive this at the speeds required. I thought about using the SPI interface, even though it used an 11-bit register, I assumed there would be capability to use that, (serves me right for not checking) but if I'm reading the ROHM datasheet right, it suggests the high-load, rising edge clock set requires MODE 3 SPI which the ATTINY 44 can't do. I thought about bit-banging it, but i'm not sure I can get it to output fast enough on the GPIO pins of the ATTINY to get it to work and wanted to know if anyone had attempted something similiar, or could advise if I am approaching the problem incorrectly.
Any feedback would be appreciated  :-+
 

Online Ian.M

  • Super Contributor
  • ***
  • Posts: 12881
Re: Question about using ATTINY to drive a BH2220 D/A Converter
« Reply #1 on: April 27, 2017, 09:48:38 am »
I don't see any requirement for either a minimum CLK frequency or for CLK to idle high in that datasheet (even though the timing diagrams show it idling high).
Try sending 16 bits of data in SPI mode 1 and see what happens.
I would expect the high nibble of the first byte to be ignored and the low nibble taken as channel select, with the next byte used for data.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf