{"id":18251680,"url":"https://github.com/32teeth/kaimana-redux","last_synced_at":"2026-01-21T14:35:02.314Z","repository":{"id":147777498,"uuid":"74499898","full_name":"32teeth/kaimana-redux","owner":"32teeth","description":null,"archived":false,"fork":false,"pushed_at":"2017-09-07T13:09:46.000Z","size":362,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-08T20:48:44.071Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":null,"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/32teeth.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,"publiccode":null,"codemeta":null}},"created_at":"2016-11-22T18:02:35.000Z","updated_at":"2016-11-22T18:02:35.000Z","dependencies_parsed_at":"2023-06-26T00:08:39.652Z","dependency_job_id":null,"html_url":"https://github.com/32teeth/kaimana-redux","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/32teeth/kaimana-redux","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/32teeth%2Fkaimana-redux","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/32teeth%2Fkaimana-redux/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/32teeth%2Fkaimana-redux/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/32teeth%2Fkaimana-redux/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/32teeth","download_url":"https://codeload.github.com/32teeth/kaimana-redux/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/32teeth%2Fkaimana-redux/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28634839,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-21T04:47:28.174Z","status":"ssl_error","status_checked_at":"2026-01-21T04:47:22.943Z","response_time":86,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":"2024-11-05T09:48:13.560Z","updated_at":"2026-01-21T14:35:02.298Z","avatar_url":"https://github.com/32teeth.png","language":null,"funding_links":[],"categories":[],"sub_categories":[],"readme":"# Kaimana Redux\n\nthis is a public repo for a **basic version** of a mash up between the slimmed down **[moledcule](http://moledcule.club)** version of original Kaimana code\n\nthe intent behind this code is to normalize and introduce efficiencies to the existing Kaimana code base\n\nin the **examples folder** you will find a few sketches *(currently there is only 'basic')*\n\n-----\n\n## basic example\nfiles:\n* basic.ino *(main program)*\n* Comm.h *(all comm port utilities)*\n* Pins.h *(input output functionality)*\n* Structures.h *(structs definitions for program)*\n* Utils.h *(transformation utilities)*\n\n-----\n\n### basic.ino\nhow are pins mapped to the Kainana device\n```\n                                      +-----+\n         +----[PWR]-------------------| USB |--+\n         |                            +-----+  |\n         |         GND/RST2  [ ][ ]            |\n         |       MOSI2/SCK2  [ ][ ]  A5/SCL[ ] |\n         |          5V/MISO2 [ ][ ]  A4/SDA[ ] |\n         |                             AREF[ ] |\n         |                              GND[ ] |\n         | [ ]N/C                    SCK/13[ ] |\n         | [ ]IOREF                 MISO/12[ ] | Kick 3\n         | [ ]RST                   MOSI/11[ ]~| Down\n         | [ ]3V3    +---+               10[ ]~| Start\n         | [ ]5v    -|   |-               9[ ]~| Select\n         | [ ]GND   -| A |-               8[ ] | Home\n         | [ ]GND   -| 3 |-                    |\n         | [ ]Vin   -| 2 |-               7[ ] |\n         |          -| U |-               6[ ]~| Kick 4\n      Up | [ ]A0    -| 4 |-               5[ ]~|\n    Left | [ ]A1    -|   |-               4[ ] | Kick 1\n   Right | [ ]A2     +---+           INT1/3[ ]~| Punch 1\n  Kick 2 | [ ]A3                     INT0/2[ ] | Punch 2\n         | [ ]A4/SDA  RST SCK MISO     TX\u003e1[ ] | Punch 4\n    Data | [ ]A5/SCL  [ ] [ ] [ ]      RX\u003c0[ ] | Punch 3\n         |            [ ] [ ] [ ]              |\n         |  UNO_R3    GND MOSI 5V  ____________/\n         \\_______________________/\n\n```\nthis file is pretty damn clean and easy to read, that was the whole intent\n\n-----\n\n### Comm.h\n\nthis header file provide access and functionality to the Serial port on the arduino.\n\n**note** *the original designers of the Kaimana board used digital pins 0 (RX) and 1 (TX) for button IO.*\n\n\n#### startComm\n```\n/*\n** @method startComm\n** @desc start serial port if DEBUG is defined\n*/\nstartComm()\n```\n\n#### listenComm\n```\n/*\n** @method listenComm\n** @desc listen to serial port if DEBUG is defined\n*/\nlistenComm()\n```\n\n#### printComm\n```\n/*\n** @method printComm\n** @param str (String)\n** @desc print string to serial port if DEBUG is defined\n*/\nprintComm(str)\n```\n-----\n\n### Pins.h\nthis file contains the assignement of the IO struct to specific pins, their input, state, type, and last toggled timestamp\n\nand example of the struct is as such\n\n```\n// definition\ntypedef struct {\n\tuint8_t pin;\t\t\t// the pin for the input button\n\tuint8_t mode;\t\t\t// INPUT | OUTPUT\n\tuint8_t state\t\t\t// HIGH | LOW \n\tString type;\t\t\t// \"a\" | \"d\"\n\tunsigned long changed;\t// last changed timestamp\n} IO;\t\n\n// declaration example\nIO FIRST_PUNCH = {1, INPUT, HIGH, \"d\", 0};\n```\n\n#### printPins\n```\n/*\n** @method printPins\n** @desc create string buffer and dump to serial\n*/\nprintPins\n```\n\n### setPins\n```\n/*\n** @method setPins\n** @desc itterate through structs and invoke setPins\n*/\nsetPins\n```\n\n### getPins\n```\n/*\n** @method getPins\n** @desc itterate through structs and set appropriate structs\n*/\ngetPins\n```\n\n-----\n\n## Structure.h\nnothing really exciting here, simply a place for all of the programs structs to live\n\n-----\n## Utils.h\n\n### getBin\nconvert an interger into a binary string\n```\n/*\n** @method getBin\n** @param number (int)\n** @return result {String} \n** @desc converts the decimal param to binary string\n*/\nString getBin(int number)\n```\n\n### getLong\nconvert an interger array into a long\n```\n/*\n** @method getLong\n** @desc convert rgb values to long int\n** @param r {int} red value\n** @param g {int} red value\n** @param b {int} red value\n** @return {long}\n*/\nlong getLong(char r, char g, char b)\n```\n\n### getLong\nconvert an hexadecimal into a long\n```\n/*\n** @method getLong\n** @desc convert hex values to long\n** @param color {hex} hex value represantation of color\n** @return {long}\n*/\nlong getLong(String color)\n```\n\n### getRGB\nconvert long into rgb array\n```\n/*\n** @method getRGB\n** @desc convert long values to rgb array\n** @param color {long} long value represantation of color\n** @return {int*}\n*/\nint* getRGB(unsigned long color)\n```\n\n### getRGB\nconvert long into the passed struct pointer\n```\n/*\n** @method getRGB\n** @desc convert long values to rgb array\n** @param color {long} long value represantation of color\n** @return {int*}\n*/\nRGB getRGB(RGB\u0026 rgb, unsigned long color)\n```\n\n### getHEX\nconvert long into hexadecimal\n```\n/*\n** @method getHEX\n** @desc convert long values to rgb array\n** @param color {long} long value represantation of color\n** @return {String}\n*/\nString getHEX(unsigned long color)\n```\n\n### getHEX\nconvert int array into hexadecimal\n```\n/*\n** @method getHEX\n** @desc convert long values to rgb array\n** @param color {long} long value represantation of color\n** @return {String}\n*/\nString getHEX(int* rgb)\n```\n\nwith the Utils.h you can do crazy stuff like this\n\n```\n// you like purple\n#define purple_hex \"ffff00\"\n\n// you want to conver the above hex into an RGB struct\nRGB purple_struct;\n\n// you can nest utilities\ngetGRB(purple_struct, getLong(purple_hex))\n\n// purple.r is now 255\n// purple.g is now 0\n// purple.b is now 255\n\n```\n\n\n\n# compiler\n\nonce you have your files ready, you can test the compiler (without the Arduino IDE), yup, that's right, we built a ***[compiler as a service](http://compiler.moledcule.club)*** just for this functionality\n\nsimply visit our  ***[compiler as a service](http://compiler.moledcule.club/#/compiler)*** drag and drop your files and off you go.\n\nif there is a bug, we'll let you know what went wrong.\n\n### drag and drop\n#### add your files to the drop area\n\u003cimg src=\"reference/step1.png\" width=\"50%\"\u003e\n\n\n\n#### see your files\n\u003cimg src=\"reference/step2.png\" width=\"50%\"\u003e\n\n#### create a collection\n\u003cimg src=\"reference/step3.png\" width=\"50%\"\u003e\n\n#### copmile your files\n##### upon success you can download your ***hex*** file\n\u003cimg src=\"reference/step4.png\" width=\"50%\"\u003e\n\n\n#### if there is an error, you'll see the red icon\n\u003cimg src=\"reference/step5.png\" width=\"50%\"\u003e\n\n#### clicking the red icon, you'll see the error\n\u003cimg src=\"reference/step6.png\" width=\"50%\"\u003e\n\n-----\n\n***have fun, play safe***\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F32teeth%2Fkaimana-redux","html_url":"https://awesome.ecosyste.ms/projects/github.com%2F32teeth%2Fkaimana-redux","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F32teeth%2Fkaimana-redux/lists"}