{"id":24011859,"url":"https://github.com/davbauer/storage-wrapper","last_synced_at":"2025-02-25T14:29:14.901Z","repository":{"id":153702098,"uuid":"478478409","full_name":"davbauer/storage-wrapper","owner":"davbauer","description":"Arduino Library for easily storing data on ESP8266","archived":false,"fork":false,"pushed_at":"2024-03-04T22:13:37.000Z","size":57,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-08T05:17:05.139Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/davbauer.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2022-04-06T08:52:40.000Z","updated_at":"2024-05-09T08:28:43.000Z","dependencies_parsed_at":null,"dependency_job_id":"e5edd577-d8d3-4e99-9802-d87fb9f5d405","html_url":"https://github.com/davbauer/storage-wrapper","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/davbauer%2Fstorage-wrapper","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/davbauer%2Fstorage-wrapper/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/davbauer%2Fstorage-wrapper/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/davbauer%2Fstorage-wrapper/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/davbauer","download_url":"https://codeload.github.com/davbauer/storage-wrapper/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240683314,"owners_count":19840679,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-01-08T05:17:14.215Z","updated_at":"2025-02-25T14:29:14.845Z","avatar_url":"https://github.com/davbauer.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ESP8266 Wrapper Library: Storage\nAn minimal Arduino wrapper library for making it easier to store or retrieve data for beginners.\n*Mostly based on https://github.com/PaulStoffregen/EEPROM*\n\n - **Importing the Library**\n\t+ I. Download the library [[.ZIP]](https://github.com/davbauer/storage-wrapper/archive/refs/heads/main.zip)\n\t+ II. Launch Arduino IDE and click *`[Sketch]`* *-\u003e* *`[Include Library]`* -\u003e *`[Add .ZIP Library...]`* to import the library\n- **Opening the example .ino file**\n\t+ I. In Arduino IDE click *`[File]`* *-\u003e* *`[Examples]`* -\u003e *`[Storage]`* -\u003e *`[basic]`* to open the example code\n- **Finishing up**\n\t+ I. Make sure the library EEPROM is installed, if its not already installed you can download it [here](https://github.com/PaulStoffregen/EEPROM) and follow the steps from above to import it\n\t\n---\n\t\n- **Available Methods**\n\n| Method-Name | Return-Type | What it does |\n| ----------- | ----------- | ----------- |\n| getStart()      \t\t\t| int       | return start byte position |\n| getEnd()   \t\t\t\t| int        | return end byte position |\n| getCache()   \t\t\t\t| String        | return cached store value |\n| clear()   \t\t\t\t| void        | clear data from store|\n| write(String/int/float/double)   \t| void        | write data to store |\n| readString()   \t\t\t| String        | read data as string |\n| read()   \t\t\t\t| String        | read data as string |\n| readInt()\t\t\t\t| int        | read data as int |\n| readDouble()   \t\t\t| double        | read data as double |\n\n---\n\n- **Example Code**\n\t\n\t```C++\n\t#include \u003cEEPROM.h\u003e // https://github.com/PaulStoffregen/EEPROM\n\t#include \u003cStorage.h\u003e // https://github.com/davbauer/Storage\n\n\tStorage my_object(0, 20); // Define your Storage objects and from which\n\tStorage other_obj(20, 30); // byte to start and end writing\n\n\tvoid setup(void) {\n\t  Serial.begin(115200);\n\t  Serial.println();\n\t  EEPROM.begin(512); // Set the amount of bytes of your EEPROM\n\n\t  my_object.write(\"Data to save\"); // Write data\n\t  String x = my_object.read(); // Read Data\n\t  Serial.println(x); // Prints (\"Data to save\")\n\n\t  other_obj.write(19.86);\n\t  int y = other_obj.readInt();\n\t  double z = other_obj.readDouble(); \n\n\t  Serial.println(y); // Prints (19)\n\t  Serial.println(z); // Prints (19.86)\n\t}\n\n\tvoid loop(void) {\n\t  delay(1000);\n\t}\n\t```\n\tFinal Output (Serial Monitor):\n\t\n\t``` text\n\tData to save\n\t19\n\t19.86\n\t```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdavbauer%2Fstorage-wrapper","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdavbauer%2Fstorage-wrapper","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdavbauer%2Fstorage-wrapper/lists"}