Rev 498 | Rev 563 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | SVN | RSS feed
| Rev 498 | Rev 514 | ||
|---|---|---|---|
| Line 211... | Line 211... | ||
| 211 | uint32_t temperature; |
211 | uint32_t temperature; |
| 212 | Can_Message_t statusMsg; |
212 | Can_Message_t statusMsg; |
| 213 | statusMsg.RemoteFlag = 0; |
213 | statusMsg.RemoteFlag = 0; |
| 214 | statusMsg.ExtendedFlag = 1; |
214 | statusMsg.ExtendedFlag = 1; |
| 215 | statusMsg.DataLength = 4; |
215 | statusMsg.DataLength = 4; |
| 216 | statusMsg.Id = ( |
216 | statusMsg.Id = ((CAN_SNS << CAN_SHIFT_CLASS) | (SNS_TYPE_STATUS << CAN_SHIFT_SNS_TYPE) | (SNS_ID_RELAY_STATUS << CAN_SHIFT_SNS_ID) | (NODE_ID << CAN_SHIFT_SNS_SID)); |
| 217 | 217 | ||
| 218 | temperature = getTC1047temperature(); |
218 | temperature = getTC1047temperature(); |
| 219 | if( (int32_t)temperature >= FAILSAFE_TRESHOLD && !failsafe_flag ){ |
219 | if( (int32_t)temperature >= FAILSAFE_TRESHOLD && !failsafe_flag ){ |
| 220 | // Goto failsafe mode |
220 | // Goto failsafe mode |
| 221 | relayFailsafe(); |
221 | relayFailsafe(); |