Changeset 10698 for firmware/FSC
- Timestamp:
- 05/13/11 12:39:16 (14 years ago)
- Location:
- firmware/FSC/src
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
firmware/FSC/src/FSC_eth_with_user_interface.c
r10697 r10698 59 59 60 60 for ( U08 i=0; i < (RESISTANCE_CHANNELS/8); ++i ) { 61 ad7719_enables[i]=0x 00;61 ad7719_enables[i]=0xFF; 62 62 ad7719_channels_ready[i]=0; 63 63 } … … 101 101 102 102 if (check_if_adc_measurement_done()) { 103 telegram_start(); 104 w5100_set_TX(adc_values, ADC_VALUES_LEN_BYTE); 105 103 106 104 if(adc_print_endless){ 107 105 usart_write_str((pU08)"V|"); 108 106 usart_write_U32(sec ,8); 109 107 print_adc_nicely(false,true); 108 telegram_start(); 109 w5100_set_TX((U08*) adc_values, ADC_VALUES_LEN_BYTE); 110 110 111 reset_voltage_done(); 111 112 } else … … 113 114 adc_values_printed = true; 114 115 print_adc_nicely(true,true); 116 telegram_start(); 117 w5100_set_TX((U08*) adc_values, ADC_VALUES_LEN_BYTE); 118 115 119 } 116 120 } 117 121 118 122 if (check_if_ad7719_measurement_done()) { 119 telegram_start();120 w5100_set_TX(ad7719_values, AD7719_VALUES_LEN_BYTE);121 123 122 124 if(ad7719_print_endless){ … … 125 127 print_ad7719_nicely(false,true); 126 128 reset_resistance_done(); 129 telegram_start(); 130 w5100_set_TX((U08*) ad7719_values, AD7719_VALUES_LEN_BYTE); 131 127 132 } else 128 133 if ( !ad7719_values_printed) { 129 134 ad7719_values_printed = true; 130 135 print_ad7719_nicely(true,true); 136 telegram_start(); 137 w5100_set_TX((U08*) ad7719_values, AD7719_VALUES_LEN_BYTE); 138 131 139 } 132 140 } -
firmware/FSC/src/w5100_spi_interface.c
r10697 r10698 300 300 // returns number of words, transmitted into TX - buffer. 301 301 U16 w5100_set_TX(U08* string, U16 NumBytes) { 302 302 303 U16 freesize = get_S0_TX_FSR(); 303 304 if (freesize == 0) … … 305 306 return 0; 306 307 } 308 usart_write_str((U08*)"sending via eth: with pointer:"); 309 usart_write_U16_hex(string); 310 usart_write_str((U08*)" #of bytes: "); 311 usart_write_U16(NumBytes,4 ); 312 usart_write_char(' \n'); 307 313 308 314 U16 last_TX_write_pointer = get_S0_TX_WR(); … … 312 318 313 319 U16 upper_size, lower_size; 320 /* 314 321 if (NumBytes > ETH_WRITE_BUFFER_SIZE) 315 322 { … … 320 327 return 0; 321 328 } 322 else if ( freesize < NumBytes ) 329 else */ 330 if ( freesize < NumBytes ) 323 331 { 324 332 NumBytes = freesize;
Note:
See TracChangeset
for help on using the changeset viewer.