|  | @@ -37,6 +37,20 @@ void testPrintBits()
 | 
											
												
													
														|  |      destroyByteBuffer(buffer);
 |  |      destroyByteBuffer(buffer);
 | 
											
												
													
														|  |  }
 |  |  }
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  | 
 |  | +void testGetId()
 | 
											
												
													
														|  | 
 |  | +{
 | 
											
												
													
														|  | 
 |  | +    unsigned long int id;
 | 
											
												
													
														|  | 
 |  | +    BYTE_BUFFER buffer;
 | 
											
												
													
														|  | 
 |  | +    char bytes[] = {0x28, 0x29, 0x01, 0x9a};
 | 
											
												
													
														|  | 
 |  | +    TEST_START;
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +    buffer = createByteBuffer();
 | 
											
												
													
														|  | 
 |  | +    pushBytes(&buffer, bytes, 4);
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +    id =  getHomeEasyId(buffer);
 | 
											
												
													
														|  | 
 |  | +    printf("Should 00A0A406\nGet %08X\n", id);
 | 
											
												
													
														|  | 
 |  | +}
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  |  void testEncode()
 |  |  void testEncode()
 | 
											
												
													
														|  |  {
 |  |  {
 | 
											
												
													
														|  |      unsigned char srcByte = 0x28;
 |  |      unsigned char srcByte = 0x28;
 | 
											
										
											
												
													
														|  | @@ -134,5 +148,7 @@ int main()
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  |      testHomeEasyCommand('D', 4, OFF);
 |  |      testHomeEasyCommand('D', 4, OFF);
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  | 
 |  | +    testGetId();
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  |      return 0;
 |  |      return 0;
 | 
											
												
													
														|  |  }
 |  |  }
 |