avr-gcc-list
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [avr-gcc-list] Problem with difference between WinAVR versions - He


From: Peter Bozzay
Subject: Re: [avr-gcc-list] Problem with difference between WinAVR versions - Help please!
Date: Wed, 08 Sep 2004 12:43:22 +0200
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.4) Gecko/20030624 Netscape/7.1 (ax)

Hello,

I didn't get any answer to my question, what I've sent on 01.09. I had many problems with my mail server in last 2 weeks until yesterday, so I'm not sure, that nobody has any idea to help me, or only the mail system couldn't deliver the messages.
If somebody sent me something, please send me again.

Thank you,
Peter

[...]
that the problem must be only with get data from the bus in ow_get_bit
function, and finally I found this:

inline unsigned char ow_get_bit(void)
{
    unsigned char x=0,global_int_mem=0;
    if(inp(SREG)&0x80) { asm("cli"); global_int_mem=1; }
    ONE_WIRE_DQ_0();
    DELAY_OW_RECOVERY_TIME();
    ONE_WIRE_DQ_1();

    sbi(PORTB,2); // test

    DELAY_OW_READ_POS();

    cbi(PORTB,2); //test line 1

    //if( BIT_IS_SET(ow_pin_reg, ow_pin )) { x=1; } //original line
    if (bit_is_set(PINB,3)) {x=1;} //test line with same result

//    cbi(PORTB,2); //test line 2

    DELAY_US(ONE_WIRE_READ_SLOT_TIME_US-ONE_WIRE_READ_POSITION_US);

    if(global_int_mem) { asm("sei"); }
    return(x);
}

The generated .hex file is exactly the same when I use test line 2
instead of test line 1, so it seems, that the heart of the function is
missing from generated code!

I would be very happy if somebody can help me to look into the code,
and help to solve this problem, or can tell me more about possible
differences, what causes this.
[...]



reply via email to

[Prev in Thread] Current Thread [Next in Thread]