Initial commit
This commit is contained in:
		
							
								
								
									
										25
									
								
								306-controller_interface.X/app/blcontrol.c
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										25
									
								
								306-controller_interface.X/app/blcontrol.c
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,25 @@ | ||||
| #include "blcontrol.h" | ||||
| #include "../mcc_generated_files/mcc.h" | ||||
| #include "../factory/factory.h" | ||||
| //private methods | ||||
|  | ||||
| void BLControl_init(BLControl* me) | ||||
| { | ||||
|     //nothing to do yet | ||||
| } | ||||
|  | ||||
| void BLControl_onButton(void * me, uint8_t buttonId, bool pressed) | ||||
| { | ||||
|     BLControl* realMe = (BLControl*)me; | ||||
|     if (buttonId == BID) | ||||
|     { | ||||
|         if (pressed)     | ||||
|         { | ||||
|             LED_on(l()); | ||||
|         } | ||||
|         else | ||||
|         { | ||||
|             LED_off(l()); | ||||
|         } | ||||
|     } | ||||
| } | ||||
		Reference in New Issue
	
	Block a user