First brush into the Aicloud 2.0 SDK file, Aicloud 2.0 specific information see Aicloud 1.0 and Aicloud 2.0 comparison app see the following QR code download.1, an Aicloud 2.0 at firmware ai-thinker_esp8266_dout_aicloud_v0.0.0.6_20170517.7z downloadAicloud 2.0 at FirmwareCharacteristics:Aicloud 2.0 safe, stable and easy to useSimple to use, any MCU can be directly connected512+512map Firmware: ai-thinker_esp8266_dout_aicloud_v0.0.0.6_20170517.7zUpdated: May 17, 2017Update Description: 0.0.0.6 ne
',%al out%al, (%DX) mov $ ' \ n ',%al out%al, (%DX) hltThis code acts as the guest OS, basically a bare-ben system. It implements the 0x3f8, then adds ' 0 ', turns 4 to ASCII ' 4 ' and outputs through the port. And then output the ' \ n ' and then shut down the machine.We put the binary that corresponds to the code into the array: Const uint8_t code[] = {0XBA, 0xf8, 0x03,/* mov $0x3f8,%dx */0x00, 0xd8,/ * add%bl,%al */0x04, ' 0 ',/ * add $ ' 0 ',%al */0xee,
Copy Code code as follows:
---Get the correct length of the UTF8 encoded string
--@param str
--@return Number
function Utfstrlen (str)
Local len = #str;
Local left = Len;
Local cnt = 0;
Local ARR={0,0XC0,0XE0,0XF0,0XF8,0XFC};
While left ~= 0 do
Local Tmp=string.byte (Str,-left);
Local i= #arr;
While Arr[i] do
If Tmp>=arr[i] then Left=left-i;break;end
I=i-1;
End
cnt=cnt+1;
End
return CNT;
End
The LUA string library does not support the processin
0xbfffe5f5
0xbfffe5f6
0xbfffe5f7
A[1]
0x90
0xf4
0x01
0x00
Add
0xbfffe5f8
0xbfffe5f9
0xbfffe5fa
0xbfffe5fb
A[2]
0x00
0x01
0x00
0x00
Same as the result.
I modified the Boot/makefrag inside the link address, the 0X7C00 to 0X7C01, re-run error, if the 0X7C01 set a breakpoint, then the card read boot sector that part, the QEMU interface is constantly
BUFIndicates that the contents are read from the memory address buf.H represents a unit in double-byte,3 means three units,U indicates hexadecimal display
Detailed Examples: (gdb) List 1 #include 2 int Main () 3{ 4 5 //char A[1]; 6//a[0]= ' a '; 7unsigned Long Long md5=14126471717450151013; 8 9//printf (" %d\n ", a[0]); 10return 0; (GDB) break ten Breakpoint 1 at 0x8048372:file test.c, line. (GDB) Run Starting program:/data/compiler/g_platform/bradenwu/md5/test.out Break
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.