Implement connection keycode logic (#25176)

This commit is contained in:
Joel Challis 2025-04-21 22:27:56 +01:00 committed by GitHub
parent ec324af22e
commit c7cb7ba976
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
15 changed files with 347 additions and 99 deletions

View file

@ -14,21 +14,17 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#pragma once
#include <stdint.h>
#include "connection.h"
enum outputs {
OUTPUT_AUTO,
// DEPRECATED - DO NOT USE
OUTPUT_NONE,
OUTPUT_USB,
OUTPUT_BLUETOOTH
};
#define OUTPUT_AUTO CONNECTION_HOST_AUTO
#define OUTPUT_NONE CONNECTION_HOST_NONE
#define OUTPUT_USB CONNECTION_HOST_USB
#define OUTPUT_BLUETOOTH CONNECTION_HOST_BLUETOOTH
#ifndef OUTPUT_DEFAULT
# define OUTPUT_DEFAULT OUTPUT_AUTO
#endif
#define set_output connection_set_host_noeeprom
#define where_to_send connection_get_host
#define auto_detect_output connection_auto_detect_host
void set_output(uint8_t output);
void set_output_user(uint8_t output);
uint8_t auto_detect_output(void);
uint8_t where_to_send(void);
void set_output_user(uint8_t output);