1. remove telemetry

2. update docs
This commit is contained in:
idea4good 2023-04-25 10:48:05 +08:00
parent 74c7af7b53
commit 7c6afefc19
13 changed files with 41 additions and 178 deletions

View File

@ -62,7 +62,7 @@ Even a C beginner could master GUI-lite quickly. The source code only uses basic
## Demo wall ## Demo wall
- Zero dependency, 100% build pass & runnable - Zero dependency, 100% build pass & runnable
- Click the demo you like, and run it on your hardware - Click the demo you like, and run it on your hardware
- Most of the demos have about 100 lines of UI code, code repository is [here.](https://gitee.com/idea4good/GuiLiteSamples) - Most of the demos have about 100 lines of UI code, the code repository is [GuiLiteSamples](https://gitee.com/idea4good/GuiLiteSamples)
--- ---
### MCU platform ### MCU platform
--- ---
@ -96,7 +96,7 @@ Even a C beginner could master GUI-lite quickly. The source code only uses basic
<td align="center"><a href="https://gitee.com/idea4good/GuiLiteSamples/tree/master/HostMonitor"><img src="documents/BuildInfo.png" width="600px;"/><br /><sub><b>Code Telemetry & Analysis in real time</b></sub></a> <td align="center"><a href="https://gitee.com/idea4good/GuiLiteSamples/tree/master/HostMonitor"><img src="documents/BuildInfo.png" width="600px;"/><br /><sub><b>Code Telemetry & Analysis in real time</b></sub></a>
</tr> </tr>
<tr> <tr>
<td align="center"><a href="https://gitee.com/idea4good/GuiLiteSamples/tree/master/HelloAzureIoT"><img src="documents/HelloAzureIoT.jpg" width="600px;"/><br /><sub><b>Track IoT device over the world</b></sub></a> <td align="center"><a href="https://gitee.com/idea4good/GuiLiteSamples/tree/master/HelloAzureIoT"><img src="documents/HelloAzureIoT.png" width="600px;"/><br /><sub><b>Track IoT device over the world</b></sub></a>
</tr> </tr>
</table> </table>

View File

@ -60,7 +60,7 @@
## Demo展示墻 ## Demo展示墻
- 0依赖100%编译通过,可直接运行 - 0依赖100%编译通过,可直接运行
- 点击你喜欢的实例,并运行在你的硬件上面 - 点击你喜欢的实例,并运行在你的硬件上面
- 大部分demo的UI代码只有100行左右代碼庫在[这里。](https://gitee.com/idea4good/GuiLiteSamples) - 大部分demo的UI代码只有100行左右代碼庫在[GuiLiteSamples](https://gitee.com/idea4good/GuiLiteSamples)
--- ---
### 單片機平臺 ### 單片機平臺
--- ---
@ -94,7 +94,7 @@
<td align="center"><a href="https://gitee.com/idea4good/GuiLiteSamples/tree/master/HostMonitor"><img src="documents/BuildInfo.png" width="600px;"/><br /><sub><b>Code Telemetry & Analysis in real time</b></sub></a> <td align="center"><a href="https://gitee.com/idea4good/GuiLiteSamples/tree/master/HostMonitor"><img src="documents/BuildInfo.png" width="600px;"/><br /><sub><b>Code Telemetry & Analysis in real time</b></sub></a>
</tr> </tr>
<tr> <tr>
<td align="center"><a href="https://gitee.com/idea4good/GuiLiteSamples/tree/master/HelloAzureIoT"><img src="documents/HelloAzureIoT.jpg" width="600px;"/><br /><sub><b>Track IoT device over the world</b></sub></a> <td align="center"><a href="https://gitee.com/idea4good/GuiLiteSamples/tree/master/HelloAzureIoT"><img src="documents/HelloAzureIoT.png" width="600px;"/><br /><sub><b>Track IoT device over the world</b></sub></a>
</tr> </tr>
</table> </table>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 98 KiB

BIN
documents/HelloAzureIoT.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 852 KiB

View File

@ -62,6 +62,6 @@ Output here: GuiLite/workspace/libGuiLite.a
## Build header-only GuiLite.h? ## Build header-only GuiLite.h?
```bash ```bash
cd GuiLite/workspace cd GuiLite/src
./header-only.sh ./GenerateGuiLite.h.sh
``` ```

View File

@ -70,36 +70,31 @@ widgets:
## 文件注释 ## 文件注释
| core 重要程度/文件名称 | 代码简介 | 推荐学习时间 | | core 重要程度/文件名称 | 代码简介 | 推荐学习时间 |
| --- | --- | --- | | --- | --- | --- |
| ★★★ wnd.cpp | UI元素的基本类定义所有的UI元素信息、绘制及管理办法 | 1.5小时 | | ★★★ wnd.h | UI元素的基本类定义所有的UI元素信息、绘制及管理办法 | 1.5小时 |
| ★★ display.cpp | 生成显示设备设定surface的数目一个surface对应一个滑动页面 | 0.5小时 | | ★★ display.h | 生成显示设备设定surface的数目一个surface对应一个滑动页面 | 0.5小时 |
| word.cpp | 显示文字 | < 1小时 | | word.h | 显示文字 | < 1小时 |
| bitmap.cpp | 绘制位图支持16 bits和32 bits | < 0.5小时 | | image.h | 绘制位图支持16 bits和32 bits | < 0.5小时 |
| rect.cpp | UI元素的位置信息 | < 0.5小时 | | rect.h | UI元素的位置信息 | < 0.5小时 |
| api_linux.cpp | Linux适配层 | < 0.5小时 | | api_linux.cpp | Linux适配层 | < 0.5小时 |
| api_win.cpp | Window适配层 | < 0.5小时 | | api_win.cpp | Window适配层 | < 0.5小时 |
| api_unknow.cpp | 无OS或其他OS适配层 | < 0.5小时 | | api_unknow.cpp | 无OS或其他OS适配层 | < 0.5小时 |
| audio_linux.cpp | Linux audio适配层 | < 0.5小时 |
| audio_win.cpp | Windows audio适配层 | < 0.5小时 |
| msg_linux.cpp | 消息管道在Linux上的实现 | < 0.5小时 |
| msg_win.cpp | 消息管道在Windows上的实现 | < 0.5小时 |
| msg_unknow.cpp | 消息管道在其他OS或无OS上的实现 | < 0.5小时 |
*** ***
| widgets 难度/文件名称 | 代码简介 | 推荐学习时间 | | widgets 难度/文件名称 | 代码简介 | 推荐学习时间 |
| --- | --- | --- | | --- | --- | --- |
| label.cpp | 标签控件的绘制 | < 0.5小时 | | label.h | 标签控件的绘制 | < 0.5小时 |
| button.cpp | 按钮控件的绘制及用户点击响应函数 | < 0.5小时 | | button.h | 按钮控件的绘制及用户点击响应函数 | < 0.5小时 |
| table.cpp | Table控件的绘制 | < 0.5小时 | | table.h | Table控件的绘制 | < 0.5小时 |
| dialog.cpp | 对话框的绘制及管理方法 | < 0.5小时 | | dialog.h | 对话框的绘制及管理方法 | < 0.5小时 |
| ★ gesture.cpp | 手势识别方法,包括:鼠标按下,弹起及滑动 | 0.5小时 | | ★ keyboard.h | 键盘控件的绘制及用户点击响应函数 | 0.5小时 |
| ★ keyboard.cpp | 键盘控件的绘制及用户点击响应函数 | 0.5小时 | | ★★ list_box.h | List控件的绘制及用户点击响应函数 | 1.5小时 |
| ★★ list_box.cpp | List控件的绘制及用户点击响应函数 | 1.5小时 | | ★★ spinbox.h | Spinbox控件的绘制及用户点击响应函数 | 1.5小时 |
| ★★ spinbox.cpp | Spinbox控件的绘制及用户点击响应函数 | 1.5小时 | | ★★ edit.h | Edit控件的绘制及用户点击响应函数 | 1.5小时 |
| ★★ edit.cpp | Edit控件的绘制及用户点击响应函数 | 1.5小时 | | ★ slide_group.h | 多屏GUI的实现以及用来切换屏幕的划屏操作 | 1.5小时 |
| ★★★ wave_buffer.cpp | 波形数据的缓冲管理 | 1.5小时 | | ★★★ wave_buffer.h | 波形数据的缓冲管理 | 1.5小时 |
| ★★★ wave_ctrl.cpp | 实现波形控件 | 1.5小时 | | ★★★ wave_ctrl.h | 它通过波形数据,绘制实时的波形控件 | 1.5小时 |
## 函数注释 ## 函数注释
| 函数名称 | display.cpp 函数接口注释 | | 函数名称 | display.h::c_display 函数接口注释 |
| --- | --- | | --- | --- |
| c_display | c_display构造函数。phy_fb物理framebuffer指针display_width物理显示器宽度display_height物理显示器高度surface_widthsurface宽度surface_heightsurface高度color_bytes颜色深度surface_cntsurface个数/滑动页面的个数gfx_op外部绘制接口用以适配非framebuffer的渲染方式如果该值不为空surface在作底层渲染的时候会调用该接口 | | c_display | c_display构造函数。phy_fb物理framebuffer指针display_width物理显示器宽度display_height物理显示器高度surface_widthsurface宽度surface_heightsurface高度color_bytes颜色深度surface_cntsurface个数/滑动页面的个数gfx_op外部绘制接口用以适配非framebuffer的渲染方式如果该值不为空surface在作底层渲染的时候会调用该接口 |
| alloc_surface | 分配surface/滑动页面。usr 用户IDmax_zorder该surface所拥有的图层数量| | alloc_surface | 分配surface/滑动页面。usr 用户IDmax_zorder该surface所拥有的图层数量|
@ -107,7 +102,7 @@ widgets:
| get_updated_fb | 获取该display的framebuffer指针常用来将GUI显示在任意需要的地方。widght用来获取framebuffer的宽度height用来获取framebuffer的高度force_update是否需要强制更新framebuffer的内容如果不需要强制更新且framebuffer没法发生变化将返回NULL | | get_updated_fb | 获取该display的framebuffer指针常用来将GUI显示在任意需要的地方。widght用来获取framebuffer的宽度height用来获取framebuffer的高度force_update是否需要强制更新framebuffer的内容如果不需要强制更新且framebuffer没法发生变化将返回NULL |
| snap_shot | 生成当前显示的快照并输出到bitmap文件。file_name快照文件的名称 | | snap_shot | 生成当前显示的快照并输出到bitmap文件。file_name快照文件的名称 |
*** ***
| 函数名称 | surface.cpp 函数接口注释 | | 函数名称 | display.h::c_surface 函数接口注释 |
| --- | --- | | --- | --- |
| c_surface | c_surface构造函数。 displaysurface所属于的displaywidthsurface的宽度heightsurface的高度color_bytes颜色深度| | c_surface | c_surface构造函数。 displaysurface所属于的displaywidthsurface的宽度heightsurface的高度color_bytes颜色深度|
| set_surface | 设置surface。wnd_root使用者者ID通常为root window其子窗口自动获得该surface的使用权。 max_z_order该surface拥有的图层数量 | | set_surface | 设置surface。wnd_root使用者者ID通常为root window其子窗口自动获得该surface的使用权。 max_z_order该surface拥有的图层数量 |

View File

@ -71,30 +71,25 @@ Rendering include rendering method and graphic management.
## Source file annotation ## Source file annotation
| core Importance/File name | Introduction | Time cost | | core Importance/File name | Introduction | Time cost |
| --- | --- | --- | | --- | --- | --- |
| ★★★ wnd.cpp | Basic class for widgets; connect/disconnect widgets; response user on_touch, on_key action | 1.5 hour | | ★★★ wnd.h | Basic class for widgets; connect/disconnect widgets; response user on_touch, on_key action | 1.5 hour |
| ★★ display.cpp | Initialize display device, create surface, | 0.5 hour | | ★★ display.h | Initialize display device, create surface, | 0.5 hour |
| word.cpp | Draw text | < 1 hour | | word.h | Draw text | < 1 hour |
| bitmap.cpp | Draw bitmap | < 0.5 hour | | image.h | Draw bitmap | < 0.5 hour |
| rect.cpp | Rect for basic use(e.g, widgets location) | < 0.5 hour | | rect.h | Rect for basic use(e.g, widgets location) | < 0.5 hour |
| api_linux.cpp | Adapter for Linux | < 0.5 hour | | api_linux.cpp | Adapter for Linux | < 0.5 hour |
| api_win.cpp | Adapter for Windows | < 0.5 hour | | api_win.cpp | Adapter for Windows | < 0.5 hour |
| api_unknow.cpp | Adapter for other OS or none OS | < 0.5 hour | | api_unknow.cpp | Adapter for other OS or none OS | < 0.5 hour |
| audio_linux.cpp | Adapter for Linux audio | < 0.5 hour |
| audio_win.cpp | Adapter Windows audio | < 0.5 hour |
| msg_linux.cpp | Implement message pipe on Linux | < 0.5 hour |
| msg_win.cpp | Implement message pipe on Windows | < 0.5 hour |
| msg_unknow.cpp | Implement message pipe on other OS or none OS | < 0.5 hour |
*** ***
| widgets Difficulty/File name | Introduction | Time cost | | widgets Difficulty/File name | Introduction | Time cost |
| --- | --- | --- | | --- | --- | --- |
| label.cpp | Source code for label | < 0.5 hour | | label.h | Draw label | < 0.5 hour |
| button.cpp | Source code for button | < 0.5 hour | | button.h | Draw/Click button | < 0.5 hour |
| table.cpp | Source code for table | < 0.5 hour | | table.h | Draw table | < 0.5 hour |
| dialog.cpp | Source code for dialog | < 0.5 hour | | dialog.h | Draw/Open/Close dialog | < 0.5 hour |
| ★ gesture.cpp | Recognize finger gesture(e.g, press/release/slip) | 0.5 hour | | ★ keyboard.h | Draw/Click keyboard | 0.5 hour |
| ★ keyboard.cpp | Source code for keyboard | 0.5 hour | | ★★ list_box.h | Draw/Click list box | 1.5 hour |
| ★★ list_box.cpp | Source code for list box | 1.5 hour | | ★★ spinbox.h | Draw/Click spin box | 1.5 hour |
| ★★ spinbox.cpp | Source code for spin box | 1.5 hour | | ★★ edit.h | Draw/Click edit widget | 1.5 hour |
| ★★ edit.cpp | Source code for edit widget | 1.5 hour | | ★ slide_group.cpp | Draw multiple screens & Swip screen | 1.5 hour |
| ★★★ wave_buffer.cpp | Source code for wave buffer | 1.5 hour | | ★★★ wave_buffer.h | Manage wave buffer data | 1.5 hour |
| ★★★ wave_ctrl.cpp | Source code for wave widget | 1.5 hour | | ★★★ wave_ctrl.h | Draw wave widget with wave buffer data | 1.5 hour |

View File

@ -1,38 +0,0 @@
if [ "$#" -ne 1 ]; then
echo "Invalid arguments"
exit -1
fi
url="https://api.powerbi.com/beta/72f988bf-86f1-41af-91ab-2d7cd011db47/datasets/2ff1e8a8-2f6f-4d73-a75d-86829e3f4574/rows?key=8f5xLp1gP8%2FzSee4vCUBcyjR65I9zZ6nb%2B%2F7bbzex%2FSctLX3ntIlAR0sxWpDdguuYyDtLdHK%2Fxbxj%2FrSBkX7eQ%3D%3D"
build_time=`date +%Y-%m-%dT%H:%M:%S.000%z`
device_info=`uname -s -n -m`
#--------------- Geo info ----------------#
timeout 30s curl ipinfo.io > /tmp/ip_info.tmp # get IP info
grep city /tmp/ip_info.tmp > /tmp/ip_city.tmp # filter city
sed -i 's/"city"://g' /tmp/ip_city.tmp #remove property name
sed -i 's/"//g' /tmp/ip_city.tmp #remove double quotes
city=`sed 's/,//g' /tmp/ip_city.tmp` #remove comma
grep country /tmp/ip_info.tmp > /tmp/ip_country.tmp # filter country
sed -i 's/"country"://g' /tmp/ip_country.tmp #remove property name
sed -i 's/"//g' /tmp/ip_country.tmp #remove double quotes
country=`sed 's/,//g' /tmp/ip_country.tmp` #remove comma
grep org /tmp/ip_info.tmp > /tmp/ip_org.tmp # filter org
sed -i 's/"org"://g' /tmp/ip_org.tmp #remove property name
sed -i 's/"//g' /tmp/ip_org.tmp #remove double quotes
org=`sed 's/,//g' /tmp/ip_org.tmp` #remove comma
timeout 30s curl --include --request POST --header "Content-Type: application/json" --data-binary "[{
\"device_info\" :\"$device_info\",
\"project_info\" :\"$1\",
\"time\" :\"$build_time\",
\"weight\" :1,
\"country\" :\"$country\",
\"city\" :\"$city\",
\"org\" :\"$org\",
\"log\" :\"$build_time\",
\"version\" :\"v3.0\"
}]" $url

View File

@ -20,5 +20,3 @@ ADD_LIBRARY(GuiLite STATIC ${CORE_SRC} ${CORE_ADAPTER} ${WIDGETS_SRC})
# build shared library # build shared library
# ADD_LIBRARY(GuiLite SHARED ${CORE_SRC} ${CORE_ADAPTER} ${WIDGETS_SRC}) # ADD_LIBRARY(GuiLite SHARED ${CORE_SRC} ${CORE_ADAPTER} ${WIDGETS_SRC})
execute_process(COMMAND ${CMAKE_SOURCE_DIR}/.sync.sh GuiLite)

View File

@ -50,4 +50,3 @@ echo "You could find GuiLite.h in root folder"
# clean # clean
rm *.h *.cpp *.o rm *.h *.cpp *.o
./.sync.sh GuiLite-header > .sync_log.txt 2>&1 &

View File

@ -82,7 +82,7 @@
<AfterMake> <AfterMake>
<RunUserProg1>1</RunUserProg1> <RunUserProg1>1</RunUserProg1>
<RunUserProg2>0</RunUserProg2> <RunUserProg2>0</RunUserProg2>
<UserProg1Name>sync_build.bat GuiLite-keil</UserProg1Name> <UserProg1Name></UserProg1Name>
<UserProg2Name></UserProg2Name> <UserProg2Name></UserProg2Name>
<UserProg1Dos16Mode>0</UserProg1Dos16Mode> <UserProg1Dos16Mode>0</UserProg1Dos16Mode>
<UserProg2Dos16Mode>0</UserProg2Dos16Mode> <UserProg2Dos16Mode>0</UserProg2Dos16Mode>

View File

@ -145,9 +145,6 @@
<Lib> <Lib>
<AdditionalOptions>%(AdditionalOptions) /machine:X86</AdditionalOptions> <AdditionalOptions>%(AdditionalOptions) /machine:X86</AdditionalOptions>
</Lib> </Lib>
<PostBuildEvent>
<Command>call "$(SolutionDir)sync_build.bat" "GuiLite"</Command>
</PostBuildEvent>
</ItemDefinitionGroup> </ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'"> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<ClCompile> <ClCompile>
@ -181,9 +178,6 @@
<Lib> <Lib>
<AdditionalOptions>%(AdditionalOptions) /machine:X64</AdditionalOptions> <AdditionalOptions>%(AdditionalOptions) /machine:X64</AdditionalOptions>
</Lib> </Lib>
<PostBuildEvent>
<Command>call "$(SolutionDir)sync_build.bat" "GuiLite"</Command>
</PostBuildEvent>
</ItemDefinitionGroup> </ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'"> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<ClCompile> <ClCompile>
@ -217,9 +211,6 @@
<Lib> <Lib>
<AdditionalOptions>%(AdditionalOptions) /machine:X86</AdditionalOptions> <AdditionalOptions>%(AdditionalOptions) /machine:X86</AdditionalOptions>
</Lib> </Lib>
<PostBuildEvent>
<Command>call "$(SolutionDir)sync_build.bat" "GuiLite"</Command>
</PostBuildEvent>
</ItemDefinitionGroup> </ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'"> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<ClCompile> <ClCompile>
@ -253,9 +244,6 @@
<Lib> <Lib>
<AdditionalOptions>%(AdditionalOptions) /machine:X64</AdditionalOptions> <AdditionalOptions>%(AdditionalOptions) /machine:X64</AdditionalOptions>
</Lib> </Lib>
<PostBuildEvent>
<Command>call "$(SolutionDir)sync_build.bat" "GuiLite"</Command>
</PostBuildEvent>
</ItemDefinitionGroup> </ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='MinSizeRel|Win32'"> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='MinSizeRel|Win32'">
<ClCompile> <ClCompile>

View File

@ -1,74 +0,0 @@
echo off
setlocal
set argC=0
for %%x in (%*) do set /A argC+=1
if NOT "1" == "%argC%" (
echo "Invalidate arguments"
goto :eof
)
set url="https://api.powerbi.com/beta/72f988bf-86f1-41af-91ab-2d7cd011db47/datasets/2ff1e8a8-2f6f-4d73-a75d-86829e3f4574/rows?key=8f5xLp1gP8%%2FzSee4vCUBcyjR65I9zZ6nb%%2B%%2F7bbzex%%2FSctLX3ntIlAR0sxWpDdguuYyDtLdHK%%2Fxbxj%%2FrSBkX7eQ%%3D%%3D"
::analyze date time
for /f %%x in ('wmic path win32_utctime get /format:list ^| findstr "="') do (
set %%x
)
set Second=0%Second%
set Second=%Second:~-2%
set Minute=0%Minute%
set Minute=%Minute:~-2%
set Hour=0%Hour%
set Hour=%Hour:~-2%
set Day=0%Day%
set Day=%Day:~-2%
set Month=0%Month%
set Month=%Month:~-2%
set datetime=%Year%-%Month%-%Day%T%Hour%:%Minute%:%Second%.000+0000
::----------------- for GEO info -----------------
set tmpPath=%userprofile%\AppData\Local\Temp\
if not exist "%tmpPath%ip_info.tmp" (
curl.exe ipinfo.io > %tmpPath%ip_info.tmp
)
if not exist "%tmpPath%ip_country.tmp" (
findstr.exe country %tmpPath%ip_info.tmp > %tmpPath%ip_country.tmp
powershell -Command "(gc %tmpPath%ip_country.tmp) -replace '\"country\":', '' | Out-File -encoding ASCII %tmpPath%ip_country.tmp"
powershell -Command "(gc %tmpPath%ip_country.tmp) -replace '""' , '' | Out-File -encoding ASCII %tmpPath%ip_country.tmp"
powershell -Command "(gc %tmpPath%ip_country.tmp) -replace ',' , '' | Out-File -encoding ASCII %tmpPath%ip_country.tmp"
)
if not exist "%tmpPath%ip_city.tmp" (
findstr.exe city %tmpPath%ip_info.tmp > %tmpPath%ip_city.tmp
powershell -Command "(gc %tmpPath%ip_city.tmp) -replace '\"city\":', '' | Out-File -encoding ASCII %tmpPath%ip_city.tmp"
powershell -Command "(gc %tmpPath%ip_city.tmp) -replace '""' , '' | Out-File -encoding ASCII %tmpPath%ip_city.tmp"
powershell -Command "(gc %tmpPath%ip_city.tmp) -replace ',' , '' | Out-File -encoding ASCII %tmpPath%ip_city.tmp"
)
if not exist "%tmpPath%ip_org.tmp" (
findstr.exe org %tmpPath%ip_info.tmp > %tmpPath%ip_org.tmp
powershell -Command "(gc %tmpPath%ip_org.tmp) -replace '\"org\":', '' | Out-File -encoding ASCII %tmpPath%ip_org.tmp"
powershell -Command "(gc %tmpPath%ip_org.tmp) -replace '""' , '' | Out-File -encoding ASCII %tmpPath%ip_org.tmp"
powershell -Command "(gc %tmpPath%ip_org.tmp) -replace ',' , '' | Out-File -encoding ASCII %tmpPath%ip_org.tmp"
)
set /p country=<%tmpPath%ip_country.tmp
set /p city=<%tmpPath%ip_city.tmp
set /p org=<%tmpPath%ip_org.tmp
set raw_data=[{^
\"device_info\" :\"Win-%USERNAME%\",^
\"project_info\" :\"%1\",^
\"time\" :\"%datetime%\",^
\"weight\" : 1,^
\"country\" :\"%country%\",^
\"city\" :\"%city%\",^
\"org\" :\"%org%\",^
\"log\" :\"%datetime%\",^
\"version\" :\"v3.0\"^
}]
curl.exe --include --request POST --header "Content-Type: application/json" --data-binary "%raw_data%" "%url%"
exit /B 0