Post Created date
double/float questions
kk6gm wrote: Simple exercise   float f1, f2, f3; f1 = __FLT_MAX__; f2 = __FLT_MAX__ - 1.0; f3 = f1 - f2; What is the value of f3? f3 is exactly 0. The value 1.0 is rounded...
Friday, 28 June 2019 - 16:08
double/float questions
Looks correct to me: https://www.wolframalpha.com/input/?i=sine(340282346638528859811704183484516925440+mod+(2*pi))   (3.4028235e38 is only an approximation for...
Friday, 28 June 2019 - 15:52
structure fails to update
Fianawarrior wrote: Okay, I have a little more information.   The function "hardware_write_block" works.  However the structure streamExt seems to be pointed at a...
Tuesday, 28 May 2019 - 20:50
can I ignore the following warning
AndreyT wrote: skotti wrote:works.   Formally, that's a violation of strict aliasing semantics. Today it "works", tomorrow it might stop working.   I read recently...
Saturday, 25 May 2019 - 00:42
longjmp() at the end of an ISR ? Or Goto+flag ?
skeeve wrote: BTW my recollection is that the way to handle register-trashing by longjmp is to call setjmp from a function that does nothing else but return the value....
Wednesday, 15 May 2019 - 18:10
Sampling rate + reconstruction question
I recommend that you watch https://xiph.org/video/vid2.shtml (go to 3:36, the "stairsteps" chapter).   By the way, we can't even hear the difference between a 20kHz sine...
Tuesday, 7 May 2019 - 18:03
Help with USART Atmega328
clawson wrote:AFAIK most terminals will send all of 0x01 to 0x1A for Ctrl-A to Ctrl-Z. If you are lucky you'll even find Ctrl-@ can be used for 0x00 and Esc has generally always...
Tuesday, 9 April 2019 - 23:12
whats the best way to implement a not gate.
From what I understand after reading a datasheet on the 555, the minimum of 0.4V on RESET means your circuit needs to pull the voltage on that pin to below 0.4V to guarantee that...
Friday, 1 March 2019 - 23:57
whats the best way to implement a not gate.
avr-mike wrote: A recent project (still unfinished)-: needed a few inverters so I used a 74LS04 I had in the parts bin.  The project uses a mega328 to control some 555 timers...
Friday, 1 March 2019 - 22:41
Check if two #defines define same register
avr-mike wrote: Try taking the address of the ports: #if ((&PORTB) != (&PORTMyPin))This should remove the * dereference in the macros.   --Mike   The...
Friday, 24 August 2018 - 20:53
Problem in reading data from MPU6050 using I2C protocol
Ah, I see there's an issue with signed values. Take the last sample: z1=58 z2=-120 Acc_z=-120 It looks like I2C_Read_Ack() returns data as a signed 8-bit value and not an...
Tuesday, 17 July 2018 - 23:14
Problem in reading data from MPU6050 using I2C protocol
Acc_x = (((int)I2C_Read_Ack()<<8) | (int)I2C_Read_Ack()); The compiler doesn't guarantee that the two I2C_Read_Ack()s will be called in any particular order. Either the...
Tuesday, 17 July 2018 - 21:54

Pages