An open API service indexing awesome lists of open source software.

https://github.com/noturlee/microbit-remote

A Kotlin application that controlls the MacqueenPlus V2 robot, using http requests, connecting via a wifi modul (ESP-01) connected on the robot.
https://github.com/noturlee/microbit-remote

esp01 http-requests kotlin remote-control

Last synced: about 1 month ago
JSON representation

A Kotlin application that controlls the MacqueenPlus V2 robot, using http requests, connecting via a wifi modul (ESP-01) connected on the robot.

Awesome Lists containing this project

README

          

![banner](https://github.com/user-attachments/assets/450a3c1c-e9cf-486c-9ed9-895174021d09)



# MacQueen Remote Control App

## Table of Contents

1. [Overview](#overview)
2. [Features](#features)
3. [Prerequisites](#prerequisites)
4. [Getting Started](#getting-started)
- [Setup the Android App](#setup-the-android-app)
- [Setup the MacQueen Plus v2 Robot](#setup-the-macqueen-plus-v2-robot)
5. [Code Explanation](#code-explanation)
6. [Troubleshooting](#troubleshooting)
7. [Roadmap](#roadmap)
8. [License](#license)

## Overview

The MacQueen Remote Control App is an Android application designed to control a MacQueen Plus v2 robot via WiFi. The app enables users to send movement commands to the robot, toggle its LED light, and activate its sound feature. It also provides haptic feedback (vibration) for each button press to enhance user interaction.

## Features

- **Robot Movement Control**: Move the robot forward, backward, left, or right.
- **LED Control**: Toggle the robot's LED light on and off.
- **Sound Control**: Activate the robot's sound feature.
- **Haptic Feedback**: Vibration feedback for each button press.

## Prerequisites

- Android device running API level 21 or higher.
- MacQueen Plus v2 robot connected to the same WiFi network as the Android device.

## Getting Started

### 1. Setup the Android App

1. **Clone the Repository**

```bash
git clone https://github.com/your-repository/macqueen-remote-control.git
cd macqueen-remote-control
2. **Open the Project**

Open the project in Android Studio.

3. **Update Network Configuration**

Ensure that your network_security_config.xml (referenced in AndroidManifest.xml) allows cleartext traffic if using HTTP:

```


192.168.4.1

```

4. **Add Permissions**

Add the following permissions to your AndroidManifest.xml:

```

```

5. ## Set up Microbit Code

Below is a link to my Code, it is important to understand the concepts of it and how it integrates and works with the Kotlin application, download and add this code to your microbit IDE:

https://makecode.microbit.org/S19893-69610-13178-56347

Technology Stack

> Tools and languages used.




Canva


Canva



Kotlin


Kotlin



React


React



TypeScript


TypeScript

6. **Build and Run**

Build and run the app on your Android device.

## Setup the MacQueen Plus v2 Robot

Ensure the MacQueen Plus v2 robot is connected to the WiFi network. The robot should be reachable at http://192.168.4.1/. Adjust the baseUrl in MainActivity if your robot's IP address is different, The wifi SSID for my code is ``Spaza-Wifi`` and the Password is ``I am speed``

## Code Explanation

- Network Requests: The app uses OkHttpClient to send HTTP requests to the robot for controlling various functions. Each button press triggers a specific command sent to the robot.

- Haptic Feedback: The app utilizes the Vibrator service to provide haptic feedback when a button is pressed, enhancing the user experience.

- Command Handling: The app handles commands to control robot movement, toggle the LED, and activate sound. The toggleLed method manages the LED state, switching it between on and off with each press.

- Kotlin App: The app is built using Kotlin and follows standard Android practices for handling UI interactions and network communication.

- MacQueen Plus v2 Robot: The MacQueen Plus v2 is a programmable robot that can be controlled over WiFi. It supports various commands for movement, LED control, and sound activation. Ensure the robot's firmware supports the commands sent by the app.

## Troubleshooting

- Robot Not Responding: Ensure the robot is connected to the same WiFi network as the Android device and that the IP address is correctly configured in the app.

- Vibration Not Working: Verify that the Android device has vibration hardware and that the vibration permission is correctly set in the app's manifest.

- Network Issues: Check network configurations and ensure that the network_security_config.xml permits cleartext traffic if using HTTP.

## Roadmap

| Phase | Description | Target Date |
|-------------|----------------------------------------------|-----------------|
| **Phase 1** | Initial Development and Setup | July 2024 |
| **Phase 2** | Core Features Implementation | July 2024 |
| **Phase 3** | Testing and Debugging | August 2024 |
| **Phase 4** | Final Review and Release | September 2024 |
| **Phase 5** | Post-Release Support and Updates | September 2024 |

## License

This project is licensed under the MIT License. See the LICENSE file for details.




# Happy Coding
image