Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions GpioController/appsettings.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@
}
},
"Authorization": {
"Enabled": false,
"Enabled": true,
"AuthorizedEmails": [
"yourEmail@gmail.com"
],
"AuthorizedCorsOrigins": ["http://yourProductionWebsite:3000", "http://localhost:3000"]
"AuthorizedCorsOrigins": ["https://pinpanda-api.com"]
},
"Filters": {
"AllowOnlyTheseChipsets": [],
Expand Down
Binary file modified Installation/linux-arm64/pinpanda-api-1.4.deb
Binary file not shown.
Binary file modified Installation/linux-x64/pinpanda-api-1.4.deb
Binary file not shown.
92 changes: 68 additions & 24 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
</a>

<h3 align="center">The Cutest Way to Control Your GPIOs</h3>
<h3 align="center">https://pinpanda-api.com/</h3>

<p align="center">
<br />
Expand All @@ -40,8 +41,9 @@
<li><a href="#installation">Installation</a></li>
</ul>
</li>
<li><a href="#usage">Usage</a></li>
<li><a href="#settings">Optional Settings</a></li>
<li><a href="#online-usage">Online Usage</a></li>
<li><a href="#local-usage">Local Usage</a></li>
<li><a href="#advanced-settings">Settings</a></li>
<li><a href="#roadmap">Roadmap</a></li>
<li><a href="#contributing">Contributing</a></li>
<li><a href="#license">License</a></li>
Expand All @@ -53,25 +55,19 @@

<!-- ABOUT THE PROJECT -->
## About The Project
PinPanda-Api is here to make your DIY projects a breeze! No more getting tangled in chipset architectures or stressing over the quirks of different board manufacturers. Just dive in and get started fast!
PinPanda-API is a easily installable REST API that allows you to interact with GPIOs online at https://pinpanda-api.com/ or locally. No coding required.
It makes any DIY project a breeze. No more getting involved with chipset architectures or worrying about different board manufacturers. Just dive in and get started fast!


No coding required. Just follow the <a href="#installation">installation steps</a> to get quick access to GPIO functionality.
Follow the <a href="#installation">installation steps</a> to get started.
<p align="right">(<a href="#readme-top">back to top</a>)</p>

<!-- GETTING STARTED -->
## Getting Started

### Prerequisites
- Have curl installed:

```sh
sudo apt-get install curl
```



- Have a Debian/Ubuntu Linux Distro installed on your board.
- Have an Ubuntu / Debian Distro installed on your board.
<details>
<summary>More Info</summary>
<br/>Follow your boards documentation if you haven't already. <br/>
Expand All @@ -84,6 +80,12 @@ No coding required. Just follow the <a href="#installation">installation steps</
<details>
<summary>Optional Installs</summary>

- Install curl:

```sh
sudo apt-get install curl
```

- Install crontab if you want to automatically run the API on startup.

```sh
Expand All @@ -94,10 +96,13 @@ No coding required. Just follow the <a href="#installation">installation steps</
### Installation
1. Run the debian package installation
```sh
sudo curl https://raw.githubusercontent.com/SparkyCoder/PinPanda-Api/refs/heads/main/Installation/Install.sh | bash
sudo curl https://pinpanda-api.com/Install.sh | bash
```



<details>
<summary>Optional Steps</summary>
<summary>(Optional) Have PinPanda-API launch on Reboot</summary>

1. To start the API on reboot:
```sh
Expand All @@ -109,12 +114,23 @@ No coding required. Just follow the <a href="#installation">installation steps</
```
</details>

<details>
<summary>(Optional, but Required for Online Control) Grant Access</summary>

1. Go into the appsettings.json file and update the `AuthorizedEmails` value with the email address you'll be logging in with. <br/>
<img src="/images/step0.png" alt="Logo" width="400" height="550">
2. At this point, the API is only available on your local intranet. To make it accessible from [PinPada-API](https://pinpanda-api.com) you'll need to give it access. To do this login to your router or firewall and add a rule. Allow TCP traffic for the IP of your SBC Development Board and the port the API is running on (Default is 3005). It should look something like this: <br/>
<img src="/images/step1.png" alt="Logo" width="270" height="600"><br/>


</details>

<p align="right">(<a href="#readme-top">back to top</a>)</p>



<!-- USAGE EXAMPLES -->
## Usage
## Local-Usage
[Postman Documentation](https://documenter.getpostman.com/view/2447338/2sB2cSiPcM)
<details>
<summary>GET /sbc/chipsets/gpios</summary>
Expand Down Expand Up @@ -215,11 +231,25 @@ No coding required. Just follow the <a href="#installation">installation steps</
```
</details>

## Online-Usage
pre-requisite:
1 - Navigate to the [PinPanda-API website](https://pinpanda-api.com) <br/>
<img src="/images/step2.png" alt="Logo" width="270" height="600">
<br/><br/><br/>2 - Login with Google <br/>
<img src="/images/step3.png" alt="Logo" width="270" height="600">
<br/><br/><br/>3 - Visit [whatismyipaddress](https://whatismyipaddress.com/) to find and copy your public IP address. This is how [PinPanda-API](https://pinpanda-api.com) will communicate securely with your board. <br/>
<img src="/images/step4.png" alt="Logo" width="270" height="600">
<br/><br/><br/>4 - Enter in that IPv4 address you just copied, followed by the port your API is running on. (Default is 3005) <br/>
<img src="/images/step5.png" alt="Logo" width="270" height="600">
<br/><br/><br/>5 - Add a new request and start interacting with the GPIOs on your board. <br/>
<img src="/images/step6.png" alt="Logo" width="270" height="600">
<br/><br/><br/>6 - Send requests to turn off / on your GPIO pins. Use the red stop button to cancel all active requests. That's it!<br/>


## Optional Settings

To see your API settings, refer to the [AppSettings](https://github.com/SparkyCoder/PinPanda-API/blob/main/GpioController/appsettings.json) file in your optional installs directory: `/opt/pinpanda-api-1.4`.<br/>
All the settings below are optional. PinPanda should work without changing any of these.
## Advanced-Settings

To update your API settings, refer to the [AppSettings](https://github.com/SparkyCoder/PinPanda-API/blob/main/GpioController/appsettings.json) file in your optional installs directory: `/opt/pinpanda-api-1.4`.

#### Kestral:
- `Kestral:Endpoints:Http:Url` - This is the endpoint your API will bind to. <br/>
Expand Down Expand Up @@ -255,15 +285,17 @@ All the settings below are optional. PinPanda should work without changing any o
<!-- ROADMAP -->
## Roadmap

- [x] add to list available GPIOs
- [x] Add endpoint to list available GPIOs
- [x] Add endpoint to Update GPIO state
- [x] Add endpoint to read GPIO values
- [x] Add settings to make usage easier (filter, security, configuration, etc...)
- [x] Add secure endpoints for Google JWT Auth
- [x] Create UI to interface with individual boards
- [x] Add communication between SBC and [PinPanda-API](https://pinpanda-api.com)
- [x] Add documentation
- [ ] Add additional chipset architectures
- [ ] linux-muscl-64
- [ ] linux-arm
- [ ] Add UI for interacting with API
- [ ] Update Install

See the [open issues](https://github.com/SparkyCoder/PinPanda-API/issues) for a full list of proposed features (and known issues).

Expand All @@ -275,7 +307,19 @@ See the [open issues](https://github.com/SparkyCoder/PinPanda-API/issues) for a
## Contributing

If you have a suggestion that would make this API better, please fork the repo and create a pull request. You can also simply open an issue with the tag "enhancement".
<br/><br/><b><h3>Don't forget to give the project a star! Thanks again!</h3><b/>
<br/><br/>


Contribute in other ways. Sponserships are solely responsible for keeping this project running. If you found this repo useful please consider becoming a sponsor.

[![Sponsor](https://img.shields.io/badge/Sponsor-💖-ff69b4?style=for-the-badge)](https://github.com/sponsors/SparkyCoder)


<b><h4>Don't forget to give the project a star! </h3><b/>



<b><h4>Thank you! </h3><b/>

<p align="right">(<a href="#readme-top">back to top</a>)</p>

Expand All @@ -284,7 +328,7 @@ If you have a suggestion that would make this API better, please fork the repo a
<!-- LICENSE -->
## License

See [LICENSE](https://github.com/SparkyCoder/PinPanda-API/blob/main/LICENSE) for more information.
See [LICENSE.txt](https://github.com/SparkyCoder/PinPanda-API/blob/main/LICENSE) for more information.

<p align="right">(<a href="#readme-top">back to top</a>)</p>

Expand All @@ -311,7 +355,7 @@ Project Link: [Gpio Controller Api](https://github.com/SparkyCoder/PinPanda-API)
[issues-shield]: https://img.shields.io/github/issues/SparkyCoder/PinPanda-Api.svg?style=for-the-badge
[issues-url]: https://github.com/SparkyCoder/PinPanda-API/issues
[license-shield]: https://img.shields.io/github/license/SparkyCoder/PinPanda-Api.svg?style=for-the-badge
[license-url]: https://github.com/SparkyCoder/PinPanda-API/blob/master/LICENSE
[license-url]: https://github.com/SparkyCoder/PinPanda-API/blob/master/LICENSE.txt
[product-screenshot]: images/screenshot.png
[linkedin-shield]: https://img.shields.io/badge/-LinkedIn-black.svg?style=for-the-badge&logo=linkedin&colorB=555
[linkedin-url]: https://www.linkedin.com/in/david-kobuszewski-60315428
Expand Down
Binary file added images/step0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/step1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/step2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/step3.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/step4.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/step5.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/step6.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading