allow user to set IR recv and IR send pin

This commit is contained in:
openshwprojects
2022-10-19 12:19:45 +02:00
parent d452cbe629
commit c0169983a4
4 changed files with 20 additions and 5 deletions

View File

@ -387,6 +387,10 @@ extern "C" void testmehere(){
unsigned char pin = 9;// PWM3/25
unsigned char txpin = 24;// PWM3/25
// allow user to change them
pin = PIN_FindPinIndexForRole(IOR_IRRecv,pin);
txpin = PIN_FindPinIndexForRole(IOR_IRSend,txpin);
if (ourReceiver){
IRrecv *temp = ourReceiver;
ourReceiver = NULL;

View File

@ -323,8 +323,8 @@ const char* htmlPinRoleNames[] = {
"BP1658CJ_DAT",
"BP1658CJ_CLK",
"PWM_n",
"error",
"error",
"IRRecv",
"IRSend",
"error",
"error",
"error",

View File

@ -41,6 +41,9 @@ enum IORole {
IOR_PWM_n,
IOR_IRRecv,
IOR_IRSend,
IOR_Total_Options,
};

View File

@ -40,7 +40,7 @@
<Tool
Name="VCCLCompilerTool"
Optimization="0"
PreprocessorDefinitions="WINDOWS"
PreprocessorDefinitions="WINDOWS;PLATFORM_BK7231T"
MinimalRebuild="true"
BasicRuntimeChecks="3"
RuntimeLibrary="3"
@ -736,7 +736,7 @@
>
</File>
<File
RelativePath=".\src\new_http.h"
RelativePath=".\src\httpserver\new_http.h"
>
<FileConfiguration
Name="Release|Win32"
@ -748,7 +748,7 @@
</FileConfiguration>
</File>
<File
RelativePath=".\src\httpserver\new_http.h"
RelativePath=".\src\new_http.h"
>
<FileConfiguration
Name="Release|Win32"
@ -875,6 +875,14 @@
RelativePath=".\src\driver\drv_cse7766.c"
>
</File>
<File
RelativePath=".\src\driver\drv_ir.cpp"
>
</File>
<File
RelativePath=".\src\driver\drv_ir.h"
>
</File>
<File
RelativePath=".\src\driver\drv_local.h"
>