 b9a766d909
			
		
	
	
		b9a766d909
		
	
	
	
	
		
			
			* Added support for running applications from SD card (FAPs - Flipper Application Packages) * Added plugin_dist target for fbt to build FAPs * All apps of type FlipperAppType.EXTERNAL and FlipperAppType.PLUGIN are built as FAPs by default * Updated VSCode configuration for new fbt features - re-deploy stock configuration to use them * Added debugging support for FAPs with fbt debug & VSCode * Added public firmware API with automated versioning Co-authored-by: hedger <hedger@users.noreply.github.com> Co-authored-by: SG <who.just.the.doctor@gmail.com> Co-authored-by: あく <alleteam@gmail.com>
		
			
				
	
	
		
			39 lines
		
	
	
		
			1.0 KiB
		
	
	
	
		
			C
		
	
	
	
	
	
			
		
		
	
	
			39 lines
		
	
	
		
			1.0 KiB
		
	
	
	
		
			C
		
	
	
	
	
	
| #include "infrared_remote_button.h"
 | |
| 
 | |
| #include <stdlib.h>
 | |
| #include <m-string.h>
 | |
| 
 | |
| struct InfraredRemoteButton {
 | |
|     string_t name;
 | |
|     InfraredSignal* signal;
 | |
| };
 | |
| 
 | |
| InfraredRemoteButton* infrared_remote_button_alloc() {
 | |
|     InfraredRemoteButton* button = malloc(sizeof(InfraredRemoteButton));
 | |
|     string_init(button->name);
 | |
|     button->signal = infrared_signal_alloc();
 | |
|     return button;
 | |
| }
 | |
| 
 | |
| void infrared_remote_button_free(InfraredRemoteButton* button) {
 | |
|     string_clear(button->name);
 | |
|     infrared_signal_free(button->signal);
 | |
|     free(button);
 | |
| }
 | |
| 
 | |
| void infrared_remote_button_set_name(InfraredRemoteButton* button, const char* name) {
 | |
|     string_set_str(button->name, name);
 | |
| }
 | |
| 
 | |
| const char* infrared_remote_button_get_name(InfraredRemoteButton* button) {
 | |
|     return string_get_cstr(button->name);
 | |
| }
 | |
| 
 | |
| void infrared_remote_button_set_signal(InfraredRemoteButton* button, InfraredSignal* signal) {
 | |
|     infrared_signal_set_signal(button->signal, signal);
 | |
| }
 | |
| 
 | |
| InfraredSignal* infrared_remote_button_get_signal(InfraredRemoteButton* button) {
 | |
|     return button->signal;
 | |
| }
 |