Skip to content
Open
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
10 changes: 7 additions & 3 deletions example/ios/Podfile.lock
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
PODS:
- boost-for-react-native (1.63.0)
- CocoaAsyncSocket (7.6.5)
- DoubleConversion (1.1.6)
- FBLazyVector (0.63.2)
- FBReactNativeSpec (0.63.2):
Expand Down Expand Up @@ -245,7 +246,8 @@ PODS:
- React-Core (= 0.63.2)
- React-cxxreact (= 0.63.2)
- React-jsi (= 0.63.2)
- tillpos-rn-receipt-printer-utils (0.1.0):
- tillpos-rn-receipt-printer-utils (0.2.5):
- CocoaAsyncSocket
- React
- Yoga (1.14.0)

Expand Down Expand Up @@ -283,6 +285,7 @@ DEPENDENCIES:
SPEC REPOS:
trunk:
- boost-for-react-native
- CocoaAsyncSocket

EXTERNAL SOURCES:
DoubleConversion:
Expand Down Expand Up @@ -342,6 +345,7 @@ EXTERNAL SOURCES:

SPEC CHECKSUMS:
boost-for-react-native: 39c7adb57c4e60d6c5479dd8623128eb5b3f0f2c
CocoaAsyncSocket: 065fd1e645c7abab64f7a6a2007a48038fdc6a99
DoubleConversion: cde416483dac037923206447da6e1454df403714
FBLazyVector: 3ef4a7f62e7db01092f9d517d2ebc0d0677c4a37
FBReactNativeSpec: dc7fa9088f0f2a998503a352b0554d69a4391c5a
Expand All @@ -367,9 +371,9 @@ SPEC CHECKSUMS:
React-RCTText: 1b6773e776e4b33f90468c20fe3b16ca3e224bb8
React-RCTVibration: 4d2e726957f4087449739b595f107c0d4b6c2d2d
ReactCommon: a0a1edbebcac5e91338371b72ffc66aa822792ce
tillpos-rn-receipt-printer-utils: dbc6561b334bc48c8d2b73163ea1bcec35178d68
tillpos-rn-receipt-printer-utils: 43925ee131d5adace8f07f7b600d494398777011
Yoga: 7740b94929bbacbddda59bf115b5317e9a161598

PODFILE CHECKSUM: f48d21d8c903ca4bae3af77aec96d015293dce33

COCOAPODS: 1.10.1
COCOAPODS: 1.11.3
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,7 @@
ORGANIZATIONNAME = Facebook;
TargetAttributes = {
13B07F861A680F5B00A75B9A = {
DevelopmentTeam = RU463RBG8L;
LastSwiftMigration = 1110;
};
};
Expand Down Expand Up @@ -288,6 +289,8 @@
CLANG_ENABLE_MODULES = YES;
CURRENT_PROJECT_VERSION = 1;
DEAD_CODE_STRIPPING = NO;
DEVELOPMENT_TEAM = RU463RBG8L;
GCC_NO_COMMON_BLOCKS = NO;
INFOPLIST_FILE = ThermalReceiptPrinterExample/Info.plist;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
OTHER_CFLAGS = (
Expand Down Expand Up @@ -315,6 +318,8 @@
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CLANG_ENABLE_MODULES = YES;
CURRENT_PROJECT_VERSION = 1;
DEVELOPMENT_TEAM = RU463RBG8L;
GCC_NO_COMMON_BLOCKS = NO;
INFOPLIST_FILE = ThermalReceiptPrinterExample/Info.plist;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
OTHER_CFLAGS = (
Expand Down Expand Up @@ -367,7 +372,7 @@
ENABLE_TESTABILITY = YES;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_DYNAMIC_NO_PIC = NO;
GCC_NO_COMMON_BLOCKS = YES;
GCC_NO_COMMON_BLOCKS = NO;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PREPROCESSOR_DEFINITIONS = (
"DEBUG=1",
Expand Down Expand Up @@ -419,7 +424,7 @@
ENABLE_NS_ASSERTIONS = NO;
ENABLE_STRICT_OBJC_MSGSEND = YES;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_NO_COMMON_BLOCKS = YES;
GCC_NO_COMMON_BLOCKS = NO;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
GCC_WARN_UNDECLARED_SELECTOR = YES;
Expand Down
8 changes: 4 additions & 4 deletions example/src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ interface Printer {
port: number;
}
const PRINTERS: Array<Printer> = [
{ device_name: 'P1', host: '10.15.0.78', port: 9100 },
{ device_name: 'P2', host: '10.15.0.174', port: 9100 },
{ device_name: 'P1', host: '10.15.0.82', port: 9100 },
//{ device_name: 'P2', host: '10.15.0.174', port: 9100 },
];

let globalCount = 0;
Expand All @@ -25,7 +25,7 @@ export default function App() {
const buffer = Buffer.from(
globalCount + ' ::: minions minions minions \n \n '
);
for (let i = 0; i < 100; i++) {
for (let i = 0; i < 1; i++) {
let spont: number = Math.floor(Math.random() * PRINTERS.length);
const printer = PRINTERS[spont];
try {
Expand All @@ -34,7 +34,7 @@ export default function App() {
printer.host,
printer.port,
buffer,
PrinterBrand.EPSON,
PrinterBrand.SUNMI,
PrinterSeries.TM_M30
);
} catch (err) {
Expand Down
74 changes: 0 additions & 74 deletions ios/PrinterSDK/GenericPrinterSDK.h

This file was deleted.

Binary file removed ios/PrinterSDK/libGenericPrinterSDK.a
Binary file not shown.
5 changes: 0 additions & 5 deletions ios/RNBLEPrinter.m
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@

#import "RNBLEPrinter.h"
#import "adapters/epson/BLEPrinterEpsonAdapter.h"
#import "adapters/generic/BLEPrinterGenericAdapter.h"
#import "utils/NSDataAdditions.h"
#import "utils/EpsonUtils.h"

Expand Down Expand Up @@ -52,10 +51,6 @@ - (dispatch_queue_t)methodQueue
BLEPrinterEpsonAdapter *adapter = [BLEPrinterEpsonAdapter alloc];
[adapter connectAndSend:bdAddress printRawData:text epsonModel:number success:successCallback fail:errorCallback];
}
else {
BLEPrinterGenericAdapter *adapter = [BLEPrinterGenericAdapter alloc];
[adapter connectAndSend:bdAddress printRawData:text success:successCallback fail:errorCallback];
}
} @catch (NSException *exception) {
errorCallback(@[exception.reason]);
}
Expand Down
4 changes: 2 additions & 2 deletions ios/RNNetPrinter.m
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

#import "RNNetPrinter.h"
#import "adapters/epson/NetPrinterEpsonAdapter.h"
#import "adapters/generic/NetPrinterGenericAdapter.h"
#import "adapters/sunmi/NetPrinterSunmiAdapter.h"
#import "utils/NSDataAdditions.h"
#import "utils/EpsonUtils.h"

Expand Down Expand Up @@ -52,7 +52,7 @@ - (dispatch_queue_t)methodQueue
[adapter connectAndSend:host withPort:port printRawData:text epsonModel:number success:successCallback fail:errorCallback];
}
else {
NetPrinterGenericAdapter *adapter = [NetPrinterGenericAdapter alloc];
NetPrinterSunmiAdapter *adapter = [NetPrinterSunmiAdapter alloc];
[adapter connectAndSend:host withPort:port printRawData:text success:successCallback fail:errorCallback];
}
} @catch (NSException *exception) {
Expand Down
24 changes: 0 additions & 24 deletions ios/adapters/generic/BLEPrinterGenericAdapter.h

This file was deleted.

Loading