วันจันทร์ที่ 24 ตุลาคม พ.ศ. 2559

how to broadcast from ffmpeg to darwin streaming server (rtp , rtsp )?

This topic describe how to  broadcast from ffmpeg to darwin streaming server .
advantage rtsp or rtp protocal streaming used as standard for long time ago .application that used such as watch video stream on Nokia classic mobile or blackberry mobile or sony Ericsson mobile.
  another application is your webcam streaming to internet server so you can watch your webcam anytime as you want .



1.server install  Darwin streaming server
   https://github.com/macosforge/dss/releases
   or you prefer chinese darwin complied
  https://github.com/EasyDarwin/EasyDarwin/releases

2.set relaying parameter file( Darwin streaming server) used for forward rtsp relay unicast broadcast.
    relayconfig.xml

<OBJECT TYPE="relay">

<!-- this is the traditional relay source.  It just listens for data on the specified -->
<!-- ports and relays it to the specified destionations.  Note that you can't use -->
<!-- announced_destinations with a udp_source (they will be ignored) -->
<OBJECT CLASS="source" TYPE="udp_source">
<!-- this is the local address to listen on (optional) -->
<PREF NAME="in_addr">0.0.0.0</PREF>
<!-- this is the address of the broadcaster -->
<PREF NAME="source_addr">127.0.0.1</PREF>
<!-- in_ports are the ports to listen to to (must match config on broadcaster) -->
<LIST-PREF NAME="udp_ports"> -->
<VALUE>5000</VALUE> -->
<VALUE>5002</VALUE> -->
</LIST-PREF>
<!-- time to live for a multicast source (optional, only used for sending receiver -->
<!-- reports) -->
<PREF NAME="ttl">5</PREF>
</OBJECT>

<!-- this would normally be followed one or more udp_destinations -->

</OBJECT>
define source_addr as you prefer


3. run ffmpeg to encode and push up to streaming server

 3.1 application webcam through Easydarwin
 refer  http://m.blog.csdn.net/article/details?id=46928933

fmpeg -f dshow -i video="Integrated Camera":audio="麦克风 (Realtek High Definition Au" -vcodec libx264 -acodec libvo_aacenc -preset:v ultrafast -tune:v zerolatency -f rtsp rtsp://127.0.0.1/live.sdp
-f rtsp rtsp://127.0.0.1 (if your server and webcam run on same computer)




 3.1 application restream from  through  Darwin streaming server

-not recommend use vlc reencode because not support aac , amr encode
-download windows ffmpeg version at https://ffmpeg.zeranoe.com


run command
ffmpeg -re -i rtmp://server.com/live/stream1   -strict experimental -vcodec h263 -vb 20k  -s qcif -strict experimental  -acodec amr_nb -ar 8000 -ab 7950 -ac 1  -f  rtsp  rtsp://server2.com/3gp.sdp

explain
  -i rtmp://server.com/live/stream1  => get input from rtmp://server.com/live/stream1 
  -strict experimental  => for use amr encoding
-vb 20k => video bitrate 20kbps
-s qcif => video size 176x144  (  h263 support  cif (352x288) , qcif 176x144 ,‘sqcif’ 128x96 )
-acodec amr_nb => use amr_nb (amr narrow band ) encoding sound at low bitrate
-ar =>  ar (audio sampling rate) 8000hz
-ab =>  audio bit rate 4750 , 5150 ,5900 ,6700,7400 ,7950 ,10200 bps
-f  rtsp  rtsp://server2.com/3gp.sdp => push to server2 that install darwin server and relay broadcast


watching stream at rtsp://server2.com/3gp.sdp


remark
1. ffmpeg -re -i input.mpg -vcodec copy -an -f rtp rtp://224.10.20.30:20000 -vn -acodec copy -f rtp rtp://224.10.20.30:30000 -newaudio
<= not working with darwin i have tested http://lucabe72.blogspot.com/2010/04/rtp-streaming-with-ffmpeg.html


วันอาทิตย์ที่ 4 กันยายน พ.ศ. 2559

nokia classic share internet via usb (tethering) โนเกียแชร์ อินเทอร์เนตผ่านusb

Nokia Asha 5xx series devices are not supported by Nokia Suite or the Nokia PC Suite, hence it becomes a little bit tricky to connect the phone to the PC as a modem to access internet on the PC.

This technic also support all nokia classic device connect internet via usb cable.

โนเกีย แบบดั้งเดิม สามารถต่ออินเทอร์เนต ผ่านสาย usb ได้ โดยไม่ต้องลง suite  แต่ ต้องลงไดรพเวอร์ nokia  และตั้งค่าเล็กน้อย ก็สามารถ เชื่อมอินเทอร์เนตได้


Phones like the Asha 503 which come with 3G facility can be perfect to get internet access on the PC/Laptop. Besides the 5xx series phones, this also applies to all other Nokia Asha phones which are not supported by Nokia Suite.



 Connecting Nokia Asha phone to PC for using Internet You need the Nokia Connectivity Cable Drivers for connecting the phone to the PC. Windows will not recognize the phone and the modem unless you have the Connectivity Cable Drivers installed on your Windows PC. Download the NCC Drivers by clicking here.

ลงไดรฟเวอร์ โนเกียเคเบิลที่นี่

หรือ ถ้าอยากลง nokia suite


วันเสาร์ที่ 6 สิงหาคม พ.ศ. 2559

happy phone truesmart 3.5 connect internet usb on windows 10

1.เนื่องจาก windows 10 ไม่ยอมให้ลง driver ที่ไม่มี ลายเซ็น จึงต้อง ทำการ
disable driver signature enforcement เพื่อ ทำการ ปิดลายเซ็น ไดร์ฟเวอร์

a.  กดปุ่ม  Win + C แล้วกด  PC settings.
b. หาหัวข้อ  “Update & recovery
c. จากนั้น คลิ๊ก Recovery option ด้านซ้ายมือ
d.  เมื่อเลือกแล้ว จะห็น หัวข้อ  advanced startup section ด้านขวา , กดปุ่ม  “Restart now
e. หลังจากเครื่อง รีสตารท์ จะเห็น ตัวเลือก   Troubleshoot option.
f. เข้าไปส่วน  Advanced options.
g. จากนั้นเข้า  Startup Settings.
h. เมื้อแก้ไขค่าเสร็จ จากนั้น รีสตารท์ ครั้งสุดท้าย

I. จะปรากฏ รายการ ต่าง startup settings  (การตั้งค่าการเริ่มวินโดว) มองหาหัวข้อ  “Disable driver signature enforcement”. ซึ่งต้องกด คีย์  F7


2. ลงไดรเวอร์ ให้ตรง กับ วินโดว์ 32bit หรือ 64bit ก็จะลงผ่าน
 ดาวน์โหลด ไดรฟเวอร์็ที่นี่
ถ้าลงผ่านจะเป็น ดังภาพด้านล่าง





3.ต่อเชื่อมโทรศัพท์ กับ เครื่องคอม ผ่านสาย usb
4.การตั้งค่าการเชื่อมต่อ ทำครั้งแรก
 เข้า setting -> network -> dialup -> set up new


  4.1



4.2


4.3




test happy phone button style 2.8inch 2016 unlocking

software require  ซอฟแวร์ที่ต้องมี
1.researchdownload
2.driver usb (spd cpu)
3.rom unlock .pac

before unlock


1.install driver usb ( cpu spectrum )
ลงไดรฟเวอร์ให้ถูกต้องก่อน



2. first instruction  before flashing firmware
  check your driver ready

pickup mobile -> pull battery out -> connect usb from mobile to computer -> press and hold # key ->  insert battery

wait until your computer install driver and device manager show image like below.

เริ่มขั้นตอนการเตรียมความพร้อม การแฟลช เฟริมแวร์

 ลองทดสอบเข้าโหมดพิเศษ สำหรับ แฟลช เฟริมแวร์
 โทรศัพท์ ->ถอดถ่าน -> เสียบสาย -> กดปุ่ม #ค้าง ->ใส่แบต

ถ้าสำเร็จ เครื่องคอมจะถามไดรฟเวอร์ก็ ปล่อยให้มันลงอัตโนมัติ

และ device manager จะขึ้น ดังรูป



3.open research download program
pick up -> unlocked .pac firmware -> press play (ready download) -> do second instruction again (number 2)-> wait for firmware downloading

เปิดโปรแกรม research download -> เปิดโปรแกรม .pac ที่อันล็อค -> ทำขั้นตอนที่ 2 อีกครั้ง -> โปรแกรมจะ โหลดเฟริมแวร์ให้ รอ




แหล่งโหลด
[GUIDE] Use Research Download (Spredtrum ROM Flash)
http://forum.xda-developers.com/showthread.php?t=2624918

driver
https://drive.google.com/file/d/0BztcLUCoKzp3LS1SblRZdVVQZzA/view

firmware
http://www.thailand-developers.com/thread-3343-1-1.html





วันศุกร์ที่ 29 กรกฎาคม พ.ศ. 2559

how to connect internet by nokia or other phone via bluetooth windows 8 , 10

การเชื่อมต่อ โทรศัพท์ ผ่าน บลูทุธ บน วินโดว์ 8 10
how to connect internet by nokia or other phone via bluetooth windows 8 , 10

1.ทำการ pair โทรศัพท์ ให้เรียบร้อย  ตามรูป กด ปุ่ม pair
   Go to setting -> Device ->manage bluetooth (in windows 10 )
 Be sure!  make your mobile discovery
 if found then press pair

1.1 wait for pass code pair your phone


2. ตรวจสอบโทรศัพท์ ว่า รองรับ การเชื่อมต่ออินเทอร์เนต ผ่าน บลูทุธ หรือไม่
check capability of mobile phone support internet via bluetooth

2.1 กด open settings

2.2 ตรวจสอบ มีคำเหล่านี้ ไหม ที่ com port ( there are com ports show similar image above)

วันพฤหัสบดีที่ 14 กรกฎาคม พ.ศ. 2559

ลองเริ่มต้น php กับ google drive กูเกิลไดรพ

1.ต้องมี กูเกิล จีเมล์ สมัครให้เรียบร้อย
2.เข้ากูเกิล คอนโซล
https://console.developers.google.com/

3.กรณี ไม่มี โปรเจค ต้องสร้างก่อน
4.enable api ที่ต้องการ กรณีนี้เรา จะทดสอบ ไดรฟ