Lua on LinkIt One

Hello there,

Lua is a powerful, fast, lightweight, embeddable scripting language. It can run on LinkIt One now.

If you’re interested in Lua, go to https://github.com/xiongyihui/Lua_for_LinkIt_One, follow the README.md, and you will get a Lua interpreter running on LinkIt One.

Hello!

I’m trying to install it with OS X El Capitan, but I have several problems when I try to upload the vxp on Linkit. Here the stack:

Parameter number = 3
Parameter 0 value = ./tools/mtk/PackTag
Parameter 1 value = -i
Parameter 2 value = lua.elf
Digist Packer Command Shell v3.1329.00
./tools/mtk/PushTool.sh cu.usbmodemFA133 lua.vxp


Command parameter number = 7
Parameter 0 = ./tools/mtk/PushTool
Parameter 1 = -d
Parameter 2 = arduino
Parameter 3 = -b
Parameter 4 = cu.usbmodemFA133
Parameter 5 = -p
Parameter 6 = lua.vxp
device path /dev/cu.usbmodemFA133
vxp file path lua.vxp
Parser argument pass.
USB Device name: IOSerialBSDClient
Device entry path: IOService:/IOResources/IOBluetoothSerialManager/IOBluetoothSerialClient/IOBluetoothSerialClientSerialStreamSync/IOSerialBSDClient
Device class name: IOSerialBSDClient
Device callout path: /dev/cu.Bluetooth-Incoming-Port

USB Device name: IOSerialBSDClient
Device entry path: IOService:/AppleACPIPlatformExpert/PCI0@0/AppleACPIPCI/EHC2@1A,7/EHC2@fa000000/PRT1@fa100000/IOUSBHostDevice@fa100000/AppleUSB20InternalHub@fa100000/PRT3@fa130000/Product@fa130000/COM(data_if)@1/AppleUSBACMData/IOModemSerialStreamSync/IOSerialBSDClient
Device class name: IOSerialBSDClient
Device vendor name: MediaTek Inc
Vendor id: 3725
Product id: 35
Interface number: 1
Device callout path: /dev/cu.usbmodemFA131

USB Device name: IOSerialBSDClient
Device entry path: IOService:/AppleACPIPlatformExpert/PCI0@0/AppleACPIPCI/EHC2@1A,7/EHC2@fa000000/PRT1@fa100000/IOUSBHostDevice@fa100000/AppleUSB20InternalHub@fa100000/PRT3@fa130000/Product@fa130000/COM(data_if)@3/AppleUSBACMData/IOModemSerialStreamSync/IOSerialBSDClient
Device class name: IOSerialBSDClient
Device vendor name: MediaTek Inc
Vendor id: 3725
Product id: 35
Interface number: 3
Device callout path: /dev/cu.usbmodemFA133
Find device PID: 35, VID: 3725, interface number: 3, and device path: /dev/cu.usbmodemFA133
device path /dev/cu.usbmodemFA133
open port /dev/cu.usbmodemFA133

descriptor is 4, bsd path-> /dev/cu.usbmodemFA133

Current input baud rate is 9600

Current output baud rate is 9600
Input baud rate changed to 115200
Output baud rate changed to 115200

Handshake lines currently set to 6

[txd] AT

[txd] AT

[rxd]
OK

[rxd]
OK

[txd] AT+ESUO?

[txd] AT+ESUO?

[rxd]
+ESUO: 3, 4

OK

[rxd]
+ESUO: 3, 4

OK

[txd] AT+EFSL

[txd] AT+EFSL

[rxd]
+EFSL: “0043003A”

OK

[rxd]
+EFSL: “0043003A”

OK

Get driver C: available size.

[txd] AT+EFS=67

[txd] AT+EFS=67

[rxd]
+EFS: 10350592

OK

[rxd]
+EFS: 10350592

OK

[txd] AT+EFSF=3

[txd] AT+EFSF=3

[rxd]
OK

[rxd]
OK

[txd] AT+EFSL=“0043003a”

[txd] AT+EFSL=“0043003a”

[rxd]
+EFSL: "

[rxd]
+EFSL: "

[rxd] 006D00720065002E006C006F0067", 0, 0

[rxd] 006D00720065002E006C006F0067", 0, 0

[rxd]
+EFSL: "

[rxd]
+EFSL: "

[rxd] 002E00660073006500760065006E007400730064", 0, 18

[rxd] 002E00660073006500760065006E007400730064", 0, 18

[rxd]
+EFSL: "

[rxd]
+EFSL: "

[rxd] 004D00520045

[rxd] 004D00520045

[rxd] ", 0, 16

[rxd] ", 0, 16

[rxd]
+EFSL: "006100750074006F00730074006100720074002E007400780074

[rxd]
+EFSL: "006100750074006F00730074006100720074002E007400780074

[rxd] ", 26, 32

[rxd] ", 26, 32

[rxd]
+EFSL: “002E005F002E0054007200610073006800650073”, 4096, 34

[rxd]
+EFSL: “002E005F002E0054007200610073006800650073”, 4096, 34

[rxd]
+EFSL: "007200650073007500

[rxd]
+EFSL: "007200650073007500

[rxd] 6C0074002E007400780074", 48, 32

[rxd] 6C0074002E007400780074", 48, 32

[rxd]
+EFSL: "

[rxd]
+EFSL: "

[rxd] 002E0054007200610073006800650073", 0, 18

[rxd] 002E0054007200610073006800650073", 0, 18

[rxd]
OK

[rxd]
OK

[txd] AT+EFSF=3

[txd] AT+EFSF=3

[rxd]
OK

[rxd]
OK

[txd] AT+EFSL=“0043003a”

[txd] AT+EFSL=“0043003a”

[rxd]
+EFSL: "006D00720065002E006C006F0067

[rxd]
+EFSL: "006D00720065002E006C006F0067

[rxd] ", 0, 0

[rxd] ", 0, 0

[rxd]
+EFSL: "

[rxd]
+EFSL: "

[rxd] 002E00660073006500760065006E007400730064", 0, 18

[rxd] 002E00660073006500760065006E007400730064", 0, 18

[rxd]
+EFSL: "

[rxd]
+EFSL: "

[rxd] 004D00520045", 0, 16

[rxd] 004D00520045", 0, 16

[rxd]
+EFSL: "

[rxd]
+EFSL: "

[rxd] 006100750074006F00730074006100720074002E007400780074", 26, 32

[rxd] 006100750074006F00730074006100720074002E007400780074", 26, 32

[rxd]
+EFSL: “002E005F002E0054007200610073006800650073”, 4096, 34

[rxd]
+EFSL: “002E005F002E0054007200610073006800650073”, 4096, 34

[rxd]
+EFSL: "0072006500730075006C0074002E007400780074

[rxd]
+EFSL: "0072006500730075006C0074002E007400780074

[rxd] ", 48, 32

[rxd] ", 48, 32

[rxd]
+EFSL: "

[rxd]
+EFSL: "

[rxd] 002E0054007200610073006800650073", 0, 18

[rxd] 002E0054007200610073006800650073", 0, 18

[rxd]
OK

[rxd]
OK

[txd] AT+[666]EXIT_ALL

[txd] AT+[666]EXIT_ALL

[rxd]
ERROR

[rxd]
ERROR

[txd] AT+EFSF=3

[txd] AT+EFSF=3

[rxd]
OK

[rxd]
OK

[txd] AT+EFSL=“0043003a005c004d00520045”

[txd] AT+EFSL=“0043003a005c004d00520045”

[rxd]
+EFSL: "

[rxd]
+EFSL: "

[rxd] 002E

[rxd] 002E

[rxd] ", 0, 16

[rxd] ", 0, 16

[rxd]
+EFSL: “002E002E”, 0, 16

[rxd]
+EFSL: “002E002E”, 0, 16

[rxd]
+EFSL: "

[rxd]
+EFSL: "

[rxd] 0062005F0042006C0069006E006B002E006300700070002E007600780070", 63528, 32

[rxd] 0062005F0042006C0069006E006B002E006300700070002E007600780070", 63528, 32

[rxd]
OK

[rxd]
OK

[txd] AT+EFSF=3

[txd] AT+EFSF=3

[rxd]
OK

[rxd]
OK

[txd] AT+EFSL=“0043003a”

[txd] AT+EFSL=“0043003a”

[rxd]
+EFSL: "006D00720065002E006C006F0067

[rxd]
+EFSL: "006D00720065002E006C006F0067

[rxd] ", 0, 0

[rxd] ", 0, 0

[rxd]
+EFSL: “002E00660073006500760065006E007400730064”, 0, 18

[rxd]
+EFSL: “002E00660073006500760065006E007400730064”, 0, 18

[rxd]
+EFSL: "

[rxd]
+EFSL: "

[rxd] 004D00520045", 0, 16

[rxd] 004D00520045", 0, 16

[rxd]
+EFSL: "006100750074006F00730074006100720074002E007400780074

[rxd]
+EFSL: "006100750074006F00730074006100720074002E007400780074

[rxd] ", 26, 32

[rxd] ", 26, 32

[rxd]
+EFSL: "

[rxd]
+EFSL: "

[rxd] 002E005F002E0054007200610073006800650073", 4096, 34

[rxd] 002E005F002E0054007200610073006800650073", 4096, 34

[rxd]
+EFSL: "0072006500730075006C0074002E007400780074

[rxd]
+EFSL: "0072006500730075006C0074002E007400780074

[rxd] ", 48, 32

[rxd] ", 48, 32

[rxd]
+EFSL: "002E0054007200610073006800650073

[rxd]
+EFSL: "002E0054007200610073006800650073

[rxd] ", 0, 18

[rxd] ", 0, 18

[rxd]
OK

[rxd]
OK

[ReadTargetFile] enter directory C:\autostart.txt first.

[txd] AT+EFSF=3

[txd] AT+EFSF=3

[rxd]
OK

[rxd]
OK

[txd] AT+EFSR=“0043003a005c006100750074006f00730074006100720074002e007400780074”

[txd] AT+EFSR=“0043003a005c006100750074006f00730074006100720074002e007400780074”

[rxd]
+EFSR: 1, 1, 26, “5B6175746F73746172745D0D0A4170703D433A5C4D52455C0D0A”

[rxd]
+EFSR: 1, 1, 26, “5B6175746F73746172745D0D0A4170703D433A5C4D52455C0D0A”

[rxd]
OK

[rxd]
OK

Read target start file successful.
current vxp dir = C:\MRE\

[txd] AT+EFSF=3

[txd] AT+EFSF=3

[rxd]
OK

[rxd]
OK

[txd] AT+EFSL=“0043003a005c004d00520045”

[txd] AT+EFSL=“0043003a005c004d00520045”

[rxd]
+EFSL: “002E”, 0, 16

[rxd]
+EFSL: “002E”, 0, 16

[rxd]
+EFSL: "002E002E

[rxd]
+EFSL: "002E002E

[rxd] ", 0, 16

[rxd] ", 0, 16

[rxd]
+EFSL: "0062005F0042006C0069006E006B002E006300700070002E007600780070

[rxd]
+EFSL: "0062005F0042006C0069006E006B002E006300700070002E007600780070

[rxd] ", 63528, 32

[rxd] ", 63528, 32

[rxd]
OK

[rxd]
OK

Enter dir C:\MRE.

[txd] AT+EFSF=3

[txd] AT+EFSF=3

[rxd]
OK

[rxd]
OK

[txd] AT+EFSD=“0043003a005c004d00520045005c002e”

[txd] AT+EFSD=“0043003a005c004d00520045005c002e”

[rxd]
ERROR

[rxd]
ERROR

Enter dir C:\MRE…

[txd] AT+EFSF=3

[txd] AT+EFSF=3

[rxd]
OK

[rxd]
OK

[txd] AT+EFSD=“0043003a005c004d00520045005c002e002e”

[txd] AT+EFSD=“0043003a005c004d00520045005c002e002e”

[rxd]
ERROR

[rxd]
ERROR

Enter dir C:\MRE\b_Blink.cpp.vxp

[txd] AT+EFSF=3

[txd] AT+EFSF=3

[rxd]
OK

[rxd]
OK

[txd] AT+EFSD=“0043003a005c004d00520045005c0062005f0042006c0069006e006b002e006300700070002e007600780070”

[txd] AT+EFSD=“0043003a005c004d00520045005c0062005f0042006c0069006e006b002e006300700070002e007600780070”

[rxd]
ERROR

[rxd]
ERROR

[txd] AT+EFSF=3

[txd] AT+EFSF=3

[rxd]
OK

[rxd]
OK

[txd] AT+EFSL=“0043003a005c004d00520045”

[txd] AT+EFSL=“0043003a005c004d00520045”

[rxd]
+EFSL: "002E

[rxd]
+EFSL: "002E

[rxd] ", 0, 16

[rxd] ", 0, 16

[rxd]
+EFSL: "002E002E

[rxd]
+EFSL: "002E002E

[rxd] ", 0, 16

[rxd] ", 0, 16

[rxd]
+EFSL: “0062005F0042006C0069006E006B002E006300700070002E007600780070”, 63528, 32

[rxd]
+EFSL: “0062005F0042006C0069006E006B002E006300700070002E007600780070”, 63528, 32

[rxd]
OK

[rxd]
OK

Set current folder C:\MRE
stop current vxp C:\autostart.txt and delete it.
Write target file:
Enter dir C:\MRE
Write target file:
Enter dir C:\MRE\

[txd] AT+EFSF=3

[txd] AT+EFSF=3

[rxd]
OK

[rxd]
OK

[txd] AT+EFSW=0,“0043003a005c004d00520045005c”

[txd] AT+EFSW=0,“0043003a005c004d00520045005c”

[rxd]
ERROR

[rxd]
ERROR

Write file lua.vxp failed,
Write file lua.vxp failed,
make: *** [install] Error 44

============
END

Why there are reference to a C:\MRE\ directory ? is it a directory inside the linkit-one where application is installed ?

NOTE: If I use the Arduino+LinkitOne-SDK I can upload successfully the Blink example.

Thank you!