#avr Logs

Jun 11 2019

#avr Calendar

12:03 AM day__ is now known as day
12:54 AM gsi__ is now known as gsi_
04:11 PM uniqdom: Hello, I'm Reading attiny85 datasheet, but I can't find what Fck is. Is it just the frequency of the clock?
04:11 PM uniqdom: I want to know the max I2C (TWI) clock speed. It says "Maximum frequency for SCL and SCK is fCK / 2"
04:11 PM uniqdom: but I cant belive that if I'm using a 20Mhz clock, the max spi speed will be 10Mhz. is it right?
04:20 PM cehteh: looks reasonable, where i woner how you would even handle data send at those speeds
04:20 PM cehteh: aka usially you use it much slower
04:23 PM cehteh: when you need data faster than some KHz then avr's are prolly not the best choice
04:30 PM uniqdom: cehteh: You are ritght. so attiny85 will probably handle fine 400khz for TWI (SPI), right?
04:30 PM cehteh: up to you, what you are doing
04:32 PM uniqdom: I will be reading an audio signal with an ADC and writing values to a LED driver over TWI (I2C).
04:33 PM uniqdom: I will have to do the maths, thanks cehteh
04:33 PM cehteh: adg will be the limiting factor
04:33 PM cehteh: adc
04:34 PM uniqdom: I will take a look at that, thanks
04:34 PM cehteh: can sample at 15khz 10 bit approx at most, when you reduce it to 8 bit then slgihtly faster
04:34 PM uniqdom: ok
04:35 PM cehteh: pretty lousy sound quality
04:37 PM cehteh: dont roget to add a lopwpass filter on your adc input
04:56 PM rue_mohr: uniqdom, did you find your answer?
04:58 PM uniqdom: I'm still reading and processing the datasheet.
05:00 PM uniqdom: I found exactly what cehteh said. I can easily drop the resouliton to 8 or 7 bits, as every increment will be translated to a LED. 8 bits will be 255 LED, and 7 bits = 127 LED.
05:04 PM vmt: wowzers, talk
05:06 PM cehteh: you mean some kind of bargraph?
05:07 PM cehteh: no idea what you are after but i think blinking leds in random order will yield the same results but vastly easier :D
05:11 PM uniqdom: yes like a bargraph
05:12 PM vmt: FFT?
05:12 PM uniqdom: a realtime volume monitor for audio.
05:12 PM vmt: oh, just volume
05:12 PM uniqdom: yes, just volume
05:12 PM vmt: well then i figure you really don't need 15 khz do you
05:13 PM cehteh: thats still needs more work than just displaing the waveform, and you can certainly reduce the sampling rate significantly
05:14 PM cehteh: depending on the exactness you want you need to do some math to actually determine the energy/pwoer level of the signal, wikipedia is your friend
05:16 PM uniqdom: thanks
05:16 PM vmt: yup, but you can get away with a super low sampling rate
05:16 PM vmt: unless you have superhuman eyes
05:16 PM uniqdom: yes. i know that eyes are really slow
05:17 PM cehteh: just add a really low lowpass filter to the input with very flat cutoff (the simplest one) .. integrate the sampling, you may even so a simple rolling oversampling then you get soem extra resolution (not that you need it)
05:18 PM cehteh: fitlers and oversampling add slight phase shift, but i guess that wont matter either
05:18 PM vmt: yep, don't really think so
05:19 PM uniqdom: thanks I really appreciate your help.
05:19 PM cehteh: actually this way you project becimes much simpler, a single attiny may be sufficient .. drive the led with some cascaded shift registers (with increment/decrement signals)
05:20 PM cehteh: looks easy peasy then
05:20 PM vmt: i'm kind of confused, is the output a mere row of 8 leds?
05:21 PM cehteh: he wants more
05:24 PM cehteh: bright/power leds or standard .. power leds will need some driver, uln2003 or so
05:25 PM vmt: need more than one
05:25 PM cehteh: anyway not my project, but looks really simple now, no need for i2c and multiple mcu's
05:26 PM vmt: myeah i never got that spi part
05:27 PM vmt: anyway, rue_mohr how's that widget toolkit coming along?
05:27 PM vmt: are we still stuck in the 80's with motif?
05:27 PM cehteh: lol
05:31 PM vmt: also rue_mohr your personal website says "bare metal", though i keep seeing that apache signature in the file index. last i heard apache runs on top of some mangy operating system like looserix or winblows, what's the story here?
07:05 PM davor_ is now known as davor
09:13 PM rue_mohr: hi
09:13 PM rue_mohr: It cascaded into needing to write a whole widget library and I dont know if I have time in my life
09:14 PM rue_mohr: vmt, heh that would be much more bare metal all right...