I was approached at the start of May to find a way of automating the clock to start running after the opening number and to fast forward to the next “morning” during the penultimate number. In previous productions, a large clock with a conventional mechanical module was used. Strlcpy(tempIpAddress,defaultNetwork.“Departures: A Song Cycle” performed its fourth iteration of the show at Pleasance Islington in June 2016. Rand_string(_s, sizeof(_s)) ī_i = 0 ī_f = 0.00 ī = 's' īool createUsefulConfig() // load data from config.json or preset.json file and store in structures Load buttons information from config file Strlcpy(tempIpAddress,"10.0.0.1",sizeof(tempIpAddress)) ĭ(tempIpAddress) Rand_string(dests.name, sizeof(dests.name)) Load destination information from config file Network.oscListenPort = defaultNetwork.oscListenPort Rand_string(network.name, sizeof(network.name)) Strlcpy(tempIpAddress,().c_str(),sizeof(tempIpAddress)) Load network information from config file Rand_string(currentPresetHTML,sizeof(currentPresetHTML)) Int key = rand() % (int) (sizeof charset - 1) Serial.println("- failed to open file for writing") Ĭonst char charset = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789" Serial.println("error opening wokwi.txt!") īool saveConfig() // store data to config.json file and from config structuresĭynamicJsonDocument doc(CONFIG_FILE_SIZE) ĭoc = currentPresetHTML ĭoc = network.sourceIpAddress ĭoc = () ĭoc = () ĭoc = () ĭoc = () ĭoc = network.oscListenPort ĭoc = dmx.address ĭoc = settings.emiDebounce ĭoc = settings.ledBrightness ĭoc = mLedBrightness ĭoc = settings.buttonLedFunction įor (int i = 0 i < NUMBER_OF_DESTINATIONS i++)ĭoc = dests.name ĭoc = () ĭoc = stPort įor (int i = 0 i < NUMBER_OF_BUTTONS i++)ĭoc = bounce įor (int j = 0 j < NUMBER_OF_MESSAGES j++)ĭoc = ĭoc = ĭoc = įor (int k = 0 k < NUMBER_OF_ARGUMENTS k++)ĭoc = _s ĭoc = _i ĭoc = _f ĭoc = String() ĭoc = įile configFile = SD.open("/config.json", FILE_WRITE) Example of reading file from the card: Serial.println("Card initialization failed!") Struct Destination dests Ĭonst struct Network defaultNetwork = Int mode // stupid cannot assign to an enum as an int for some reason, so 0 = detect, 1 = dmx, 2 = osc, 3 = manual Int monitorValue // this is the value sent to the website and is 0-255 or 256 if not updated. Struct Version // structure to hold version number in various formatsĬhar dec // verison as string 00.00.00.00Ĭhar hex // version as string representation of hex 0x00000000īyte targetValue // this is to prevent sending data when dmx value has not changed.īyte readI2Cvalue // value read via I2C from DMX receiver chip - this may get passed to targetValue Uint32_t version // verison number of new files Struct Update // structure to store information received from checkURLĬhar status // status message returned from checkURLĬhar spiffs // path to new spiffs bin fileĬhar code // path to new code bin file #define LOG_BUF_SIZE 512 // char array for sending log messages as server side events.Įnum ButtonLedFunction // TODO: When this and I2C inputs are finalised need to update generate JSON.ino sketch. #define CONFIG_FILE_SIZE 100000 // see for calculation based on maximum size of JSON file.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |