Skip to content

Commit

Permalink
fix: build for lns+
Browse files Browse the repository at this point in the history
  • Loading branch information
Edouard Merle committed Feb 2, 2022
1 parent 5b7615e commit 3aadbdd
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 11 deletions.
20 changes: 11 additions & 9 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -33,10 +33,10 @@ DEFINES += APPVERSION=\"$(APPVERSION)\"
COIN = xrp

#prepare hsm generation
ifeq ($(TARGET_NAME),TARGET_NANOX)
ICONNAME=img/nanox_app_$(COIN).gif
else
ifeq ($(TARGET_NAME),TARGET_NANOS)
ICONNAME=img/nanos_app_$(COIN).gif
else
ICONNAME=img/nanox_app_$(COIN).gif
endif


Expand Down Expand Up @@ -66,28 +66,30 @@ DEFINES += U2F_PROXY_MAGIC=\"XRP\"
DEFINES += HAVE_WEBUSB WEBUSB_URL_SIZE_B=0 WEBUSB_URL=""

ifeq ($(TARGET_NAME),TARGET_NANOX)
DEFINES += IO_SEPROXYHAL_BUFFER_SIZE_B=300
DEFINES += HAVE_BLE BLE_COMMAND_TIMEOUT_MS=2000
DEFINES += HAVE_BLE_APDU # basic ledger apdu transport over BLE
endif

ifeq ($(TARGET_NAME),TARGET_NANOS)
DEFINES += IO_SEPROXYHAL_BUFFER_SIZE_B=128
else
DEFINES += IO_SEPROXYHAL_BUFFER_SIZE_B=300
DEFINES += HAVE_GLO096
DEFINES += HAVE_BAGL BAGL_WIDTH=128 BAGL_HEIGHT=64
DEFINES += HAVE_BAGL_ELLIPSIS # long label truncation feature
DEFINES += HAVE_BAGL_FONT_OPEN_SANS_REGULAR_11PX
DEFINES += HAVE_BAGL_FONT_OPEN_SANS_EXTRABOLD_11PX
DEFINES += HAVE_BAGL_FONT_OPEN_SANS_LIGHT_16PX
else
DEFINES += IO_SEPROXYHAL_BUFFER_SIZE_B=128
endif

# Enabling debug PRINTF
DEBUG:=0
ifneq ($(DEBUG),0)

ifeq ($(TARGET_NAME),TARGET_NANOX)
DEFINES += HAVE_PRINTF PRINTF=mcu_usb_printf
else
ifeq ($(TARGET_NAME),TARGET_NANOS)
DEFINES += HAVE_PRINTF PRINTF=screen_printf
else
DEFINES += HAVE_PRINTF PRINTF=mcu_usb_printf
endif
else
DEFINES += PRINTF\(...\)=
Expand Down
2 changes: 1 addition & 1 deletion src/limitations.h
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
// Hardware dependent limits
// Ledger Nano X has 30K RAM
// Ledger Nano S has 4K RAM
#if defined(TARGET_NANOX)
#if defined(TARGET_NANOX) || defined(TARGET_NANOS2)

#define MAX_FIELD_COUNT 60
#define MAX_FIELD_LEN 1024
Expand Down
2 changes: 1 addition & 1 deletion src/ui/ux.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
#ifndef LEDGER_APP_XRP_UX_H
#define LEDGER_APP_XRP_UX_H

#if defined(TARGET_NANOX)
#if defined(TARGET_NANOX) || defined(TARGET_NANOS2)
#define DEV_SCREEN_H 64
#elif defined(TARGET_NANOS)
#define DEV_SCREEN_H 32
Expand Down

0 comments on commit 3aadbdd

Please sign in to comment.