rms_terminal_sdk 0.0.1 rms_terminal_sdk: ^0.0.1 copied to clipboard
Razer Merchant Service Terminal Dart TCP Connect
import 'dart:io';
import 'package:example/pages/homepage.dart';
import 'package:flutter/material.dart';
void main() async {
Socket socket = await Socket.connect('192.168.0.72', 8800);
runApp(MyApp(socket));
}
class MyApp extends StatelessWidget {
final Socket socket;
const MyApp(
this.socket, {Key? key}
) : super(key: key);
@override
Widget build(BuildContext context) {
return MaterialApp(
title: 'Flutter Demo',
theme: ThemeData(
primarySwatch: Colors.blue,
),
home: HomePage(socket: socket,),
);
}
}