Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: mbed mbed-rtos TextLCD
SETUP.hpp
00001 #ifndef SETUP_HPP//Header Guards Prevents Multiple includes 00002 #define SETUP_HPP 00003 00004 #include "stdio.h" 00005 #include "string.h" 00006 #include "mbed.h" 00007 #include "rtos.h" 00008 #include "TextLCD.h" 00009 #include "iostream" 00010 #include "rtos.h" 00011 #include "STEPPER_MOTOR.hpp" 00012 #include "Interface.hpp" 00013 00014 #define Debounce_Time 100//200 works fine 00015 INTERFACE INTERFACE; 00016 00017 //Digital Outputs 00018 DigitalOut led1(LED1); 00019 DigitalOut led2(LED2); 00020 00021 00022 //Function forward declarations 00023 void up_thread_function(); 00024 void down_thread_function(); 00025 void start_thread_function(); 00026 void function_thread_function(); 00027 void select_thread_function(); 00028 void Polling_thread_function(); 00029 //Thread Setups 00030 Thread polling_thread; 00031 Thread lcd_thread; 00032 Thread led_thread; 00033 Thread up_thread; 00034 Thread down_thread; 00035 Thread start_stop_thread; 00036 Thread function_thread; 00037 Thread select_thread; 00038 //LCD pin connections 00039 TextLCD lcd(D0,D1,D4,D5,D6,D7); // rs, e, d4-d7 00040 00041 //Serial Terminal setup for debugging 00042 Serial pc(USBTX, USBRX); //Define serial namespace so the serial comms can be printed to 00043 00044 #endif
Generated on Sat Jul 16 2022 17:32:46 by
1.7.2