Update main.c add pigpen start and commands

beta-dw-pigpio
Alan Johnston 2 years ago committed by GitHub
parent 486b3b60e3
commit 9731ba3259
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -97,6 +97,13 @@ int main(int argc, char * argv[]) {
hab_mode = TRUE;
fprintf(stderr, "HAB mode is ON\n");
}
FILE * gpiod = popen("sudo pigpiod", "r"); // start gpiod
pclose(gpiod);
gpiod = popen("pigs m 19 5", "r"); // set PWM audio utput to GPIO 19 (pin 35)
pclose(gpiod);
gpiod = popen("pigs hc 13 12880000", "r"); // set clock to 12.88 MHz on GPIO 13 (pin 33)
pclose(gpiod);
// FILE * rpitx_stop = popen("sudo systemctl stop rpitx", "r");
FILE * rpitx_stop = popen("sudo systemctl restart rpitx", "r");

Loading…
Cancel
Save

Powered by TurnKey Linux.