Open AR-Tawil opened 3 years ago
@AR-Tawil
This can be, due to some optimisations bij Maxim. Try to download the latest esp-homekit repro here and compile it again. let me know if it worked out.
@AR-Tawil
btw. I saw that you have 7 different blinds repro's. I curious how you solved some coding issues and hardware issues. I really would like to have a peek at you code en know how you connected eg stepper etc. If you want we can do a private chat?
best regards, Achim
Hi Achim, I have updated the code to the latest esp-homekit repro, recompiled and updated my boards. I'm still having the same issue where the boarded requires resetting after ~2 days. As I mentioned in my previous message the code works perfectly until the reset is required. It seems to me that it depends on the number of sensor activations until a reset becomes needed?!! Thank you for your help.
@AR-Tawil
btw. I saw that you have 7 different blinds repro's. I curious how you solved some coding issues and hardware issues. I really would like to have a peek at you code en know how you connected eg stepper etc. If you want we can do a private chat?
best regards, Achim
Hi Achim, I'm learning and it's still a hit or miss exercise for me. Please find below the adapted stepper code I use for my blinds:
//#include
// ESP-12F(WeMos D1 mini)
const int NBSTEPS = 4095; const int STEPTIME = 900; int Step = 0; bool Clockwise = true;
int arrayDefault[4] = {0, 0, 0, 0}; void stepper(); void setDirection(); void test(int outArray[4]);
int stepsMatrix[8][4] = { {0, 0, 0, 1}, {0, 0, 1, 1}, {0, 0, 1, 0}, {0, 1, 1, 0}, {0, 1, 0, 0}, {1, 1, 0, 0}, {1, 0, 0, 0}, {1, 0, 0, 1} };
bool set_gpio() { gpio_enable(IN1, GPIO_OUTPUT); gpio_enable(IN2, GPIO_OUTPUT); gpio_enable(IN3, GPIO_OUTPUT); gpio_enable(IN4, GPIO_OUTPUT);
return true; }
void writeStep(int outArray[4]) {
test(outArray);
gpio_write(IN1, outArray[0]);
gpio_write(IN2, outArray[1]);
gpio_write(IN3, outArray[2]);
gpio_write(IN4, outArray[3]);
}
void setDirection() { (Clockwise == true) ? (Step++) : (Step--);
if (Step > 7) { Step = 0; } else if (Step < 0) { Step = 7; } }
void step() {
if ((Step >= 0) && (Step < 8)) { writeStep(stepsMatrix[Step]); } else { writeStep(arrayDefault); } setDirection(); }
void sleep(){ writeStep(arrayDefault); }
void reverse(){ Clockwise = !Clockwise; }
bool clockwise(){ return Clockwise; }
@AR-Tawil I saw that you already contacted Maxim https://github.com/maximkulkin/esp-homekit-demo/issues/376 and he noticed that you having trouble with your DHCP, is this issue solved? maybe you can have a look here: https://github.com/maximkulkin/esp-homekit/issues if they having the same problems as you?
Hi Achim, I have updated the code to the latest esp-homekit repro, recompiled and updated my boards. I'm still having the same issue where the boarded requires resetting after ~2 days. As I mentioned in my previous message the code works perfectly until the reset is required. It seems to me that it depends on the number of sensor activations until a reset becomes needed?!! Thank you for your help.
Hi Achim, I think DHCP is working better now. Do have any ideas or suggestions to fix the motion sensor board resetting issue? Thank you for your continuous support :)
@AR-Tawil do you have a log report to see what's happing when it resets?
@AchimPieters Is there a way to get log reports without using a direct USB connection to the device?
yes off course! open your terminal and type:
nc -kulnw0 45678
@AR-Tawil did you managed to fix your problem?
Hi Achim, I'm using your motion sensor code and it works perfectly. However, I noticed that the board needs resetting every two days or it will go into a No Responsive state?!!!
Thank you for your help AR Tawil