Altera_Forum
Honored Contributor
20 years agoSet a bit
hi
in my statement i declare static alt_u8 count ;//8 digital input static alt_u8 mem;# define bit0 count&0x01 //first bit of byte count # define fp mem&0x01 //first bit of byte mem # define true 1# define false 0 if ((bit0 ) & (!fp) { //.....make something fp=1; } if(!bit0) { fp=0; } //witn this software i would like to have e positive edge on my first button input but in during compilation i cannot assign bit0=1 or bit0=true i don't want to use rising edge capture but use this simple sw like usually i use in plc program Where do i make mistake ? How can i assign a value to bit0? thanks for ansuwers walter