remote server color doesn't look correct - emacs

I use ssh to login remote server quite often and on the server I'll use tools like emacs, git, tmux, etc. I noticed that the color on the remote server is very ugly compared with local machine. Especially for emacs, I want to use solarize theme but on the remote server it doesn't really show the correct color.
Does anyone know how to improve the color on remote server?
I am using item2 and when running infocmp I got the following results:
# Reconstructed via infocmp from file: /opt/sw/python/20201012/anaconda3/envs/i38/share/terminfo/x/xterm-256color
xterm-256color|xterm with 256 colors,
am, bce, ccc, km, mc5i, mir, msgr, npc, xenl,
colors#0x100, cols#80, it#8, lines#24, pairs#0x10000,
acsc=``aaffggiijjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~,
bel=^G, blink=\E[5m, bold=\E[1m, cbt=\E[Z, civis=\E[?25l,
clear=\E[H\E[2J, cnorm=\E[?12l\E[?25h, cr=\r,
csr=\E[%i%p1%d;%p2%dr, cub=\E[%p1%dD, cub1=^H,
cud=\E[%p1%dB, cud1=\n, cuf=\E[%p1%dC, cuf1=\E[C,
cup=\E[%i%p1%d;%p2%dH, cuu=\E[%p1%dA, cuu1=\E[A,
cvvis=\E[?12;25h, dch=\E[%p1%dP, dch1=\E[P, dim=\E[2m,
dl=\E[%p1%dM, dl1=\E[M, ech=\E[%p1%dX, ed=\E[J, el=\E[K,
el1=\E[1K, flash=\E[?5h$<100/>\E[?5l, home=\E[H,
hpa=\E[%i%p1%dG, ht=^I, hts=\EH, ich=\E[%p1%d#,
il=\E[%p1%dL, il1=\E[L, ind=\n, indn=\E[%p1%dS,
initc=\E]4;%p1%d;rgb\:%p2%{255}%*%{1000}%/%2.2X/%p3%{255}%*%{1000}%/%2.2X/%p4%{255}%*%{1000}%/%2.2X\E\\,
invis=\E[8m, is2=\E[!p\E[?3;4l\E[4l\E>, kDC=\E[3;2~,
kEND=\E[1;2F, kHOM=\E[1;2H, kIC=\E[2;2~, kLFT=\E[1;2D,
kNXT=\E[6;2~, kPRV=\E[5;2~, kRIT=\E[1;2C, ka1=\EOw,
ka3=\EOy, kb2=\EOu, kbs=^H, kc1=\EOq, kc3=\EOs, kcbt=\E[Z,
kcub1=\EOD, kcud1=\EOB, kcuf1=\EOC, kcuu1=\EOA,
kdch1=\E[3~, kend=\EOF, kent=\EOM, kf1=\EOP, kf10=\E[21~,
kf11=\E[23~, kf12=\E[24~, kf13=\E[1;2P, kf14=\E[1;2Q,
kf15=\E[1;2R, kf16=\E[1;2S, kf17=\E[15;2~, kf18=\E[17;2~,
kf19=\E[18;2~, kf2=\EOQ, kf20=\E[19;2~, kf21=\E[20;2~,
kf22=\E[21;2~, kf23=\E[23;2~, kf24=\E[24;2~,
kf25=\E[1;5P, kf26=\E[1;5Q, kf27=\E[1;5R, kf28=\E[1;5S,
kf29=\E[15;5~, kf3=\EOR, kf30=\E[17;5~, kf31=\E[18;5~,
kf32=\E[19;5~, kf33=\E[20;5~, kf34=\E[21;5~,
kf35=\E[23;5~, kf36=\E[24;5~, kf37=\E[1;6P, kf38=\E[1;6Q,
kf39=\E[1;6R, kf4=\EOS, kf40=\E[1;6S, kf41=\E[15;6~,
kf42=\E[17;6~, kf43=\E[18;6~, kf44=\E[19;6~,
kf45=\E[20;6~, kf46=\E[21;6~, kf47=\E[23;6~,
kf48=\E[24;6~, kf49=\E[1;3P, kf5=\E[15~, kf50=\E[1;3Q,
kf51=\E[1;3R, kf52=\E[1;3S, kf53=\E[15;3~, kf54=\E[17;3~,
kf55=\E[18;3~, kf56=\E[19;3~, kf57=\E[20;3~,
kf58=\E[21;3~, kf59=\E[23;3~, kf6=\E[17~, kf60=\E[24;3~,
kf61=\E[1;4P, kf62=\E[1;4Q, kf63=\E[1;4R, kf7=\E[18~,
kf8=\E[19~, kf9=\E[20~, khome=\EOH, kich1=\E[2~,
kind=\E[1;2B, kmous=\E[<, knp=\E[6~, kpp=\E[5~,
kri=\E[1;2A, mc0=\E[i, mc4=\E[4i, mc5=\E[5i, meml=\El,
memu=\Em, mgc=\E[?69l, oc=\E]104\007, op=\E[39;49m, rc=\E8,
rep=%p1%c\E[%p2%{1}%-%db, rev=\E[7m, ri=\EM,
rin=\E[%p1%dT, ritm=\E[23m, rmacs=\E(B, rmam=\E[?7l,
rmcup=\E[?1049l\E[23;0;0t, rmir=\E[4l, rmkx=\E[?1l\E>,
rmm=\E[?1034l, rmso=\E[27m, rmul=\E[24m,
rs1=\Ec\E]104\007, rs2=\E[!p\E[?3;4l\E[4l\E>, sc=\E7,
setab=\E[%?%p1%{8}%<%t4%p1%d%e%p1%{16}%<%t10%p1%{8}%-%d%e48;5;%p1%d%;m,
setaf=\E[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;m,
sgr=%?%p9%t\E(0%e\E(B%;\E[0%?%p6%t;1%;%?%p5%t;2%;%?%p2%t;4%;%?%p1%p3%|%t;7%;%?%p4%t;5%;%?%p7%t;8%;m,
sgr0=\E(B\E[m, sitm=\E[3m, smacs=\E(0, smam=\E[?7h,
smcup=\E[?1049h\E[22;0;0t,
smglr=\E[?69h\E[%i%p1%d;%p2%ds, smir=\E[4h,
smkx=\E[?1h\E=, smm=\E[?1034h, smso=\E[7m, smul=\E[4m,
tbc=\E[3g, u6=\E[%i%d;%dR, u7=\E[6n,
u8=\E[?%[;0123456789]c, u9=\E[c, vpa=\E[%i%p1%dd,

Make sure your terminal type is set to xterm-256color in Preferences > Profiles > Terminal > Report Terminal Type.
https://iterm2.com/faq.html
Q: How do I get 256 color mode working in vim?
A: The recommended way is to set your terminal type to xterm-256color in Preferences > Profiles > Terminal > Report Terminal Type. You may also need to put set background=light or set background=dark in your .vimrc.

Related

Flutter ZEBRA mobile printer ZQ521 stuck when print multiple image(ZPL)

Im developing a Flutter app that need to print selected image with mobile printer (ZEBRA ZQ521).
Generated ZPL string are works on http://labelary.com/viewer.html.
But mobile printer (ZQ521) totally stuck when printing (sometimes goes smooth).
error : Caused by: java.io.IOException: Bluetooth LE Write timed out
is it my ZPL string are too long? please help.
my zpl stringļ¼š
^XA
~DGimg5.GRF,5126,22, FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFE
FFFFFFFFFFFFFFFFFFFFFFFFFE7FFFFFFFFFFFFFFFFE
FFFFFFFFFFFFFFFFFFFFCFC78607FFFFFFFFFFFFFFFE
FFFFFFFFFFFFFFFFFFFF0FFCB303FFFFFFFFFFFFFFFE
FFFFFFFFFFFFFFFFFFFF3FFC33807FFFFFFFFFFFFFFE
FFFFFFFFFFFFFFFFFFFE06338C803FFFFFC7FFFFFFFE
FFFFFFFFFFFFFFFFFFFE7FF3CFE01FFFFFE1FFFFFFFE
FFFFFFFFFFFFFFFFFFFC380FFFC01FFFFFF1FFFFFFFE
FFFFFFFFFFFFFFFFFFFCF338FFE00FFFFFF87FFFFFFE
FFFFFFFFFFFFFFFFFFFFFBF03FFFFFFFFFFC3FFFFFFE
FFFFFFFFFFFFFFFFFFC1F1F03FFFFFFFFFFC1FFFFFFE
FFFFFFFFFFFFFFFFFC000000187C19FFFFF80FFFFFFE
FFFFFFFFFFFFFFC000000000000000001CFFFFFFFFFE
FFFFFFFFFFFFFEC00000000000000000000FFFFFFFFE
FFFFFFFFFFFFFF80000000000000000000007FFFFFFE
FFFFFFFFFFFFE0000000000000000000000003FFFFFE
FFFFFFFFFFFFF80000000000000000000000007FFFFE
FFFFFFFFFFFFFFF000000000000000000000007FFFFE
FFFFFFFFFFFFFFE000000000000000000000003FFFFE
FFFFFFFFFFFFFFC000000000000000000000003FFFFE
FFFFFFFFFFFFFF8000000000000000000000003FFFFE
FFFFFFFFFFFFF80000000000000000000000007FFFFE
FFFFFFFFFFFFFFFF00000000000000000000007FFFFE
FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFC000007FFFFE
FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF50007FFFFE
FFFFFFFFFFFFFFFF8100000000000FE7FFFFF07FFFFE
FFFFFFFFFFFF80000000000000000400000407FFFFFE
FFFFFFFFFFC000040300000000000C00000000FFFFFE
FFFFFFFFFFE1000006000000000000000000007FFFFE
FFFFFFFFFFC0000404400000000008000000007FFFFE
FFFFFFFFFFC0000000D80000000000000000003FFFFE
FFFFFFFFFFC0000000F80000000000000000003FFFFE
FFFFFFFFFFC91000007A0000000000000000003FFFFE
FFFFFFFFFFC91000009E0000000000000000003FFFFE
FFFFFFFFFFCF0000009E0000000000000000003FFFFE
FFFFFFFFFFCF000001B60000000000000000001FFFFE
FFFFFFFFFFCF000000970000080001000000001FFFFE
FFFFFFFFFFEF2000029F0000080001000000001FFFFE
FFFFFFFFFFFF2000039F0000080001001000001FFFFE
FFFFFFFFFFFEA00003530000080001003000001FFFFE
FFFFFFFFFFFF2000061B8000080009001800001FFFFE
FFFFFFFFFFEF2000060BA000080008001800001FFFFE
FFFFFFFFFFFF200006038000080008001800001FFFFE
FFFFFFFFFFFFA00002038000080008000000001FFFFE
FFFFFFFFFFFFE00000038000080005000000001FFFFE
FFFFFFFFFFFFE00000438000080005000000001FFFFE
FFFFFFFFFFFFE00000618040280025000000001FFFFE
FFFFFFFFFFFFE0000047B040280025C00000001FFFFE
FFFFFFFFFFFFE40001251040280025000000001FFFFE
FFFFFFFFFFFFE40001A51040280025000000001FFFFE
FFFFFFFFFFFFE40001A53040388024000000003FFFFE
FFFFFFFFFFFFE40005A41040388004000000003FFFFE
FFFFFFFFFFFFF00007A41040388004000000003FFFFE
FFFFFFFFFFFFF00007BD1040348004600000003FFFFE
FFFFFFFFFFFFFE0007BDBB4064801760000001FFFFFE
FFFFFFFFFFFFFF900735BFC0648ED778000083FFFFFE
FFFFFFFFFFFFF7FFFFFFFFC06880877FFEFFDFFFFFFE
FFFFFFFFFFFFFFF803FFFFFFFFFFFFFFFFFFFFFFFFFE
FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFE
FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFBFFFFE
FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFBFFFFE
FFFFF8FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFE07FFFFE
FFFFFFE3FFFFFFFFFFFFFFFFFFFFFFFFFFFD007FFFFE
FFFFFC7FFFFFFF83EFFFFFFFFFFFFFFFD911017FFFFE
FFF017FFFFFFFF8007FFFFFE75FFFFFFC201007FFFFE
FFFFFFFFFFFFFF0003FFFF581429FFFFC200007FFFFE
FFFFFFFFFFFFFF8003F87700102BFFFFC200007FFFFE
FFFFFFFFFFFFFFD803F033001021FFFEC20200FFFFFE
FFFFFFFFFFCFFF8003FF3B001001FFFEC20700FFFFFE
FFFFFFFFF80FFFD803FF3F10100FFFFEC20300FFFFFE
FFFFFFFF000FFFFF03F89F101001FFFF431100FFFFFE
FFFFFFF00007FFF803F89E50300BFFFF63B900FFFFFE
FFFFFC000007FFFD63F91F10210FFFFDD3BB01FFFFFE
FFFF00000007FFFFEBF81E00210BFFFDD3FF05FFFFFE
FFE000000007FFFFEBF89E00210FFFFFD3FE05FFFFFE
F00000000007FFFFE3FD9E00210FFFFFFFFE0DFFFFFE
000000000007FFFEE7FF9E50210FFFFFFFFE0BFFFFFE
000000000007FFFFEFFF9E50210FFFFFFFFE0BFFFFFE
000000000007FFFFF7FF9E50210FFFFFA7FF1BFFFFFE
000000000007FFFFF7DF9E40210FFFFFB7FF1BFFFFFE
000000000007FFFFEBFDAC20200FFFFFFBFE57FFFFFE
000000000007FFFFFBFDEC22200FFFFFFBFF7FFFFFFE
000000000007FFFFFFF5FC22200FFFFFFFFFFFFFFFFE
000000000007FFFFFFF5FC62201FFFFFFFFFFFFFFFFE
000000000007FFFFFFF5FC62201FFFFFFFFEFFFFFFFE
000000000003FFFFFFFDFC0A205FFFFFFFFEFFFFFFFE
000000000003FFFFFFFDFC4A205FFFFFFFFFFFFFFFFE
000000000003FFFFFFFDFDE2207FFFFFFFFFFFFFFFFE
000000000007FFFFFFFFEEDA606FFFFFDFFDDFFFFFFE
000000000003FFFFFFFFFEDA603FFFFFFFFFFFFFFFFE
000000000003FFFFFFFFFFDA603FFFFFFFFFFFFFFFFE
000000000003FFFFFFFFFFDA603FFFFFFFFFFFFFFFFE
000000000003FFFFFFFFDFDA603FFFFFBFFFFFFFFFFE
000000000003FFFFFFFFFEDA629FFFFFFFFFFFFFFFFE
000000000003FFFFFFFFFEDA46DFFFFFFFF7FFFFFFFE
000000000003FFFFFFFFFFFA67DFFFFFFFF7FFFFFFFE
000000000003FFFFFFFFFFFC57FFFFFFFFFFFFFFFFFE
000000000003FFFFFFFFFFFED7FFFFFFFFFFFFFFFFFE
000000000003FFFFFFFFFFFFD3FFFFFFFFEFFFFFFFFE
000000000001FFFFFFFFFFFFD3FFFFFFFFFFFFFFFFFE
000000000001FFFFFFFFFFFFD77FFFFFFFFFFFFFFFFE
000000000001FFFFFFFFFFFE5F7FFFFFFFBFFFFFFFFE
000000000001FFFFFFFFFFFE5DFFFFFFFFBFFFFFFFFE
000000000001FFFFFFFFFFFFC9FFFFFFFFFFFFFFFFFE
000000000001FFFFFFFFFFFD5FFFFFFFFFFFFFFFFFFE
000000000001FFFFFFFFFFFFDFFFFFFFFFFFFFFFFFFE
000000000001FFFFFFFFFFFFCFFFFFFFFFFFFFFFFFFE
000000000001FFFFFFFFFFFFCFFFFFFFFEFFFFFFFFFE
000000000001FFFFFFFFFFFFCF7FFFFFFFFFFFFFFFFE
000000000001FFFFFFFFFFFFDFFFFFFFFFFFFFFFFFFE
000000000001FFFFFFFFFFFFDFFFFFFFFFFFFFFFFFFE
000000000000FFFFFFFFFFFFDFFFFFFFFFFFFFFFFFFE
000000000000FFFFFFFFFFFFDBFFFFFFFFF07FFFFFFE
000000000000FFFFFFFFFFFFFFFFFFFFFFF007FFFFFE
000000000000FFFFFFFFFFFFFFFFFFFFFFE0003FFFFE
000000000000FFFFFFFFFFFFFFFFFFFFFF800003FFFE
000000000000FFFFFFFFFFFFFFFFFFFFFF8000003FFE
000000000000FFFFFFFFFFFFFFFFFFFFFF00000003FE
000000000000FFFFFFFFFFFFFFFFFFFFFE00000003FE
000000000000FFFFFFFFFFFFFFFFFFFFF800000003FE
000000000000FFFFFFFFFFFFFFFFFFFFE400000003FE
000000000000FFFFFFFFFFFFFFFFFFFFE000000003FE
000000000000FFFFFFFFFFFFFFFFFFFFC000000007FE
000000000000FFFFFFFFFFFFFFFFFFFFC000000007FE
000000000000FFFFFFFFFFFFFFFFFFFF8000000007FE
000000000000FFFFFFFFFFFFFFFFFFFF0000000027FE
000000000000FFFFFFFFFFFFFFFFFFFE0000000027FE
000000000000FFFFFFFFFFFFFFFFFFF60000000067FE
0000000000007F07FFFFFFFFFFFFFFFC00000000FFFE
0000000000007F03FFFFFFFFFFFFFFF0000000009FFE
0000000000007E00FE7EFFFFFFFFFFE0000000019FFE
0000000000007C00387F7FFFFFFFFF0000000000BFFE
0000000000007C00001FEFFFFFFFFE00000000027FFE
0000000000007C000003FFFFFFFFF000000000067FFE
0000000000007C000000FFFFFFFF8000000000007FFE
000000000000780000001FFFFFF8000000000000FFFE
0000000000007000000007FFFE20000000000002FFFE
0000000000007200000000FE0000000000000003FFFE
00000000000060000000043F0000000000000003FFFE
000000000001F20000001C0FE000000000000007FFFE
000000000001CF0000007081FC00000000000007FFFE
000000000006BF600000E0007F0000000000000FFFFE
000000000006EFF0000300000FE000000000001FFFFE
0000000000017FFC0006000003F800000000001FFFFE
000000000003FFFF00180000087E00000000003FFFFE
0000000000017FFB80600000000F80000000003FFFFE
0000000000005FFA00C000000007F0000000007FFFFE
0000000000003FE8020000000000F8000000007FFFFE
0000000000000FF00C00000000003E00000000FFFFFE
00000000000003C01000000000000F80000000FFFFFE
000000000300000060000000000003E0000003FFFFFE
0000000003000001C1010000000000F8000013FFBFFE
0000000006000003000000000000007C000003FFFFFE
000000001800000E000000000000001E000007FFFFFE
0000000030000038000000000000000F80000FFFFFFE
00000000E00000600000000000000003C0000FFFFFFE
00000001803801C00000000000000001A0001FFFFFFE
0000000600FF0700000000000000000060003FFFFFFE
0000000EFFEFFC00000000000000000030003FFFFFFE
00000031FFFFF00000000000000000001C007FFFFFFE
000000C09FFFFC0000000000000000000E007FEFFFFE
000003FFFFFFFF8000000000000000000700FFFFFFFC
000007FFFFFFFFE000000000000000000781FFFFFFFC
00001CFFFFFFFFF0000000000000000003C1FFFFFFFE
000031FFFFFFFFFC000000000000000003C3FFFFFFFE
0000E7FFFFFFFFFE000000000000000001E3FFFFFFFC
00038FFFFFFFFFFF000000000000000008F7FFFFFFFC
000E1FFFFFFFFFFFC00000000000000005F7FFFFFFFE
00183FFFFFFFFFFFE000000000000000007FFEFFFFFE
00707FFFFFFFFFF7F800000000000000007FFFFFFFFE
01C07FFFFFFFFFE7F800000000000000007FF5FBFFFE
0700FFFFFFFFFFE7FE00000000000000007FF0FFFFFE
0C00FFFFFFFFFFF9FF00000000000000007FE83FFFFE
30007FFFFFFFFF00FF00000000000000007FE05FFFFE
E0007FFFFFFFFF40FF8000000000000000FFD07FFFF6
C0007FFFFFFFFF01FFC000000000000000FFE07FFFF6
80003FFFFFFFFFE27FE000000000000000FFC0FFFFEE
80001FFFFFFFFC383FE006000000000001FFC13FFFEE
00001FFFFFFFFC393FF000000000000001FFE017FFDE
00008FFFFFFFFFF3BFF800000000000003FFFC06FFDE
00000FFFFFFFFFFFFFF800000000000007FFFE06FFDE
000003FFFFFFFFFFFFFC0000000000000FFFFE0DFFDE
000000FFFFFFCFFFFFFC0000000000000FFFFF0DFFBE
0000000FFFFFFFFFFFFC0000000000001FDFFFCDFFBE
00000203FFFFE7FFFFFF8040000000003F9FFFFBFFBE
00000000FFFFF7FFFFFF00C0000000003F1FFFFBFFBE
000000003FFFFFFFFFFE000003000000FF1FFFF3FF7E
000000001FFFFFFFFFFE000000000000FE1FFFF7FF7E
000000000FFFFFFFFFFE000000000000FC1FFFE7FF68
0000000003FFFFFFFFFE000000000001FC1FFFEFFF00
0000000001FFFFFFFFFC000000800001F81FFFCFFE00
0000010001FFFFFFFFFC000401800003F01FFFCFFE00
0000000100FFFFFFFFFC000000000003E03FFF9FFE00
00000000007FFFFFFFF800000000000FE03FFF9FFE00
00000000003FFFFFFFF800000000003FC07FFF9FFC00
00000000001FFFFFFFF800000000003FC05FFF3FFC00
00000000001FFFFFFFE000000000007FC09FFF3FFC00
00000000000FFFFFFFE000000000007FE69FFF7FFC00
000000100007FFFFFFC000000000007FE3BFFE7FF800
800000100007FFFFFF000000000000FFE93FFE7FF800
000000000003FFFFFE000000400000FFF07FFCFFF800
000000000000FFFFF8000000000001FFE8FFFCFFF800
0000000000047FFFE0000000000003FFCF7FF8FFF000
0000000000001FFF80000000000003FFDFFFF9FFF000
000000000000016000000000100001FFDFFFFBFFF000
000000000000004000000000100001FFBFFFF3FFF000
000000000000000010000000000003FBFFFFF3FFE000
000000000000000000000000000003FB7FFFE7FFE000
000000000000000000000000000007F0FFFFE7FFE000
00000000000000000000000000000780FFFFC7FFE000
00000000000000000000000000002F80FFFFCFFFC000
0000000002000000000000000000FF00DFFFCFFFC000
0000000000000000000200000000FF00C7FF9FFFC000
0000000000000000000000000000FE0101FF9FFF8000
0008000040000000000000000001FC0100FF3FFF8000
0000000000000000000000000001FC03007F3FFF8000
000000000000C000000000000001F802007E3FFF8000
0000000000000000010000000001F006007E3FFF0000
0000000000000000010000000001F00400FC7FFF0000
0000000000000000000000000001E00C00FCFFFF0000
000000000000000000000000003BE01800FCFFFF0000
700000000000000000000000007FC01800F8FFFE0000
700000000000000000000000007FC01000F9FFFE0000
600000000000000000000000007F80200071FFFE0000
00000000000000000000000600FFC0600079FFFC0000
00000000000000000000000701FFF040007BFFFC0000
00000000000000000003000303FFF88000FBFFFC0000
00010000000000000003000007FFFE8000FBFFF80000
0000000000000000000100101FFFFF8001DB9FF80000
0000010000000000000118031FFFFF8001FB8FF80000
0000000000000000000018073FFFFFE003FB83F00000
000000200000000000000004BFFFFFF803BB03F00000
0000000000000000000000887FFFFFFC07FB80F00000
^FO150,150^XGR:img5.GRF,1,1^FS
^XZ
BTLE on zebra printers is meant to be used just to configure the printer, not to print labels, so it has a low timeout and a slow transmission speed.
Not a Flutter expert at all, but all the mobile printers should have the BT Classic, which should allow you to print labels, so you might check if you can switch to that on the printing call you're doing from your app.
You can also check what BT type the printer is set on by sending the following command
! U1 getvar "bluetooth.le.controller_mode"
and you can set it to use Classic BT sending this command
! U1 setvar "bluetooth.le.controller_mode" "classic"
(Note that all these commands need a new line after the command itself).
Have a look here to see how to send this command

GraphMachine doesn't generate graph for NarcolepticSuperhero quickstart example

I tried creating a Diagram using the NarcolepticSuperhero machine defined in the GitHub documentation but it only outputs this:
Steps to recreate:
Create a file named test.py, with this content:
from transitions import Machine
from transitions.extensions import GraphMachine
import random
class NarcolepticSuperhero(object):
# Define some states. Most of the time, narcoleptic superheroes are just like
# everyone else. Except for...
states = ['asleep', 'hanging out', 'hungry', 'sweaty', 'saving the world']
def __init__(self, name):
# No anonymous superheroes on my watch! Every narcoleptic superhero gets
# a name. Any name at all. SleepyMan. SlumberGirl. You get the idea.
self.name = name
# What have we accomplished today?
self.kittens_rescued = 0
# Initialize the state machine
self.machine = Machine(model=self, states=NarcolepticSuperhero.states, initial='asleep')
# Add some transitions. We could also define these using a static list of
# dictionaries, as we did with states above, and then pass the list to
# the Machine initializer as the transitions= argument.
# At some point, every superhero must rise and shine.
self.machine.add_transition(trigger='wake_up', source='asleep', dest='hanging out')
# Superheroes need to keep in shape.
self.machine.add_transition('work_out', 'hanging out', 'hungry')
# Those calories won't replenish themselves!
self.machine.add_transition('eat', 'hungry', 'hanging out')
# Superheroes are always on call. ALWAYS. But they're not always
# dressed in work-appropriate clothing.
self.machine.add_transition('distress_call', '*', 'saving the world',
before='change_into_super_secret_costume')
# When they get off work, they're all sweaty and disgusting. But before
# they do anything else, they have to meticulously log their latest
# escapades. Because the legal department says so.
self.machine.add_transition('complete_mission', 'saving the world', 'sweaty',
after='update_journal')
# Sweat is a disorder that can be remedied with water.
# Unless you've had a particularly long day, in which case... bed time!
self.machine.add_transition('clean_up', 'sweaty', 'asleep', conditions=['is_exhausted'])
self.machine.add_transition('clean_up', 'sweaty', 'hanging out')
# Our NarcolepticSuperhero can fall asleep at pretty much any time.
self.machine.add_transition('nap', '*', 'asleep')
def update_journal(self):
""" Dear Diary, today I saved Mr. Whiskers. Again. """
self.kittens_rescued += 1
#property
def is_exhausted(self):
""" Basically a coin toss. """
return random.random() < 0.5
def change_into_super_secret_costume(self):
print("Beauty, eh?")
batman = NarcolepticSuperhero("Batman")
batman.wake_up()
batman.state
machine = GraphMachine(model=batman)
batman.get_graph().draw("test.png", prog='dot')
Install the requirements (Ubuntu 20.10, I tested on it's docker image) and run the script:
$ apt install graphviz graphviz-dev
$ pip3 install transitions graphviz pygraphviz
$ python3 test.py
Check the generated image
You are instantiating a GraphMachine without any states and transitions here:
machine = GraphMachine(model=batman)
You basically reuse NarcolepticSuperhero as a model for that new machine but what you should do instead is changing the NarcolepticSuperhero's machine into a GraphMachine:
# Initialize the state machine
self.machine = GraphMachine(model=self, states=NarcolepticSuperhero.states, initial='asleep')
# [...]
batman.state
# this is not required anymore
# machine = GraphMachine(model=batman)
batman.get_graph().draw("test.png", prog='dot')

Mikrotik - result of script job as var is empty

I need to now some info about LTE/3G connection from output of command with Zabbix. Routerboard is 6.47.7 version.
[admin#Mikrotik_24] > interface lte info lte1 once
pin-status: ok
registration-status: registered
functionality: full
manufacturer: "MikroTik"
model: "R11e-LTE"
revision: "MikroTik_CP_2.160.000_v008"
current-operator: MTS
psc: 295
lac: 5205
current-cellid: 241903616
access-technology: 3G
session-uptime: 21h3m18s
imei: 355654090621868
imsi: 250016652966098
uicc: 89701011266529660988
earfcn: 10762
ecno: 0dB
rssi: -95dBm
For example "rssi", "access-technology", "uicc" and so on.
The problem with such command described by themselves - the data goes infinitely, and you cant catch it easy.
https://wiki.mikrotik.com/wiki/Manual:Scripting_Tips_and_Tricks#Get_values_from_looped_interactive_commands_like_.22monitor.22
So I have a script to get some values as a global var.
/interface lte info lte1 once do={:global at $"access-technology" }
and ":put $at" in terminal works fine. But I think to take result with SNMP by executing another script to show this generated var $at. It is possible with OID they did for "script result" purpose.
The question is how to output this var in script?
[admin#Mikrotik_24] > /system script export compact
# oct/31/2020 01:52:57 by RouterOS 6.47.7
# software id = PW8X-NNQ5
#
# model = RouterBOARD wAP R-2nD
/system script
add dont-require-permissions=no name=at owner=admin policy=\
ftp,reboot,read,write,policy,test,password,sniff,sensitive,romon source=\
"/interface lte info lte1 once do={:global at \$\"access-technology\" } \r\
\n"
add dont-require-permissions=no name=at_result owner=admin policy=\
ftp,reboot,read,write,policy,test,password,sniff,sensitive,romon source=":put \$at"
[admin#Mikrotik_24] > :environment print
at="3G"
[admin#Mikrotik_24] > /system script environment print
# NAME VALUE
0 at 3G
[admin#Mikrotik_24] > /system script run at_result
[admin#Mikrotik_24] >
You see, /system script run at_result is empty, but in terminal I can see it
[admin#Mikrotik_24] > :put $at
3G
[admin#Mikrotik_24] >
Ok. The right form of script var is
{
:global test
set $test "my data"
}
I have to declare it first.

Elastix Custom Configuration files

I am new in Asterisk and using Elastix 2.5 to create two queues with 2 static members per queue in a lab environment. I want to set the value of 'setqueuevar' to yes. To do that I have changed the queue_custom.conf file and set this value to yes; although I have reloaded the asterisk modules and everything looks ok, but the related channel variables (QUEUENAME, QUEUESTRATEGY,...) don't get any value!
As some of the configuration files are auto-generated by Elastix (freepbx module), would you please tell me what is the precedence of configuration files in it? Is there any relationship between them or the main files are overwritten by custom configuration files?
queues.conf file:
[general]
;
; Global settings for call queues
; (none exist currently)
;
; Note that a timeout to fail out of a queue may be passed as part of
application call
; from extensions.conf:
; Queue(queuename|[options]|[optionalurl]|[announceoverride]|[timeout])
; example: Queue(dave|t|||45)
#include queues_general_additional.conf
#include queues_custom_general.conf
[default]
;
; Default settings for queues (currently unused)
;
#include queues_custom.conf
#include queues_additional.conf
#include queues_post_custom.conf
queues_additional.conf
;--------------------------------------------------------------------------------;
; Do NOT edit this file as it is auto-generated by FreePBX. All modifications to ;
; this file must be done via the web gui. There are alternative files to make ;
; custom modifications, details at: http://freepbx.org/configuration_files ;
;--------------------------------------------------------------------------------;
;
[1050]
announce-frequency=0
announce-holdtime=no
announce-position=no
autofill=no
autopause=no
autopausebusy=no
autopausedelay=0
autopauseunavail=no
eventmemberstatus=no
eventwhencalled=no
joinempty=no
leavewhenempty=no
maxlen=0
memberdelay=0
monitor-type=mixmonitor
penaltymemberslimit=0
periodic-announce-frequency=0
queue-callswaiting=silence/1
queue-thereare=silence/1
queue-youarenext=silence/1
reportholdtime=no
retry=5
ringinuse=yes
servicelevel=60
strategy=rrmemory
timeout=15
timeoutpriority=app
timeoutrestart=no
weight=0
wrapuptime=0
member=Local/10501#from-queue/n,0,10501,hint:10501#ext-local
member=Local/10502#from-queue/n,0,10502,hint:10502#ext-local
[115]
announce-frequency=0
announce-holdtime=no
announce-position=no
autofill=no
autopause=no
autopausebusy=no
autopausedelay=0
autopauseunavail=no
eventmemberstatus=no
eventwhencalled=no
joinempty=no
leavewhenempty=no
maxlen=0
memberdelay=0
monitor-type=mixmonitor
penaltymemberslimit=0
periodic-announce-frequency=0
queue-callswaiting=silence/1
queue-thereare=silence/1
queue-youarenext=silence/1
reportholdtime=no
retry=5
ringinuse=yes
servicelevel=60
strategy=rrmemory
timeout=15
timeoutpriority=app
timeoutrestart=no
weight=0
wrapuptime=0
member=Local/1151#from-queue/n,0,1151,hint:1151#ext-local
member=Local/1152#from-queue/n,0,1152,hint:1152#ext-local
queues_custom.conf:
[1050]
announce-frequency=0
announce-holdtime=no
announce-position=no
autofill=no
autopause=no
autopausebusy=no
autopausedelay=0
autopauseunavail=no
eventmemberstatus=no
eventwhencalled=no
joinempty=no
leavewhenempty=no
maxlen=0
memberdelay=0
monitor-type=mixmonitor
penaltymemberslimit=0
periodic-announce-frequency=0
queue-callswaiting=silence/1
queue-thereare=silence/1
queue-youarenext=silence/1
reportholdtime=no
retry=5
ringinuse=yes
servicelevel=60
strategy=rrmemory
timeout=15
timeoutpriority=app
timeoutrestart=no
weight=0
wrapuptime=0
setqueuevar=yes
member=Local/10501#from-queue/n,0,10501,hint:10501#ext-local
member=Local/10502#from-queue/n,0,10502,hint:10502#ext-local
[115]
announce-frequency=0
announce-holdtime=no
announce-position=no
autofill=no
autopause=no
autopausebusy=no
autopausedelay=0
autopauseunavail=no
eventmemberstatus=no
eventwhencalled=no
joinempty=no
leavewhenempty=no
maxlen=0
memberdelay=0
monitor-type=mixmonitor
penaltymemberslimit=0
periodic-announce-frequency=0
queue-callswaiting=silence/1
queue-thereare=silence/1
queue-youarenext=silence/1
reportholdtime=no
retry=5
ringinuse=yes
servicelevel=60
strategy=rrmemory
timeout=15
timeoutpriority=app
timeoutrestart=no
weight=0
wrapuptime=0
setqueuevar=yes
member=Local/1151#from-queue/n,0,1151,hint:1151#ext-local
member=Local/1152#from-queue/n,0,1152,hint:1152#ext-local
Freepbx overwrite only files which ends by "_additional.conf"
You should do NOT do any changes in file, instead you have write freepbx module.
If you still want do manual changes, do changes in files which ending by "_custom.conf"
If you have same pattern in 2 files with same prio, result is UNPREDICTABLE, but in most cases first one will work.
Read this
https://www.voip-info.org/wiki/view/Asterisk+Dialplan+Introduction
Read ORelly's "Asterisk the future telephony"

Jump to the first file or directory that starts with a specific letter

In the VS Code Explorer, how do jump to the first file or directory that starts with a specific letter?
For example, in the node_modules directory, I want to be able to press W and jump to wcwidth in the following directory list.
.bin
abbrev
accepts
acorn
after
agent-base
align-text
amdefine
ansi-align
ansi-regex
ansi-styles
ansicolors
any-promise
anymatch
archy
argparse
arr-diff
arr-flatten
array-differ
array-find-index
array-slice
array-uniq
array-unique
arraybuffer.slice
arrify
asn1
assert-plus
async
async-done
async-each
async-each-series
async-settle
atob
aurelia-animator-css
aurelia-binding
aurelia-bootstrapper
aurelia-cli
aurelia-dependency-injection
aurelia-event-aggregator
aurelia-fetch-client
aurelia-framework
aurelia-history
aurelia-history-browser
aurelia-loader
aurelia-loader-default
aurelia-logging
aurelia-logging-console
aurelia-metadata
aurelia-pal
aurelia-pal-browser
aurelia-path
aurelia-polyfills
aurelia-route-recognizer
aurelia-router
aurelia-task-queue
aurelia-templating
aurelia-templating-binding
aurelia-templating-resources
aurelia-templating-router
aurelia-testing
aurelia-tools
aws-sign2
bach
backo2
balanced-match
base64-arraybuffer
base64id
batch
beeper
benchmark
better-assert
binary-extensions
bl
blob
bluebird
body-parser
boom
boxen
brace-expansion
braces
breeze-dag
breeze-nexttick
breeze-queue
browser-sync
browser-sync-client
browser-sync-ui
bs-recipes
builtin-modules
bytes
callsite
camelcase
camelcase-keys
capture-stack-trace
cardinal
caseless
center-align
chalk
chokidar
cli-boxes
cli-table
cli-usage
cliui
clone
clone-stats
code-point-at
colors
columnify
combined-stream
commander
component-bind
component-emitter
component-inherit
concat-map
concat-stream
configstore
connect
connect-history-api-fallback
content-type
convert-source-map
core-js
core-util-is
create-error-class
cryptiles
css
ctype
currently-unhandled
custom-event
d
dateformat
debug
decamelize
deep-extend
deep-is
default-resolution
defaults
delayed-stream
depd
destroy
detect-file
detect-indent
detect-newline
dev-ip
di
diff
dom-serialize
dot-prop
duplexer
duplexer2
duplexify
easy-extender
eazy-logger
ee-first
emitter-steward
end-of-stream
engine.io
engine.io-client
engine.io-parser
ent
error-ex
es5-ext
es6-iterator
es6-symbol
es6-weak-map
escape-html
escape-string-regexp
escodegen
esprima-fb
estraverse
esutils
etag
event-stream
eventemitter3
expand-braces
expand-brackets
expand-range
expand-tilde
express
extend
extend-shallow
extglob
fancy-log
fast-levenshtein
filename-regex
fileset
fill-range
filled-array
finalhandler
find-up
findup-sync
fined
first-chunk-stream
flagged-respawn
for-in
for-own
forever-agent
form-data
formidable
fresh
from
fs-access
fs-exists-sync
fs-extra
fs.realpath
function-bind
gaia-tsort
generate-function
generate-object-property
get-stdin
glob
glob-base
glob-parent
glob-stream
glob-watcher
global-modules
global-prefix
glogg
got
graceful-fs
graceful-readlink
growly
gulp
gulp-changed-in-place
gulp-notify
gulp-plumber
gulp-rename
gulp-sourcemaps
gulp-tslint
gulp-typescript
gulp-util
gulplog
handlebars
har-validator
has
has-ansi
has-binary
has-cors
has-flag
has-gulplog
hawk
hoek
hosted-git-info
http-errors
http-proxy
http-proxy-agent
http-signature
https-proxy-agent
iconv-lite
immutable
imurmurhash
indent-string
indexof
inflight
inherits
ini
interpret
invariant
invert-kv
is
is-absolute
is-arrayish
is-binary-path
is-buffer
is-builtin-module
is-dotfile
is-equal-shallow
is-extendable
is-extglob
is-finite
is-fullwidth-code-point
is-glob
is-my-json-valid
is-npm
is-number
is-obj
is-plain-obj
is-posix-bracket
is-primitive
is-property
is-redirect
is-relative
is-retry-allowed
is-stream
is-unc-path
is-utf8
is-valid-glob
is-windows
isarray
isbinaryfile
isexe
isobject
isstream
istanbul
jasmine-core
js-tokens
js-yaml
json-stable-stringify
json-stringify-safe
json3
jsonfile
jsonify
jsonpointer
jsrsasign
jwt-decode
karma
karma-chrome-launcher
karma-cli
karma-coverage
karma-firefox-launcher
karma-jasmine
karma-requirejs
karma-spec-reporter
karma-typescript-preprocessor
kind-of
klaw
last-run
latest-version
lazy-cache
lazy-req
lazystream
lcid
levn
liftoff
limiter
listify
load-json-file
localtunnel
lockfile
lodash
lodash.assign
lodash.assignwith
lodash.clonedeep
lodash.debounce
lodash.defaults
lodash.escape
lodash.filter
lodash.flatten
lodash.foreach
lodash.initial
lodash.isarguments
lodash.isarray
lodash.isempty
lodash.isequal
lodash.isfunction
lodash.isplainobject
lodash.isstring
lodash.keys
lodash.last
lodash.map
lodash.mapvalues
lodash.pick
lodash.reduce
lodash.restparam
lodash.sortby
lodash.template
lodash.templatesettings
lodash._arraycopy
lodash._arrayeach
lodash._baseassign
lodash._baseclone
lodash._basecopy
lodash._basefor
lodash._basetostring
lodash._basevalues
lodash._bindcallback
lodash._createassigner
lodash._getnative
lodash._isiterateecall
lodash._reescape
lodash._reevaluate
lodash._reinterpolate
lodash._root
log4js
longest
loose-envify
loud-rejection
lowercase-keys
lru-cache
make-error
make-error-cause
map-cache
map-obj
map-stream
marked
marked-terminal
matchdep
media-typer
meow
merge-stream
micromatch
mime
mime-db
mime-types
minimatch
minimist
mkdirp
ms
multipipe
mute-stdout
negotiator
next-tick
node-emoji
node-notifier
node-status-codes
node-uuid
node.extend
nopt
normalize-package-data
normalize-path
now-and-later
npm
null-check
number-is-nan
oauth-sign
object-assign
object-component
object-path
object.omit
object.pick
on-finished
once
openurl
opn
optimist
optionator
options
ordered-read-streams
os-homedir
os-locale
os-tmpdir
osenv
package-json
parse-filepath
parse-glob
parse-json
parsejson
parseqs
parseuri
parseurl
path-exists
path-is-absolute
path-root
path-root-regex
path-type
pause-stream
pify
pinkie
pinkie-promise
pkg-conf
popsicle
popsicle-proxy-agent
popsicle-retry
popsicle-status
portscanner
prelude-ls
prepend-http
preserve
pretty-hrtime
process-nextick-args
promise-finally
qs
randomatic
range-parser
raw-body
rc
read-all-stream
read-pkg
read-pkg-up
readable-stream
readdirp
rechoir
redent
redeyed
regex-cache
registry-url
repeat-element
repeat-string
repeating
replace-ext
request
require-main-filename
requirejs
requires-port
resolve
resolve-dir
resolve-url
resp-modifier
right-align
rimraf
rx
semver
semver-diff
semver-greatest-satisfied-range
semver-regex
send
serve-index
serve-static
server-destroy
set-blocking
set-immediate-shim
setprototypeof
shellwords
signal-exit
slide
sntp
socket.io
socket.io-adapter
socket.io-client
socket.io-parser
sort-keys
source-map
source-map-resolve
source-map-url
sparkles
spdx-correct
spdx-exceptions
spdx-expression-parse
spdx-license-ids
split
sprintf-js
stack-trace
statuses
stream-combiner
stream-exhaust
stream-shift
stream-throttle
string-template
string-width
stringstream
string_decoder
strip-ansi
strip-bom
strip-bom-stream
strip-indent
strip-json-comments
supports-color
symbol
text
tfunk
thenify
throat
through
through2
through2-filter
throwback
tildify
time-stamp
timed-out
to-absolute-glob
to-array
touch
tough-cookie
trim-newlines
tslint
tunnel-agent
type-check
type-is
typedarray
typescript
typings
typings-core
ua-parser-js
uglify-js
uglify-to-browserify
ultron
unc-path-regex
underscore
underscore.string
undertaker
undertaker-registry
unique-stream
unpipe
unzip-response
update-notifier
urix
url-parse-lax
user-home
useragent
utf8
util-deprecate
utils-merge
uuid
v8flags
vali-date
validate-npm-package-license
vinyl
vinyl-fs
void-elements
wcwidth
weinre
whatwg-fetch
which
widest-line
window-size
wordwrap
wrap-ansi
wrappy
wreck
write-file-atomic
ws
xdg-basedir
xmlhttprequest-ssl
xtend
y18n
yargs
yargs-parser
yeast
zip-object
This already works in the Windows File Explorer. It's called "When typing into list view, Select the typed item in the view." Does a similar feature exist in the Visual Studio Code Explorer?