Skip to content

SmartStockRFID/smartstock-mobile

Repository files navigation

🌎 English | 🇧🇷 Português

RFID Reader App (Smart Stock Project)

Flutter Dart

Mobile application developed in Flutter for connecting with an RFID reader 🏷️
Designed to connect to an RFID reader via Bluetooth Low Energy (BLE) to optimize product counting and inventory.

💻 Getting Started

Follow these instructions to get a copy of the project up and running on your local machine for development and testing.

Prerequisites

Installation

  1. Clone the repository:

    git clone {repository-url-for-smartstock-mobile}
    cd smartstock-mobile
  2. Install dependencies:

    flutter pub get
  3. Configure environment variables:

    cp .env.example .env

Edit the .env file with the necessary settings.

  1. Run the application:

    flutter run
  2. Generate routing files: The project uses auto_route for navigation. During development, run the following command to generate the required files:

    dart run build_runner build

🛠️ Technologies Used

🏗️ Project Structure

The project follows a clean architecture, separating responsibilities into different layers:

lib/
├── app/
│   ├── bluetooth/      # Bluetooth connection logic and state machine
│   ├── config/         # API settings, dependencies, and environment variables
│   ├── data/           # Repositories and Data Transfer Objects (DTOs)
│   ├── domain/         # Entities and repository abstractions
│   ├── routing/        # Route configuration (AutoRoute)
│   ├── ui/             # Widgets, pages, providers (Riverpod), and themes
│   └── utils/          # Utility classes (e.g., logger)
└── main.dart           # Application entry point

👀 NOTES

  • To maintain a smoother transition between screens with the same AppBar style, I opted to use AutoTabs instead of Navigator.push(), avoiding the default effect that replaces the entire screen. However, as AutoTabs simulates navigation, the native back button ends up closing the app when in internal routes. I solved this using PopScope and SystemNavigator.pop() on Android. On iOS, this behavior will differ as the method is not supported. Edit: I believe that customizing the screen transition animation would make this unnecessary. However, as these screens currently share behaviors, it worked out perfectly.
  • Credits for the home screen background stock.png: https://www.pexels.com/photo/red-and-white-plastic-containers-on-shelf-3992851/ + https://pinetools.com/blur-image with the Stack Blur filter and radius 100 + https://imgonline.tools/pt/darken with a darkening factor of 15.
  • Changing the application icon on iOS needs adjustments to become functional. Also, due to the lack of compatible hardware, the iOS version of the application has not been tested.
  • Useful command: flutter build apk --obfuscate --split-debug-info=/output

📄 License

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

👨‍💻 About

This repository contains the implementation of the project's mobile application, developed by Ruan Macedo Santos.

Developed for the Smart Stock project within the EmbarcaTech Program.

About

Flutter app for real-time inventory tracking with RFID and BLE.

Topics

Resources

License

Stars

Watchers

Forks

Contributors

Languages